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

Unified Diff: test/cctest/test-assembler-arm64.cc

Issue 572903003: ARM64: Remove the unused 'SmiAbs'. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Created 6 years, 3 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 | « src/arm64/macro-assembler-arm64.cc ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: test/cctest/test-assembler-arm64.cc
diff --git a/test/cctest/test-assembler-arm64.cc b/test/cctest/test-assembler-arm64.cc
index 3d05487f393e9acfda72bf305051c8f07b408317..587a4ce971be319a430d006e2013cf38e776890d 100644
--- a/test/cctest/test-assembler-arm64.cc
+++ b/test/cctest/test-assembler-arm64.cc
@@ -10270,58 +10270,6 @@ TEST(copyfields) {
}
-static void DoSmiAbsTest(int32_t value, bool must_fail = false) {
- SETUP();
-
- START();
- Label end, slow;
- __ Mov(x2, 0xc001c0de);
- __ Mov(x1, value);
- __ SmiTag(x1);
- __ SmiAbs(x1, &slow);
- __ SmiUntag(x1);
- __ B(&end);
-
- __ Bind(&slow);
- __ Mov(x2, 0xbad);
-
- __ Bind(&end);
- END();
-
- RUN();
-
- if (must_fail) {
- // We tested an invalid conversion. The code must have jump on slow.
- CHECK_EQUAL_64(0xbad, x2);
- } else {
- // The conversion is valid, check the result.
- int32_t result = (value >= 0) ? value : -value;
- CHECK_EQUAL_64(result, x1);
-
- // Check that we didn't jump on slow.
- CHECK_EQUAL_64(0xc001c0de, x2);
- }
-
- TEARDOWN();
-}
-
-
-TEST(smi_abs) {
- INIT_V8();
- // Simple and edge cases.
- DoSmiAbsTest(0);
- DoSmiAbsTest(0x12345);
- DoSmiAbsTest(0x40000000);
- DoSmiAbsTest(0x7fffffff);
- DoSmiAbsTest(-1);
- DoSmiAbsTest(-12345);
- DoSmiAbsTest(0x80000001);
-
- // Check that the most negative SMI is detected.
- DoSmiAbsTest(0x80000000, true);
-}
-
-
TEST(blr_lr) {
// A simple test to check that the simulator correcty handle "blr lr".
INIT_V8();
« no previous file with comments | « src/arm64/macro-assembler-arm64.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698