| Index: src/x87/lithium-codegen-x87.cc
|
| diff --git a/src/x87/lithium-codegen-x87.cc b/src/x87/lithium-codegen-x87.cc
|
| index 13dfc17345f028d757d61387854e54aed7deee8f..d3f0a4b3e6b9c70a72948ffcc31e41f568290653 100644
|
| --- a/src/x87/lithium-codegen-x87.cc
|
| +++ b/src/x87/lithium-codegen-x87.cc
|
| @@ -3452,6 +3452,22 @@ void LCodeGen::DoLoadKeyedFixedArray(LLoadKeyed* instr) {
|
| __ cmp(result, factory()->the_hole_value());
|
| DeoptimizeIf(equal, instr, Deoptimizer::kHole);
|
| }
|
| + } else if (instr->hydrogen()->hole_mode() == CONVERT_HOLE_TO_UNDEFINED) {
|
| + DCHECK(instr->hydrogen()->elements_kind() == FAST_HOLEY_ELEMENTS);
|
| + Label done;
|
| + __ cmp(result, factory()->the_hole_value());
|
| + __ j(not_equal, &done);
|
| + if (info()->IsStub()) {
|
| + // A stub can safely convert the hole to undefined only if the array
|
| + // protector cell contains (Smi) Isolate::kArrayProtectorValid. Otherwise
|
| + // it needs to bail out.
|
| + __ mov(result, isolate()->factory()->array_protector());
|
| + __ cmp(FieldOperand(result, PropertyCell::kValueOffset),
|
| + Immediate(Smi::FromInt(Isolate::kArrayProtectorValid)));
|
| + DeoptimizeIf(not_equal, instr, Deoptimizer::kHole);
|
| + }
|
| + __ mov(result, isolate()->factory()->undefined_value());
|
| + __ bind(&done);
|
| }
|
| }
|
|
|
|
|