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

Unified Diff: src/arm/codegen-arm.cc

Issue 155272: Address review comments.... (Closed) Base URL: http://v8.googlecode.com/svn/branches/bleeding_edge/
Patch Set: Created 11 years, 5 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/arm/codegen-arm.cc
===================================================================
--- src/arm/codegen-arm.cc (revision 2401)
+++ src/arm/codegen-arm.cc (working copy)
@@ -2421,26 +2421,22 @@
Comment cmnt(masm_, "[ Conditional");
JumpTarget then;
JumpTarget else_;
- JumpTarget exit;
LoadConditionAndSpill(node->condition(), NOT_INSIDE_TYPEOF,
&then, &else_, true);
- if (frame_ != NULL) {
+ if (has_valid_frame()) {
Branch(false, &else_);
}
- if (frame_ != NULL || then.is_linked()) {
+ if (has_valid_frame() || then.is_linked()) {
then.Bind();
LoadAndSpill(node->then_expression(), typeof_state());
}
- if (frame_ != NULL) {
- exit.Jump();
- }
if (else_.is_linked()) {
+ JumpTarget exit;
+ if (has_valid_frame()) exit.Jump();
else_.Bind();
LoadAndSpill(node->else_expression(), typeof_state());
+ if (exit.is_linked()) exit.Bind();
}
- if (exit.is_linked()) {
- exit.Bind();
- }
ASSERT(frame_->height() == original_height + 1);
}
@@ -3615,9 +3611,8 @@
false_target(),
true_target(),
true);
- // LoadConditionAndSpill might emit only unconditional jumps to
- // the targets in which case cc_reg_ is not set. When that
- // happens, don't attempt to negate the condition.
+ // LoadCondition may (and usually does) leave a test and branch to
+ // be emitted by the caller. In that case, negate the condition.
if (has_cc()) cc_reg_ = NegateCondition(cc_reg_);
} else if (op == Token::DELETE) {
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698