Back out cbf65998682c (bug 1112934) for SM(r) orange

CLOSED TREE
This commit is contained in:
Phil Ringnalda 2015-01-03 01:24:44 -08:00
parent 3d2cba0574
commit c86f1608b4
6 changed files with 10 additions and 56 deletions

View File

@ -9332,9 +9332,9 @@ CodeGenerator::visitGetDOMProperty(LGetDOMProperty *ins)
}
void
CodeGenerator::visitGetDOMMemberV(LGetDOMMemberV *ins)
CodeGenerator::visitGetDOMMember(LGetDOMMember *ins)
{
// It's simpler to duplicate visitLoadFixedSlotV here than it is to try to
// It's simple to duplicate visitLoadFixedSlotV here than it is to try to
// use an LLoadFixedSlotV or some subclass of it for this case: that would
// require us to have MGetDOMMember inherit from MLoadFixedSlot, and then
// we'd have to duplicate a bunch of stuff we now get for free from
@ -9346,22 +9346,6 @@ CodeGenerator::visitGetDOMMemberV(LGetDOMMemberV *ins)
masm.loadValue(Address(object, NativeObject::getFixedSlotOffset(slot)), result);
}
void
CodeGenerator::visitGetDOMMemberT(LGetDOMMemberT *ins)
{
// It's simpler to duplicate visitLoadFixedSlotT here than it is to try to
// use an LLoadFixedSlotT or some subclass of it for this case: that would
// require us to have MGetDOMMember inherit from MLoadFixedSlot, and then
// we'd have to duplicate a bunch of stuff we now get for free from
// MGetDOMProperty.
Register object = ToRegister(ins->object());
size_t slot = ins->mir()->domMemberSlotIndex();
AnyRegister result = ToAnyRegister(ins->getDef(0));
MIRType type = ins->mir()->type();
masm.loadUnboxedValue(Address(object, NativeObject::getFixedSlotOffset(slot)), type, result);
}
void
CodeGenerator::visitSetDOMProperty(LSetDOMProperty *ins)
{

View File

@ -305,8 +305,7 @@ class CodeGenerator : public CodeGeneratorSpecific
void visitCallInstanceOf(LCallInstanceOf *ins);
void visitProfilerStackOp(LProfilerStackOp *lir);
void visitGetDOMProperty(LGetDOMProperty *lir);
void visitGetDOMMemberV(LGetDOMMemberV *lir);
void visitGetDOMMemberT(LGetDOMMemberT *lir);
void visitGetDOMMember(LGetDOMMember *lir);
void visitSetDOMProperty(LSetDOMProperty *lir);
void visitCallDOMNative(LCallDOMNative *lir);
void visitCallGetIntrinsicValue(LCallGetIntrinsicValue *lir);

View File

@ -1750,28 +1750,11 @@ class LGetDOMProperty : public LDOMPropertyInstructionHelper<BOX_PIECES, 0>
}
};
class LGetDOMMemberV : public LInstructionHelper<BOX_PIECES, 1, 0>
class LGetDOMMember : public LInstructionHelper<BOX_PIECES, 1, 0>
{
public:
LIR_HEADER(GetDOMMemberV);
explicit LGetDOMMemberV(const LAllocation &object) {
setOperand(0, object);
}
const LAllocation *object() {
return getOperand(0);
}
MGetDOMMember *mir() const {
return mir_->toGetDOMMember();
}
};
class LGetDOMMemberT : public LInstructionHelper<1, 1, 0>
{
public:
LIR_HEADER(GetDOMMemberT);
explicit LGetDOMMemberT(const LAllocation &object) {
LIR_HEADER(GetDOMMember);
explicit LGetDOMMember(const LAllocation &object) {
setOperand(0, object);
}

View File

@ -316,8 +316,7 @@
_(InterruptCheckImplicit) \
_(ProfilerStackOp) \
_(GetDOMProperty) \
_(GetDOMMemberV) \
_(GetDOMMemberT) \
_(GetDOMMember) \
_(SetDOMProperty) \
_(CallDOMNative) \
_(IsCallable) \

View File

@ -3824,19 +3824,9 @@ LIRGenerator::visitGetDOMMember(MGetDOMMember *ins)
// value can in fact change as a result of DOM setters and method calls.
MOZ_ASSERT(ins->domAliasSet() != JSJitInfo::AliasEverything,
"Member gets had better not alias the world");
MDefinition *obj = ins->object();
MOZ_ASSERT(obj->type() == MIRType_Object);
MIRType type = ins->type();
if (type == MIRType_Value) {
LGetDOMMemberV *lir = new(alloc()) LGetDOMMemberV(useRegisterAtStart(obj));
defineBox(lir, ins);
} else {
LGetDOMMemberT *lir = new(alloc()) LGetDOMMemberT(useRegisterForTypedLoad(obj, type));
define(lir, ins);
}
LGetDOMMember *lir =
new(alloc()) LGetDOMMember(useRegisterAtStart(ins->object()));
defineBox(lir, ins);
}
void

View File

@ -10644,7 +10644,6 @@ class MGetDOMMember : public MGetDOMProperty
explicit MGetDOMMember(const JSJitInfo *jitinfo)
: MGetDOMProperty(jitinfo)
{
setResultType(MIRTypeFromValueType(jitinfo->returnType()));
}
public: