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

Side by Side Diff: src/ia32/lithium-ia32.cc

Issue 16938009: Fix bogus replay of arguments object binding in LChunkBuilder. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Created 7 years, 6 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 | « src/arm/lithium-arm.cc ('k') | src/mips/lithium-mips.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 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 2716 matching lines...) Expand 10 before | Expand all | Expand 10 after
2727 2727
2728 LInstruction* LChunkBuilder::DoEnterInlined(HEnterInlined* instr) { 2728 LInstruction* LChunkBuilder::DoEnterInlined(HEnterInlined* instr) {
2729 HEnvironment* outer = current_block_->last_environment(); 2729 HEnvironment* outer = current_block_->last_environment();
2730 HConstant* undefined = graph()->GetConstantUndefined(); 2730 HConstant* undefined = graph()->GetConstantUndefined();
2731 HEnvironment* inner = outer->CopyForInlining(instr->closure(), 2731 HEnvironment* inner = outer->CopyForInlining(instr->closure(),
2732 instr->arguments_count(), 2732 instr->arguments_count(),
2733 instr->function(), 2733 instr->function(),
2734 undefined, 2734 undefined,
2735 instr->inlining_kind(), 2735 instr->inlining_kind(),
2736 instr->undefined_receiver()); 2736 instr->undefined_receiver());
2737 if (instr->arguments_var() != NULL) { 2737 // Only replay binding of arguments object if it wasn't removed from graph.
2738 inner->Bind(instr->arguments_var(), graph()->GetArgumentsObject()); 2738 if (instr->arguments_var() != NULL && instr->arguments_object()->IsLinked()) {
2739 inner->Bind(instr->arguments_var(), instr->arguments_object());
2739 } 2740 }
2740 inner->set_entry(instr); 2741 inner->set_entry(instr);
2741 current_block_->UpdateEnvironment(inner); 2742 current_block_->UpdateEnvironment(inner);
2742 chunk_->AddInlinedClosure(instr->closure()); 2743 chunk_->AddInlinedClosure(instr->closure());
2743 return NULL; 2744 return NULL;
2744 } 2745 }
2745 2746
2746 2747
2747 LInstruction* LChunkBuilder::DoLeaveInlined(HLeaveInlined* instr) { 2748 LInstruction* LChunkBuilder::DoLeaveInlined(HLeaveInlined* instr) {
2748 LInstruction* pop = NULL; 2749 LInstruction* pop = NULL;
(...skipping 47 matching lines...) Expand 10 before | Expand all | Expand 10 after
2796 LInstruction* LChunkBuilder::DoLoadFieldByIndex(HLoadFieldByIndex* instr) { 2797 LInstruction* LChunkBuilder::DoLoadFieldByIndex(HLoadFieldByIndex* instr) {
2797 LOperand* object = UseRegister(instr->object()); 2798 LOperand* object = UseRegister(instr->object());
2798 LOperand* index = UseTempRegister(instr->index()); 2799 LOperand* index = UseTempRegister(instr->index());
2799 return DefineSameAsFirst(new(zone()) LLoadFieldByIndex(object, index)); 2800 return DefineSameAsFirst(new(zone()) LLoadFieldByIndex(object, index));
2800 } 2801 }
2801 2802
2802 2803
2803 } } // namespace v8::internal 2804 } } // namespace v8::internal
2804 2805
2805 #endif // V8_TARGET_ARCH_IA32 2806 #endif // V8_TARGET_ARCH_IA32
OLDNEW
« no previous file with comments | « src/arm/lithium-arm.cc ('k') | src/mips/lithium-mips.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698