966d795f4e
* Fix .dart test which didn't exersize the shared stub going into runtime. * Fix AllocateMint runtime entry int constant choice so it doesn't fit a Smi on all targets, not only 32-bit ones. * Make MintAllocation stubs go to runtime when FLAG_shared_slow_path_triggers_gc is set for testing purposes. Change-Id: I699f36c70d055af7bd17a16f81b92b9e9d87580c Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/129703 Reviewed-by: Martin Kustermann <kustermann@google.com> Commit-Queue: Martin Kustermann <kustermann@google.com>
29 lines
728 B
Dart
29 lines
728 B
Dart
// Copyright (c) 2019, the Dart project authors. Please see the AUTHORS file
|
|
// for details. All rights reserved. Use of this source code is governed by a
|
|
// BSD-style license that can be found in the LICENSE file.
|
|
|
|
// Test case that tests boxing mint
|
|
|
|
// VMOptions=--optimization_counter_threshold=10 --deterministic --use-slow-path --shared-slow-path-triggers-gc --stacktrace_filter=foobar
|
|
|
|
import 'dart:typed_data';
|
|
import 'package:expect/expect.dart';
|
|
|
|
final gSize = 100;
|
|
final l = Uint64List(gSize);
|
|
int sum = 0;
|
|
|
|
foobar() {
|
|
for (int i = 0; i < l.length; ++i) {
|
|
sum += l[i];
|
|
}
|
|
Expect.equals(-9223372036854775808, sum);
|
|
}
|
|
|
|
main() {
|
|
for (int i = 0; i < gSize; i++) {
|
|
l[i] = (i + 30) << 62;
|
|
}
|
|
foobar();
|
|
}
|