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

Unified Diff: runtime/vm/assembler_x64_test.cc

Issue 10451026: More intrinsification x64: array index load and store. (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/
Patch Set: Created 8 years, 7 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
Index: runtime/vm/assembler_x64_test.cc
===================================================================
--- runtime/vm/assembler_x64_test.cc (revision 7962)
+++ runtime/vm/assembler_x64_test.cc (working copy)
@@ -1211,6 +1211,26 @@
EXPECT_EQ(16, res); // 16 bytes emitted.
}
+
+ASSEMBLER_TEST_GENERATE(TestAdds, assembler) {
+ __ movq(RAX, Immediate(4));
+ __ pushq(RAX);
+ __ addq(Address(RSP, 0), Immediate(5));
+ // TOS: 9
+ __ addq(Address(RSP, 0), Immediate(-2));
regis 2012/05/24 23:31:29 You are not testing the newly added (Address, Regi
srdjan 2012/05/24 23:54:13 Added test.
+ // TOS: 7
+ __ popq(RAX);
+ __ ret();
+}
+
+
+ASSEMBLER_TEST_RUN(TestAdds, entry) {
+ typedef int (*TestAdds)();
+ int res = reinterpret_cast<TestAdds>(entry)();
+ EXPECT_EQ(7, res);
+}
+
+
} // namespace dart
#endif // defined TARGET_ARCH_X64

Powered by Google App Engine
This is Rietveld 408576698