[vm/ffi] Fix Pointer deferred materialization on deopt - fix test

This test deoptimizes, so it can't run in AOT.

TEST=runtime/tests/vm/dart/regress_54871_test.dart

Fixes: https://github.com/dart-lang/sdk/issues/54913
Change-Id: Ida2c67f20c8cf879db2cc9424f3d37535b76370d
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/352660
Reviewed-by: Alexander Markov <alexmarkov@google.com>
Commit-Queue: Daco Harkes <dacoharkes@google.com>
Auto-Submit: Daco Harkes <dacoharkes@google.com>
This commit is contained in:
Daco Harkes 2024-02-14 17:18:18 +00:00 committed by Commit Queue
parent 4ef3c33932
commit 9626a2552f

View file

@ -4,13 +4,20 @@
// Regression test for https://dartbug.com/54871.
import 'dart:ffi';
import 'dart:_internal';
import 'dart:ffi';
import 'dart:io';
const address = 0xaabbccdd;
bool deoptimize = false;
final bool isAOT = Platform.executable.contains('dart_precompiled_runtime');
main() {
// This test will cause deoptimizations (via helper in `dart:_internal`) and
// does therefore not run in AOT.
if (isAOT) return;
for (int i = 0; i < 100000; ++i) {
foo();
}