Chromium Code Reviews| Index: src/hydrogen.cc |
| =================================================================== |
| --- src/hydrogen.cc (revision 8228) |
| +++ src/hydrogen.cc (working copy) |
| @@ -1985,9 +1985,10 @@ |
| HBasicBlock* if_false = owner->graph()->CreateBasicBlock(); |
| if_true->MarkAsInlineReturnTarget(); |
| if_false->MarkAsInlineReturnTarget(); |
| + Expression* cond = TestContext::cast(owner->ast_context())->condition(); |
| // The AstContext constructor pushed on the context stack. This newed |
| // instance is the reason that AstContext can't be BASE_EMBEDDED. |
| - test_context_ = new TestContext(owner, if_true, if_false); |
| + test_context_ = new TestContext(owner, cond, if_true, if_false); |
|
Sven Panne
2011/06/09 10:07:57
Is this part of the change correct? I'm only 50% s
fschneider
2011/06/10 09:18:18
You probably want the call-instruction as the cond
Kevin Millikin (Chromium)
2011/06/10 09:35:06
I don't think you can specialize the individual re
|
| } else { |
| function_return_ = owner->graph()->CreateBasicBlock(); |
| function_return()->MarkAsInlineReturnTarget(); |
| @@ -2157,7 +2158,7 @@ |
| void HGraphBuilder::VisitForControl(Expression* expr, |
| HBasicBlock* true_block, |
| HBasicBlock* false_block) { |
| - TestContext for_test(this, true_block, false_block); |
| + TestContext for_test(this, expr, true_block, false_block); |
| Visit(expr); |
| } |