Index: src/x64/lithium-codegen-x64.cc |
diff --git a/src/x64/lithium-codegen-x64.cc b/src/x64/lithium-codegen-x64.cc |
index 1252003ee37e851a1c8c948c8a85326d53b9e662..070d0281e0616f6c47ae570a0b7c8c2cd344f65a 100644 |
--- a/src/x64/lithium-codegen-x64.cc |
+++ b/src/x64/lithium-codegen-x64.cc |
@@ -761,7 +761,6 @@ void LCodeGen::DeoptimizeIf(Condition cc, LEnvironment* environment) { |
__ j(cc, &jump_table_.last().label); |
} |
} |
- __ bind(&done); |
} |
@@ -3890,9 +3889,11 @@ void LCodeGen::DoCallNew(LCallNew* instr) { |
ASSERT(ToRegister(instr->result()).is(rax)); |
__ Set(rax, instr->arity()); |
- // No cell in ebx for construct type feedback in optimized code |
- Handle<Object> undefined_value(isolate()->factory()->undefined_value()); |
- __ Move(rbx, undefined_value); |
+ if (FLAG_optimize_constructed_arrays) { |
+ // No cell in ebx for construct type feedback in optimized code |
+ Handle<Object> undefined_value(isolate()->factory()->undefined_value()); |
+ __ Move(rbx, undefined_value); |
+ } |
CallConstructStub stub(NO_CALL_FUNCTION_FLAGS); |
CallCode(stub.GetCode(isolate()), RelocInfo::CONSTRUCT_CALL, instr); |
} |
@@ -3901,12 +3902,12 @@ void LCodeGen::DoCallNew(LCallNew* instr) { |
void LCodeGen::DoCallNewArray(LCallNewArray* instr) { |
ASSERT(ToRegister(instr->constructor()).is(rdi)); |
ASSERT(ToRegister(instr->result()).is(rax)); |
+ ASSERT(FLAG_optimize_constructed_arrays); |
__ Set(rax, instr->arity()); |
__ Move(rbx, instr->hydrogen()->property_cell()); |
Handle<Code> array_construct_code = |
isolate()->builtins()->ArrayConstructCode(); |
- |
CallCode(array_construct_code, RelocInfo::CONSTRUCT_CALL, instr); |
} |