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

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

Issue 1744163002: [stubs] Introduce a proper ToBooleanStub. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Fix mips Created 4 years, 9 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
OLDNEW
1 // Copyright 2012 the V8 project authors. All rights reserved. 1 // Copyright 2012 the V8 project authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #if V8_TARGET_ARCH_MIPS 5 #if V8_TARGET_ARCH_MIPS
6 6
7 // Note on Mips implementation: 7 // Note on Mips implementation:
8 // 8 //
9 // The result_register() for mips is the 'v0' register, which is defined 9 // The result_register() for mips is the 'v0' register, which is defined
10 // by the ABI to contain function return values. However, the first 10 // by the ABI to contain function return values. However, the first
(...skipping 619 matching lines...) Expand 10 before | Expand all | Expand 10 after
630 if (false_label_ != fall_through_) __ Branch(false_label_); 630 if (false_label_ != fall_through_) __ Branch(false_label_);
631 } 631 }
632 } 632 }
633 633
634 634
635 void FullCodeGenerator::DoTest(Expression* condition, 635 void FullCodeGenerator::DoTest(Expression* condition,
636 Label* if_true, 636 Label* if_true,
637 Label* if_false, 637 Label* if_false,
638 Label* fall_through) { 638 Label* fall_through) {
639 __ mov(a0, result_register()); 639 __ mov(a0, result_register());
640 Handle<Code> ic = ToBooleanStub::GetUninitialized(isolate()); 640 Handle<Code> ic = ToBooleanICStub::GetUninitialized(isolate());
641 CallIC(ic, condition->test_id()); 641 CallIC(ic, condition->test_id());
642 __ LoadRoot(at, Heap::kTrueValueRootIndex); 642 __ LoadRoot(at, Heap::kTrueValueRootIndex);
643 Split(eq, result_register(), Operand(at), if_true, if_false, fall_through); 643 Split(eq, result_register(), Operand(at), if_true, if_false, fall_through);
644 } 644 }
645 645
646 646
647 void FullCodeGenerator::Split(Condition cc, 647 void FullCodeGenerator::Split(Condition cc,
648 Register lhs, 648 Register lhs,
649 const Operand& rhs, 649 const Operand& rhs,
650 Label* if_true, 650 Label* if_true,
(...skipping 3565 matching lines...) Expand 10 before | Expand all | Expand 10 after
4216 reinterpret_cast<uint32_t>( 4216 reinterpret_cast<uint32_t>(
4217 isolate->builtins()->OsrAfterStackCheck()->entry())); 4217 isolate->builtins()->OsrAfterStackCheck()->entry()));
4218 return OSR_AFTER_STACK_CHECK; 4218 return OSR_AFTER_STACK_CHECK;
4219 } 4219 }
4220 4220
4221 4221
4222 } // namespace internal 4222 } // namespace internal
4223 } // namespace v8 4223 } // namespace v8
4224 4224
4225 #endif // V8_TARGET_ARCH_MIPS 4225 #endif // V8_TARGET_ARCH_MIPS
OLDNEW
« no previous file with comments | « src/full-codegen/ia32/full-codegen-ia32.cc ('k') | src/full-codegen/mips64/full-codegen-mips64.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698