Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(274)

Unified Diff: tests/lib/typed_data/float32x4_unbox_regress_test.dart

Issue 13872020: Inline Float32x4 Getters (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 7 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « runtime/vm/intermediate_language_x64.cc ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: tests/lib/typed_data/float32x4_unbox_regress_test.dart
diff --git a/tests/lib/typed_data/float32x4_unbox_regress_test.dart b/tests/lib/typed_data/float32x4_unbox_regress_test.dart
index ed3897036557414994a70fe747e3921a96fdda0b..e166c3f561204b5c727406da909b2dd4808e4047 100644
--- a/tests/lib/typed_data/float32x4_unbox_regress_test.dart
+++ b/tests/lib/typed_data/float32x4_unbox_regress_test.dart
@@ -50,7 +50,31 @@ void testAddDeopt() {
} catch (_) {}
}
+
+testGet(a) {
+ var c = a.x + a.y + a.z + a.w;
+ Expect.equals(10.0, c);
+}
+
+void testGetDeopt() {
+ var a = new Float32x4(1.0, 2.0, 3.0, 4.0);
+ var smi = 12;
+ for (int i = 0; i < 3000; i++) {
+ testGet(a);
+ }
+
+ try {
+ testGet(12);
+ } catch (_) {
+ }
+
+ for (int i = 0; i < 3000; i++) {
+ testGet(a);
+ }
+}
+
main() {
testListStoreDeopt();
testAddDeopt();
+ testGetDeopt();
}
« no previous file with comments | « runtime/vm/intermediate_language_x64.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698