| 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 2051 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2062 | 2062 |
| 2063 LInstruction* LChunkBuilder::DoDeleteProperty(HDeleteProperty* instr) { | 2063 LInstruction* LChunkBuilder::DoDeleteProperty(HDeleteProperty* instr) { |
| 2064 LOperand* object = UseFixed(instr->object(), a0); | 2064 LOperand* object = UseFixed(instr->object(), a0); |
| 2065 LOperand* key = UseFixed(instr->key(), a1); | 2065 LOperand* key = UseFixed(instr->key(), a1); |
| 2066 LDeleteProperty* result = new(zone()) LDeleteProperty(object, key); | 2066 LDeleteProperty* result = new(zone()) LDeleteProperty(object, key); |
| 2067 return MarkAsCall(DefineFixed(result, v0), instr); | 2067 return MarkAsCall(DefineFixed(result, v0), instr); |
| 2068 } | 2068 } |
| 2069 | 2069 |
| 2070 | 2070 |
| 2071 LInstruction* LChunkBuilder::DoOsrEntry(HOsrEntry* instr) { | 2071 LInstruction* LChunkBuilder::DoOsrEntry(HOsrEntry* instr) { |
| 2072 ASSERT(argument_count_ == 0); |
| 2072 allocator_->MarkAsOsrEntry(); | 2073 allocator_->MarkAsOsrEntry(); |
| 2073 current_block_->last_environment()->set_ast_id(instr->ast_id()); | 2074 current_block_->last_environment()->set_ast_id(instr->ast_id()); |
| 2074 return AssignEnvironment(new(zone()) LOsrEntry); | 2075 return AssignEnvironment(new(zone()) LOsrEntry); |
| 2075 } | 2076 } |
| 2076 | 2077 |
| 2077 | 2078 |
| 2078 LInstruction* LChunkBuilder::DoParameter(HParameter* instr) { | 2079 LInstruction* LChunkBuilder::DoParameter(HParameter* instr) { |
| 2079 int spill_index = chunk()->GetParameterStackSlot(instr->index()); | 2080 int spill_index = chunk()->GetParameterStackSlot(instr->index()); |
| 2080 return DefineAsSpilled(new(zone()) LParameter, spill_index); | 2081 return DefineAsSpilled(new(zone()) LParameter, spill_index); |
| 2081 } | 2082 } |
| (...skipping 119 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2201 chunk_->AddInlinedClosure(instr->closure()); | 2202 chunk_->AddInlinedClosure(instr->closure()); |
| 2202 return NULL; | 2203 return NULL; |
| 2203 } | 2204 } |
| 2204 | 2205 |
| 2205 | 2206 |
| 2206 LInstruction* LChunkBuilder::DoLeaveInlined(HLeaveInlined* instr) { | 2207 LInstruction* LChunkBuilder::DoLeaveInlined(HLeaveInlined* instr) { |
| 2207 LInstruction* pop = NULL; | 2208 LInstruction* pop = NULL; |
| 2208 | 2209 |
| 2209 HEnvironment* env = current_block_->last_environment(); | 2210 HEnvironment* env = current_block_->last_environment(); |
| 2210 | 2211 |
| 2211 if (instr->arguments_pushed()) { | 2212 if (env->entry()->arguments_pushed()) { |
| 2212 int argument_count = env->arguments_environment()->parameter_count(); | 2213 int argument_count = env->arguments_environment()->parameter_count(); |
| 2213 pop = new(zone()) LDrop(argument_count); | 2214 pop = new(zone()) LDrop(argument_count); |
| 2214 argument_count_ -= argument_count; | 2215 argument_count_ -= argument_count; |
| 2215 } | 2216 } |
| 2216 | 2217 |
| 2217 HEnvironment* outer = current_block_->last_environment()-> | 2218 HEnvironment* outer = current_block_->last_environment()-> |
| 2218 DiscardInlined(false); | 2219 DiscardInlined(false); |
| 2219 current_block_->UpdateEnvironment(outer); | 2220 current_block_->UpdateEnvironment(outer); |
| 2220 | 2221 |
| 2221 return pop; | 2222 return pop; |
| (...skipping 31 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2253 | 2254 |
| 2254 | 2255 |
| 2255 LInstruction* LChunkBuilder::DoLoadFieldByIndex(HLoadFieldByIndex* instr) { | 2256 LInstruction* LChunkBuilder::DoLoadFieldByIndex(HLoadFieldByIndex* instr) { |
| 2256 LOperand* object = UseRegister(instr->object()); | 2257 LOperand* object = UseRegister(instr->object()); |
| 2257 LOperand* index = UseRegister(instr->index()); | 2258 LOperand* index = UseRegister(instr->index()); |
| 2258 return DefineAsRegister(new(zone()) LLoadFieldByIndex(object, index)); | 2259 return DefineAsRegister(new(zone()) LLoadFieldByIndex(object, index)); |
| 2259 } | 2260 } |
| 2260 | 2261 |
| 2261 | 2262 |
| 2262 } } // namespace v8::internal | 2263 } } // namespace v8::internal |
| OLD | NEW |