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

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

Issue 1317383002: Crankshaft is now able to compile top level code even if there is a ScriptContext. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Rebasing Created 5 years, 3 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
« no previous file with comments | « src/ia32/lithium-ia32.h ('k') | src/mips/lithium-codegen-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 // 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 #include <sstream> 5 #include <sstream>
6 6
7 #if V8_TARGET_ARCH_IA32 7 #if V8_TARGET_ARCH_IA32
8 8
9 #include "src/hydrogen-osr.h" 9 #include "src/hydrogen-osr.h"
10 #include "src/ia32/lithium-codegen-ia32.h" 10 #include "src/ia32/lithium-codegen-ia32.h"
(...skipping 937 matching lines...) Expand 10 before | Expand all | Expand 10 after
948 #endif 948 #endif
949 949
950 if (FLAG_stress_pointer_maps && !instr->HasPointerMap()) { 950 if (FLAG_stress_pointer_maps && !instr->HasPointerMap()) {
951 instr = AssignPointerMap(instr); 951 instr = AssignPointerMap(instr);
952 } 952 }
953 if (FLAG_stress_environments && !instr->HasEnvironment()) { 953 if (FLAG_stress_environments && !instr->HasEnvironment()) {
954 instr = AssignEnvironment(instr); 954 instr = AssignEnvironment(instr);
955 } 955 }
956 chunk_->AddInstruction(instr, current_block_); 956 chunk_->AddInstruction(instr, current_block_);
957 957
958 if (instr->IsCall()) { 958 if (instr->IsCall() || instr->IsPrologue()) {
959 HValue* hydrogen_value_for_lazy_bailout = hydrogen_val; 959 HValue* hydrogen_value_for_lazy_bailout = hydrogen_val;
960 if (hydrogen_val->HasObservableSideEffects()) { 960 if (hydrogen_val->HasObservableSideEffects()) {
961 HSimulate* sim = HSimulate::cast(hydrogen_val->next()); 961 HSimulate* sim = HSimulate::cast(hydrogen_val->next());
962 sim->ReplayEnvironment(current_block_->last_environment()); 962 sim->ReplayEnvironment(current_block_->last_environment());
963 hydrogen_value_for_lazy_bailout = sim; 963 hydrogen_value_for_lazy_bailout = sim;
964 } 964 }
965 LInstruction* bailout = AssignEnvironment(new(zone()) LLazyBailout()); 965 LInstruction* bailout = AssignEnvironment(new(zone()) LLazyBailout());
966 bailout->set_hydrogen_value(hydrogen_value_for_lazy_bailout); 966 bailout->set_hydrogen_value(hydrogen_value_for_lazy_bailout);
967 chunk_->AddInstruction(bailout, current_block_); 967 chunk_->AddInstruction(bailout, current_block_);
968 } 968 }
969 } 969 }
970 970
971 971
972 LInstruction* LChunkBuilder::DoPrologue(HPrologue* instr) {
973 return new (zone()) LPrologue();
974 }
975
976
972 LInstruction* LChunkBuilder::DoGoto(HGoto* instr) { 977 LInstruction* LChunkBuilder::DoGoto(HGoto* instr) {
973 return new(zone()) LGoto(instr->FirstSuccessor()); 978 return new(zone()) LGoto(instr->FirstSuccessor());
974 } 979 }
975 980
976 981
977 LInstruction* LChunkBuilder::DoBranch(HBranch* instr) { 982 LInstruction* LChunkBuilder::DoBranch(HBranch* instr) {
978 HValue* value = instr->value(); 983 HValue* value = instr->value();
979 Representation r = value->representation(); 984 Representation r = value->representation();
980 HType type = value->type(); 985 HType type = value->type();
981 ToBooleanStub::Types expected = instr->expected_input_types(); 986 ToBooleanStub::Types expected = instr->expected_input_types();
(...skipping 1772 matching lines...) Expand 10 before | Expand all | Expand 10 after
2754 LAllocateBlockContext* result = 2759 LAllocateBlockContext* result =
2755 new(zone()) LAllocateBlockContext(context, function); 2760 new(zone()) LAllocateBlockContext(context, function);
2756 return MarkAsCall(DefineFixed(result, esi), instr); 2761 return MarkAsCall(DefineFixed(result, esi), instr);
2757 } 2762 }
2758 2763
2759 2764
2760 } // namespace internal 2765 } // namespace internal
2761 } // namespace v8 2766 } // namespace v8
2762 2767
2763 #endif // V8_TARGET_ARCH_IA32 2768 #endif // V8_TARGET_ARCH_IA32
OLDNEW
« no previous file with comments | « src/ia32/lithium-ia32.h ('k') | src/mips/lithium-codegen-mips.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698