OLD | NEW |
1 // Copyright 2011 the V8 project authors. All rights reserved. | 1 // Copyright 2011 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 2096 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2107 LInstruction* LChunkBuilder::DoParameter(HParameter* instr) { | 2107 LInstruction* LChunkBuilder::DoParameter(HParameter* instr) { |
2108 int spill_index = chunk()->GetParameterStackSlot(instr->index()); | 2108 int spill_index = chunk()->GetParameterStackSlot(instr->index()); |
2109 return DefineAsSpilled(new LParameter, spill_index); | 2109 return DefineAsSpilled(new LParameter, spill_index); |
2110 } | 2110 } |
2111 | 2111 |
2112 | 2112 |
2113 LInstruction* LChunkBuilder::DoUnknownOSRValue(HUnknownOSRValue* instr) { | 2113 LInstruction* LChunkBuilder::DoUnknownOSRValue(HUnknownOSRValue* instr) { |
2114 int spill_index = chunk()->GetNextSpillIndex(false); // Not double-width. | 2114 int spill_index = chunk()->GetNextSpillIndex(false); // Not double-width. |
2115 if (spill_index > LUnallocated::kMaxFixedIndex) { | 2115 if (spill_index > LUnallocated::kMaxFixedIndex) { |
2116 Abort("Too many spill slots needed for OSR"); | 2116 Abort("Too many spill slots needed for OSR"); |
| 2117 spill_index = 0; |
2117 } | 2118 } |
2118 return DefineAsSpilled(new LUnknownOSRValue, spill_index); | 2119 return DefineAsSpilled(new LUnknownOSRValue, spill_index); |
2119 } | 2120 } |
2120 | 2121 |
2121 | 2122 |
2122 LInstruction* LChunkBuilder::DoCallStub(HCallStub* instr) { | 2123 LInstruction* LChunkBuilder::DoCallStub(HCallStub* instr) { |
2123 argument_count_ -= instr->argument_count(); | 2124 argument_count_ -= instr->argument_count(); |
2124 return MarkAsCall(DefineFixed(new LCallStub, rax), instr); | 2125 return MarkAsCall(DefineFixed(new LCallStub, rax), instr); |
2125 } | 2126 } |
2126 | 2127 |
(...skipping 100 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2227 LOperand* key = UseOrConstantAtStart(instr->key()); | 2228 LOperand* key = UseOrConstantAtStart(instr->key()); |
2228 LOperand* object = UseOrConstantAtStart(instr->object()); | 2229 LOperand* object = UseOrConstantAtStart(instr->object()); |
2229 LIn* result = new LIn(key, object); | 2230 LIn* result = new LIn(key, object); |
2230 return MarkAsCall(DefineFixed(result, rax), instr); | 2231 return MarkAsCall(DefineFixed(result, rax), instr); |
2231 } | 2232 } |
2232 | 2233 |
2233 | 2234 |
2234 } } // namespace v8::internal | 2235 } } // namespace v8::internal |
2235 | 2236 |
2236 #endif // V8_TARGET_ARCH_X64 | 2237 #endif // V8_TARGET_ARCH_X64 |
OLD | NEW |