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

Side by Side Diff: src/x64/lithium-codegen-x64.cc

Issue 292993003: Revert "Refactor transitioning stores." (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Created 6 years, 7 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 | Annotate | Revision Log
« no previous file with comments | « src/lithium-codegen.cc ('k') | src/x64/lithium-x64.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 2013 the V8 project authors. All rights reserved. 1 // Copyright 2013 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 "v8.h" 5 #include "v8.h"
6 6
7 #if V8_TARGET_ARCH_X64 7 #if V8_TARGET_ARCH_X64
8 8
9 #include "x64/lithium-codegen-x64.h" 9 #include "x64/lithium-codegen-x64.h"
10 #include "code-stubs.h" 10 #include "code-stubs.h"
(...skipping 4003 matching lines...) Expand 10 before | Expand all | Expand 10 after
4014 Register value = ToRegister(instr->value()); 4014 Register value = ToRegister(instr->value());
4015 Condition cc = masm()->CheckSmi(value); 4015 Condition cc = masm()->CheckSmi(value);
4016 DeoptimizeIf(cc, instr->environment()); 4016 DeoptimizeIf(cc, instr->environment());
4017 4017
4018 // We know now that value is not a smi, so we can omit the check below. 4018 // We know now that value is not a smi, so we can omit the check below.
4019 check_needed = OMIT_SMI_CHECK; 4019 check_needed = OMIT_SMI_CHECK;
4020 } 4020 }
4021 } 4021 }
4022 } else if (representation.IsDouble()) { 4022 } else if (representation.IsDouble()) {
4023 ASSERT(access.IsInobject()); 4023 ASSERT(access.IsInobject());
4024 ASSERT(!hinstr->has_transition());
4024 ASSERT(!hinstr->NeedsWriteBarrier()); 4025 ASSERT(!hinstr->NeedsWriteBarrier());
4025 XMMRegister value = ToDoubleRegister(instr->value()); 4026 XMMRegister value = ToDoubleRegister(instr->value());
4026 __ movsd(FieldOperand(object, offset), value); 4027 __ movsd(FieldOperand(object, offset), value);
4027 return; 4028 return;
4028 } 4029 }
4029 4030
4031 if (hinstr->has_transition()) {
4032 Handle<Map> transition = hinstr->transition_map();
4033 AddDeprecationDependency(transition);
4034 if (!hinstr->NeedsWriteBarrierForMap()) {
4035 __ Move(FieldOperand(object, HeapObject::kMapOffset), transition);
4036 } else {
4037 Register temp = ToRegister(instr->temp());
4038 __ Move(kScratchRegister, transition);
4039 __ movp(FieldOperand(object, HeapObject::kMapOffset), kScratchRegister);
4040 // Update the write barrier for the map field.
4041 __ RecordWriteField(object,
4042 HeapObject::kMapOffset,
4043 kScratchRegister,
4044 temp,
4045 kSaveFPRegs,
4046 OMIT_REMEMBERED_SET,
4047 OMIT_SMI_CHECK);
4048 }
4049 }
4050
4030 // Do the store. 4051 // Do the store.
4031 Register write_register = object; 4052 Register write_register = object;
4032 if (!access.IsInobject()) { 4053 if (!access.IsInobject()) {
4033 write_register = ToRegister(instr->temp()); 4054 write_register = ToRegister(instr->temp());
4034 __ movp(write_register, FieldOperand(object, JSObject::kPropertiesOffset)); 4055 __ movp(write_register, FieldOperand(object, JSObject::kPropertiesOffset));
4035 } 4056 }
4036 4057
4037 if (representation.IsSmi() && SmiValuesAre32Bits() && 4058 if (representation.IsSmi() && SmiValuesAre32Bits() &&
4038 hinstr->value()->representation().IsInteger32()) { 4059 hinstr->value()->representation().IsInteger32()) {
4039 ASSERT(hinstr->store_mode() == STORE_TO_INITIALIZED_ENTRY); 4060 ASSERT(hinstr->store_mode() == STORE_TO_INITIALIZED_ENTRY);
(...skipping 1659 matching lines...) Expand 10 before | Expand all | Expand 10 after
5699 __ bind(deferred->exit()); 5720 __ bind(deferred->exit());
5700 __ bind(&done); 5721 __ bind(&done);
5701 } 5722 }
5702 5723
5703 5724
5704 #undef __ 5725 #undef __
5705 5726
5706 } } // namespace v8::internal 5727 } } // namespace v8::internal
5707 5728
5708 #endif // V8_TARGET_ARCH_X64 5729 #endif // V8_TARGET_ARCH_X64
OLDNEW
« no previous file with comments | « src/lithium-codegen.cc ('k') | src/x64/lithium-x64.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698