| Index: src/a64/lithium-codegen-a64.cc
|
| diff --git a/src/a64/lithium-codegen-a64.cc b/src/a64/lithium-codegen-a64.cc
|
| index da03ccc214700a949048b590d342a434f84521c2..875b4505cb33f800d66b7d0510315b450afe6c25 100644
|
| --- a/src/a64/lithium-codegen-a64.cc
|
| +++ b/src/a64/lithium-codegen-a64.cc
|
| @@ -5051,11 +5051,17 @@ void LCodeGen::DoStoreNamedField(LStoreNamedField* instr) {
|
| }
|
|
|
| Handle<Map> transition = instr->transition();
|
| + SmiCheck check_needed =
|
| + instr->hydrogen()->value()->IsHeapObject()
|
| + ? OMIT_SMI_CHECK : INLINE_SMI_CHECK;
|
|
|
| if (FLAG_track_heap_object_fields && representation.IsHeapObject()) {
|
| Register value = ToRegister(instr->value());
|
| if (!instr->hydrogen()->value()->type().IsHeapObject()) {
|
| DeoptimizeIfSmi(value, instr->environment());
|
| +
|
| + // We know that value is a smi now, so we can omit the check below.
|
| + check_needed = OMIT_SMI_CHECK;
|
| }
|
| } else if (representation.IsDouble()) {
|
| ASSERT(transition.is_null());
|
| @@ -5087,9 +5093,6 @@ void LCodeGen::DoStoreNamedField(LStoreNamedField* instr) {
|
| // Do the store.
|
| Register value = ToRegister(instr->value());
|
| Register destination;
|
| - SmiCheck check_needed =
|
| - instr->hydrogen()->value()->IsHeapObject()
|
| - ? OMIT_SMI_CHECK : INLINE_SMI_CHECK;
|
| if (access.IsInobject()) {
|
| destination = object;
|
| } else {
|
|
|