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

Side by Side Diff: runtime/vm/assembler_ia32_test.cc

Issue 11085004: Faster 64-bit left-shift for ia32. (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/
Patch Set: addressed comments. Created 8 years, 2 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 unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « runtime/vm/assembler_ia32.cc ('k') | runtime/vm/flow_graph_optimizer.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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
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
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
OLDNEW
« no previous file with comments | « runtime/vm/assembler_ia32.cc ('k') | runtime/vm/flow_graph_optimizer.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698