mirror of
https://github.com/dart-lang/sdk
synced 2024-09-06 00:59:09 +00:00
![Robert Nystrom](/assets/img/avatar_default.png)
- Copies corelib_2/a* -> corelib/ - Copies language_2/ab* -> language/ - Copies lib_2/math/ -> lib/math/ - Copies standalone_2/a* -> standalone/ And also copies over and renames all of the status files in those directories. Then it migrates those tests to be static error free in NNBD. Finally, adds support to the test_runner for the new suites. Note that this review is split into multiple patchsets. The first patchset is a straight copy of the existing files. Then the later patchsets have the interesting changes. Change-Id: Icec2ff850a3aee30b653066ac184495d1e3814d0 Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/125467 Commit-Queue: Bob Nystrom <rnystrom@google.com> Reviewed-by: Leaf Petersen <leafp@google.com> Reviewed-by: Alexander Thomas <athom@google.com> Reviewed-by: Nicholas Shahan <nshahan@google.com>
27 lines
676 B
Dart
27 lines
676 B
Dart
// Copyright (c) 2016, 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.
|
|
|
|
// VMOptions=--optimization-counter-threshold=-1 --new_gen_semi_max_size=2
|
|
|
|
// TODO(rnystrom): This looks like a VM-specific test. Move out of
|
|
// tests/language and into somewhere more appropriate.
|
|
|
|
import 'dart:math';
|
|
|
|
main() {
|
|
// 2MB / 16 bytes = 125000 allocations
|
|
|
|
for (var i = 0; i < 500000; i++) {
|
|
sin(i);
|
|
}
|
|
|
|
for (var i = 0; i < 500000; i++) {
|
|
cos(i);
|
|
}
|
|
|
|
for (var i = 0; i < 500000; i++) {
|
|
i.toDouble().truncateToDouble();
|
|
}
|
|
}
|