| OLD | NEW |
| 1 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file |
| 2 // for details. All rights reserved. Use of this source code is governed by a | 2 // for details. All rights reserved. Use of this source code is governed by a |
| 3 // BSD-style license that can be found in the LICENSE file. | 3 // BSD-style license that can be found in the LICENSE file. |
| 4 | 4 |
| 5 #include "vm/globals.h" | 5 #include "vm/globals.h" |
| 6 #if defined(TARGET_ARCH_IA32) | 6 #if defined(TARGET_ARCH_IA32) |
| 7 | 7 |
| 8 #include "vm/assembler.h" | 8 #include "vm/assembler.h" |
| 9 #include "vm/os.h" | 9 #include "vm/os.h" |
| 10 #include "vm/unit_test.h" | 10 #include "vm/unit_test.h" |
| (...skipping 489 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 500 __ movl(EAX, Immediate(0)); | 500 __ movl(EAX, Immediate(0)); |
| 501 __ movl(ECX, Immediate(3)); | 501 __ movl(ECX, Immediate(3)); |
| 502 __ sarl(Address(ESP, 0), ECX); | 502 __ sarl(Address(ESP, 0), ECX); |
| 503 __ shrd(Address(ESP, 0), EAX); | 503 __ shrd(Address(ESP, 0), EAX); |
| 504 __ cmpl(Address(ESP, 0), Immediate(0x1e000000)); | 504 __ cmpl(Address(ESP, 0), Immediate(0x1e000000)); |
| 505 __ j(EQUAL, &donetest14); | 505 __ j(EQUAL, &donetest14); |
| 506 __ int3(); | 506 __ int3(); |
| 507 __ Bind(&donetest14); | 507 __ Bind(&donetest14); |
| 508 __ addl(ESP, Immediate(kWordSize)); | 508 __ addl(ESP, Immediate(kWordSize)); |
| 509 | 509 |
| 510 Label donetest15; |
| 511 __ subl(ESP, Immediate(kWordSize)); |
| 512 __ movl(Address(ESP, 0), Immediate(0xFF000000)); |
| 513 __ movl(EAX, Immediate(-1)); |
| 514 __ movl(ECX, Immediate(2)); |
| 515 __ shll(Address(ESP, 0), ECX); |
| 516 __ shld(Address(ESP, 0), EAX); |
| 517 __ cmpl(Address(ESP, 0), Immediate(0xF0000003)); |
| 518 __ j(EQUAL, &donetest15); |
| 519 __ int3(); |
| 520 __ Bind(&donetest15); |
| 521 __ addl(ESP, Immediate(kWordSize)); |
| 522 |
| 510 __ movl(EAX, Immediate(0)); | 523 __ movl(EAX, Immediate(0)); |
| 511 __ ret(); | 524 __ ret(); |
| 512 } | 525 } |
| 513 | 526 |
| 514 | 527 |
| 515 ASSEMBLER_TEST_RUN(LogicalOps, entry) { | 528 ASSEMBLER_TEST_RUN(LogicalOps, entry) { |
| 516 typedef int (*LogicalOpsCode)(); | 529 typedef int (*LogicalOpsCode)(); |
| 517 EXPECT_EQ(0, reinterpret_cast<LogicalOpsCode>(entry)()); | 530 EXPECT_EQ(0, reinterpret_cast<LogicalOpsCode>(entry)()); |
| 518 } | 531 } |
| 519 | 532 |
| (...skipping 1576 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2096 EAX); | 2109 EAX); |
| 2097 __ popl(EAX); | 2110 __ popl(EAX); |
| 2098 __ popl(CTX); | 2111 __ popl(CTX); |
| 2099 __ ret(); | 2112 __ ret(); |
| 2100 } | 2113 } |
| 2101 | 2114 |
| 2102 | 2115 |
| 2103 } // namespace dart | 2116 } // namespace dart |
| 2104 | 2117 |
| 2105 #endif // defined TARGET_ARCH_IA32 | 2118 #endif // defined TARGET_ARCH_IA32 |
| OLD | NEW |