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

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

Issue 1089003002: Implement bigint shift intrinsics on IA32. (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/
Patch Set: Created 5 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 unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « runtime/vm/assembler_ia32.cc ('k') | runtime/vm/assembler_x64.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/cpu.h" 9 #include "vm/cpu.h"
10 #include "vm/os.h" 10 #include "vm/os.h"
(...skipping 561 matching lines...) Expand 10 before | Expand all | Expand 10 after
572 __ movl(EAX, Immediate(0)); 572 __ movl(EAX, Immediate(0));
573 __ movl(Address(EAX, 0), EAX); 573 __ movl(Address(EAX, 0), EAX);
574 __ Bind(&donetest13); 574 __ Bind(&donetest13);
575 575
576 Label donetest14; 576 Label donetest14;
577 __ subl(ESP, Immediate(kWordSize)); 577 __ subl(ESP, Immediate(kWordSize));
578 __ movl(Address(ESP, 0), Immediate(0x80000000)); 578 __ movl(Address(ESP, 0), Immediate(0x80000000));
579 __ movl(EAX, Immediate(0)); 579 __ movl(EAX, Immediate(0));
580 __ movl(ECX, Immediate(3)); 580 __ movl(ECX, Immediate(3));
581 __ sarl(Address(ESP, 0), ECX); 581 __ sarl(Address(ESP, 0), ECX);
582 __ shrdl(Address(ESP, 0), EAX); 582 __ shrdl(Address(ESP, 0), EAX, ECX);
583 __ cmpl(Address(ESP, 0), Immediate(0x1e000000)); 583 __ cmpl(Address(ESP, 0), Immediate(0x1e000000));
584 __ j(EQUAL, &donetest14); 584 __ j(EQUAL, &donetest14);
585 __ int3(); 585 __ int3();
586 __ Bind(&donetest14); 586 __ Bind(&donetest14);
587 __ addl(ESP, Immediate(kWordSize)); 587 __ addl(ESP, Immediate(kWordSize));
588 588
589 Label donetest15; 589 Label donetest15;
590 __ subl(ESP, Immediate(kWordSize)); 590 __ subl(ESP, Immediate(kWordSize));
591 __ movl(Address(ESP, 0), Immediate(0xFF000000)); 591 __ movl(Address(ESP, 0), Immediate(0xFF000000));
592 __ movl(EAX, Immediate(-1)); 592 __ movl(EAX, Immediate(-1));
593 __ movl(ECX, Immediate(2)); 593 __ movl(ECX, Immediate(2));
594 __ shll(Address(ESP, 0), ECX); 594 __ shll(Address(ESP, 0), ECX);
595 __ shldl(Address(ESP, 0), EAX); 595 __ shldl(Address(ESP, 0), EAX, ECX);
596 __ cmpl(Address(ESP, 0), Immediate(0xF0000003)); 596 __ cmpl(Address(ESP, 0), Immediate(0xF0000003));
597 __ j(EQUAL, &donetest15); 597 __ j(EQUAL, &donetest15);
598 __ int3(); 598 __ int3();
599 __ Bind(&donetest15); 599 __ Bind(&donetest15);
600 __ addl(ESP, Immediate(kWordSize)); 600 __ addl(ESP, Immediate(kWordSize));
601 601
602 Label donetest16; 602 Label donetest16;
603 __ movl(EDX, Immediate(0x80000000)); 603 __ movl(EDX, Immediate(0x80000000));
604 __ movl(EAX, Immediate(0)); 604 __ movl(EAX, Immediate(0));
605 __ movl(ECX, Immediate(3)); 605 __ movl(ECX, Immediate(3));
(...skipping 2867 matching lines...) Expand 10 before | Expand all | Expand 10 after
3473 EXPECT_EQ(ICData::kInt64RangeBit, range_of(Integer::New(kMaxInt64))); 3473 EXPECT_EQ(ICData::kInt64RangeBit, range_of(Integer::New(kMaxInt64)));
3474 EXPECT_EQ(ICData::kInt64RangeBit, range_of(Integer::New(kMinInt64))); 3474 EXPECT_EQ(ICData::kInt64RangeBit, range_of(Integer::New(kMinInt64)));
3475 3475
3476 EXPECT_EQ(-1, range_of(Bool::True().raw())); 3476 EXPECT_EQ(-1, range_of(Bool::True().raw()));
3477 } 3477 }
3478 3478
3479 3479
3480 } // namespace dart 3480 } // namespace dart
3481 3481
3482 #endif // defined TARGET_ARCH_IA32 3482 #endif // defined TARGET_ARCH_IA32
OLDNEW
« no previous file with comments | « runtime/vm/assembler_ia32.cc ('k') | runtime/vm/assembler_x64.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698