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

Side by Side Diff: src/arm/full-codegen-arm.cc

Issue 10824235: Fix the full compiler on ARM to always generate the same code (Closed) Base URL: http://v8.googlecode.com/svn/branches/bleeding_edge/
Patch Set: Created 8 years, 4 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
OLDNEW
1 // Copyright 2012 the V8 project authors. All rights reserved. 1 // Copyright 2012 the V8 project authors. All rights reserved.
2 // Redistribution and use in source and binary forms, with or without 2 // Redistribution and use in source and binary forms, with or without
3 // modification, are permitted provided that the following conditions are 3 // modification, are permitted provided that the following conditions are
4 // met: 4 // met:
5 // 5 //
6 // * Redistributions of source code must retain the above copyright 6 // * Redistributions of source code must retain the above copyright
7 // notice, this list of conditions and the following disclaimer. 7 // notice, this list of conditions and the following disclaimer.
8 // * Redistributions in binary form must reproduce the above 8 // * Redistributions in binary form must reproduce the above
9 // copyright notice, this list of conditions and the following 9 // copyright notice, this list of conditions and the following
10 // disclaimer in the documentation and/or other materials provided 10 // disclaimer in the documentation and/or other materials provided
(...skipping 655 matching lines...) Expand 10 before | Expand all | Expand 10 after
666 } else { 666 } else {
667 if (false_label_ != fall_through_) __ b(false_label_); 667 if (false_label_ != fall_through_) __ b(false_label_);
668 } 668 }
669 } 669 }
670 670
671 671
672 void FullCodeGenerator::DoTest(Expression* condition, 672 void FullCodeGenerator::DoTest(Expression* condition,
673 Label* if_true, 673 Label* if_true,
674 Label* if_false, 674 Label* if_false,
675 Label* fall_through) { 675 Label* fall_through) {
676 if (CpuFeatures::IsSupported(VFP2)) { 676 ToBooleanStub stub(result_register());
677 ToBooleanStub stub(result_register()); 677 __ CallStub(&stub);
678 __ CallStub(&stub); 678 __ tst(result_register(), result_register());
679 __ tst(result_register(), result_register());
680 } else {
681 // Call the runtime to find the boolean value of the source and then
682 // translate it into control flow to the pair of labels.
683 __ push(result_register());
684 __ CallRuntime(Runtime::kToBool, 1);
685 __ LoadRoot(ip, Heap::kFalseValueRootIndex);
686 __ cmp(r0, ip);
687 }
688 Split(ne, if_true, if_false, fall_through); 679 Split(ne, if_true, if_false, fall_through);
689 } 680 }
690 681
691 682
692 void FullCodeGenerator::Split(Condition cond, 683 void FullCodeGenerator::Split(Condition cond,
693 Label* if_true, 684 Label* if_true,
694 Label* if_false, 685 Label* if_false,
695 Label* fall_through) { 686 Label* fall_through) {
696 if (if_false == fall_through) { 687 if (if_false == fall_through) {
697 __ b(cond, if_true); 688 __ b(cond, if_true);
(...skipping 3875 matching lines...) Expand 10 before | Expand all | Expand 10 after
4573 *context_length = 0; 4564 *context_length = 0;
4574 return previous_; 4565 return previous_;
4575 } 4566 }
4576 4567
4577 4568
4578 #undef __ 4569 #undef __
4579 4570
4580 } } // namespace v8::internal 4571 } } // namespace v8::internal
4581 4572
4582 #endif // V8_TARGET_ARCH_ARM 4573 #endif // V8_TARGET_ARCH_ARM
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698