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 2096 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2107 if (!instr->is_typed_elements()) { | 2107 if (!instr->is_typed_elements()) { |
2108 ASSERT(instr->elements()->representation().IsTagged()); | 2108 ASSERT(instr->elements()->representation().IsTagged()); |
2109 bool needs_write_barrier = instr->NeedsWriteBarrier(); | 2109 bool needs_write_barrier = instr->NeedsWriteBarrier(); |
2110 LOperand* object = NULL; | 2110 LOperand* object = NULL; |
2111 LOperand* key = NULL; | 2111 LOperand* key = NULL; |
2112 LOperand* val = NULL; | 2112 LOperand* val = NULL; |
2113 | 2113 |
2114 Representation value_representation = instr->value()->representation(); | 2114 Representation value_representation = instr->value()->representation(); |
2115 if (value_representation.IsDouble()) { | 2115 if (value_representation.IsDouble()) { |
2116 object = UseRegisterAtStart(instr->elements()); | 2116 object = UseRegisterAtStart(instr->elements()); |
2117 val = UseRegisterAtStart(instr->value()); | 2117 val = UseTempRegister(instr->value()); |
2118 key = UseRegisterOrConstantAtStart(instr->key()); | 2118 key = UseRegisterOrConstantAtStart(instr->key()); |
2119 } else { | 2119 } else { |
2120 ASSERT(value_representation.IsSmiOrTagged() || | 2120 ASSERT(value_representation.IsSmiOrTagged() || |
2121 value_representation.IsInteger32()); | 2121 value_representation.IsInteger32()); |
2122 if (needs_write_barrier) { | 2122 if (needs_write_barrier) { |
2123 object = UseTempRegister(instr->elements()); | 2123 object = UseTempRegister(instr->elements()); |
2124 val = UseTempRegister(instr->value()); | 2124 val = UseTempRegister(instr->value()); |
2125 key = UseTempRegister(instr->key()); | 2125 key = UseTempRegister(instr->key()); |
2126 } else { | 2126 } else { |
2127 object = UseRegisterAtStart(instr->elements()); | 2127 object = UseRegisterAtStart(instr->elements()); |
(...skipping 403 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2531 LInstruction* LChunkBuilder::DoLoadFieldByIndex(HLoadFieldByIndex* instr) { | 2531 LInstruction* LChunkBuilder::DoLoadFieldByIndex(HLoadFieldByIndex* instr) { |
2532 LOperand* object = UseRegister(instr->object()); | 2532 LOperand* object = UseRegister(instr->object()); |
2533 LOperand* index = UseTempRegister(instr->index()); | 2533 LOperand* index = UseTempRegister(instr->index()); |
2534 return DefineSameAsFirst(new(zone()) LLoadFieldByIndex(object, index)); | 2534 return DefineSameAsFirst(new(zone()) LLoadFieldByIndex(object, index)); |
2535 } | 2535 } |
2536 | 2536 |
2537 | 2537 |
2538 } } // namespace v8::internal | 2538 } } // namespace v8::internal |
2539 | 2539 |
2540 #endif // V8_TARGET_ARCH_X64 | 2540 #endif // V8_TARGET_ARCH_X64 |
OLD | NEW |