| OLD | NEW |
| 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 2107 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2118 | 2118 |
| 2119 LInstruction* LChunkBuilder::DoDeleteProperty(HDeleteProperty* instr) { | 2119 LInstruction* LChunkBuilder::DoDeleteProperty(HDeleteProperty* instr) { |
| 2120 LOperand* object = UseFixed(instr->object(), r0); | 2120 LOperand* object = UseFixed(instr->object(), r0); |
| 2121 LOperand* key = UseFixed(instr->key(), r1); | 2121 LOperand* key = UseFixed(instr->key(), r1); |
| 2122 LDeleteProperty* result = new(zone()) LDeleteProperty(object, key); | 2122 LDeleteProperty* result = new(zone()) LDeleteProperty(object, key); |
| 2123 return MarkAsCall(DefineFixed(result, r0), instr); | 2123 return MarkAsCall(DefineFixed(result, r0), instr); |
| 2124 } | 2124 } |
| 2125 | 2125 |
| 2126 | 2126 |
| 2127 LInstruction* LChunkBuilder::DoOsrEntry(HOsrEntry* instr) { | 2127 LInstruction* LChunkBuilder::DoOsrEntry(HOsrEntry* instr) { |
| 2128 ASSERT(argument_count_ == 0); |
| 2128 allocator_->MarkAsOsrEntry(); | 2129 allocator_->MarkAsOsrEntry(); |
| 2129 current_block_->last_environment()->set_ast_id(instr->ast_id()); | 2130 current_block_->last_environment()->set_ast_id(instr->ast_id()); |
| 2130 return AssignEnvironment(new(zone()) LOsrEntry); | 2131 return AssignEnvironment(new(zone()) LOsrEntry); |
| 2131 } | 2132 } |
| 2132 | 2133 |
| 2133 | 2134 |
| 2134 LInstruction* LChunkBuilder::DoParameter(HParameter* instr) { | 2135 LInstruction* LChunkBuilder::DoParameter(HParameter* instr) { |
| 2135 int spill_index = chunk()->GetParameterStackSlot(instr->index()); | 2136 int spill_index = chunk()->GetParameterStackSlot(instr->index()); |
| 2136 return DefineAsSpilled(new(zone()) LParameter, spill_index); | 2137 return DefineAsSpilled(new(zone()) LParameter, spill_index); |
| 2137 } | 2138 } |
| (...skipping 119 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2257 chunk_->AddInlinedClosure(instr->closure()); | 2258 chunk_->AddInlinedClosure(instr->closure()); |
| 2258 return NULL; | 2259 return NULL; |
| 2259 } | 2260 } |
| 2260 | 2261 |
| 2261 | 2262 |
| 2262 LInstruction* LChunkBuilder::DoLeaveInlined(HLeaveInlined* instr) { | 2263 LInstruction* LChunkBuilder::DoLeaveInlined(HLeaveInlined* instr) { |
| 2263 LInstruction* pop = NULL; | 2264 LInstruction* pop = NULL; |
| 2264 | 2265 |
| 2265 HEnvironment* env = current_block_->last_environment(); | 2266 HEnvironment* env = current_block_->last_environment(); |
| 2266 | 2267 |
| 2267 if (instr->arguments_pushed()) { | 2268 if (env->entry()->arguments_pushed()) { |
| 2268 int argument_count = env->arguments_environment()->parameter_count(); | 2269 int argument_count = env->arguments_environment()->parameter_count(); |
| 2269 pop = new(zone()) LDrop(argument_count); | 2270 pop = new(zone()) LDrop(argument_count); |
| 2270 argument_count_ -= argument_count; | 2271 argument_count_ -= argument_count; |
| 2271 } | 2272 } |
| 2272 | 2273 |
| 2273 HEnvironment* outer = current_block_->last_environment()-> | 2274 HEnvironment* outer = current_block_->last_environment()-> |
| 2274 DiscardInlined(false); | 2275 DiscardInlined(false); |
| 2275 current_block_->UpdateEnvironment(outer); | 2276 current_block_->UpdateEnvironment(outer); |
| 2276 | 2277 |
| 2277 return pop; | 2278 return pop; |
| (...skipping 31 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2309 | 2310 |
| 2310 | 2311 |
| 2311 LInstruction* LChunkBuilder::DoLoadFieldByIndex(HLoadFieldByIndex* instr) { | 2312 LInstruction* LChunkBuilder::DoLoadFieldByIndex(HLoadFieldByIndex* instr) { |
| 2312 LOperand* object = UseRegister(instr->object()); | 2313 LOperand* object = UseRegister(instr->object()); |
| 2313 LOperand* index = UseRegister(instr->index()); | 2314 LOperand* index = UseRegister(instr->index()); |
| 2314 return DefineAsRegister(new(zone()) LLoadFieldByIndex(object, index)); | 2315 return DefineAsRegister(new(zone()) LLoadFieldByIndex(object, index)); |
| 2315 } | 2316 } |
| 2316 | 2317 |
| 2317 | 2318 |
| 2318 } } // namespace v8::internal | 2319 } } // namespace v8::internal |
| OLD | NEW |