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

Unified Diff: src/arm/lithium-codegen-arm.cc

Issue 324093002: ARM/ARM64: Optimise HLoadNamedField and HStoreNamedField. Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Upload the correct patch (minor diff in hydrogen.h) Created 6 years, 6 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 side-by-side diff with in-line comments
Download patch
Index: src/arm/lithium-codegen-arm.cc
diff --git a/src/arm/lithium-codegen-arm.cc b/src/arm/lithium-codegen-arm.cc
index f852f3de712c45112b351d424c9078e2a1cab2c6..776b55edc3a9a99a26a38e0c1f67f0248ebf350a 100644
--- a/src/arm/lithium-codegen-arm.cc
+++ b/src/arm/lithium-codegen-arm.cc
@@ -3054,11 +3054,16 @@ void LCodeGen::DoLoadNamedField(LLoadNamedField* instr) {
}
Register result = ToRegister(instr->result());
+ Register source = object;
if (!access.IsInobject()) {
- __ ldr(result, FieldMemOperand(object, JSObject::kPropertiesOffset));
- object = result;
+ if (instr->object_properties()) {
+ source = ToRegister(instr->object_properties());
+ } else {
+ __ ldr(result, FieldMemOperand(object, JSObject::kPropertiesOffset));
+ source = result;
+ }
}
- MemOperand operand = FieldMemOperand(object, offset);
+ MemOperand operand = FieldMemOperand(source, offset);
__ Load(result, operand, access.representation());
}
@@ -4110,7 +4115,13 @@ void LCodeGen::DoStoreNamedField(LStoreNamedField* instr) {
instr->hydrogen()->PointersToHereCheckForValue());
}
} else {
- __ ldr(scratch, FieldMemOperand(object, JSObject::kPropertiesOffset));
+ Register destination;
+ if (instr->object_properties()) {
+ destination = ToRegister(instr->object_properties());
+ } else {
+ __ ldr(scratch, FieldMemOperand(object, JSObject::kPropertiesOffset));
+ destination = scratch;
+ }
MemOperand operand = FieldMemOperand(scratch, offset);
__ Store(value, operand, representation);
if (instr->hydrogen()->NeedsWriteBarrier()) {
« no previous file with comments | « src/arm/lithium-arm.cc ('k') | src/arm64/lithium-arm64.h » ('j') | src/hydrogen-instructions.h » ('J')

Powered by Google App Engine
This is Rietveld 408576698