mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-10-25 03:05:34 +00:00
Backed out changeset 74d0a284f6ff (bug 1278303)
This commit is contained in:
parent
6dfb5f0411
commit
ca91e1647e
@ -71,7 +71,7 @@ LoopUnroller::getReplacementDefinition(MDefinition* def)
|
|||||||
// the block itself.
|
// the block itself.
|
||||||
MOZ_ASSERT(def->isConstant());
|
MOZ_ASSERT(def->isConstant());
|
||||||
|
|
||||||
MConstant* constant = MConstant::Copy(alloc, def->toConstant());
|
MConstant* constant = new(alloc) MConstant(*def->toConstant());
|
||||||
oldPreheader->insertBefore(*oldPreheader->begin(), constant);
|
oldPreheader->insertBefore(*oldPreheader->begin(), constant);
|
||||||
return constant;
|
return constant;
|
||||||
}
|
}
|
||||||
|
@ -1019,17 +1019,6 @@ class MInstruction
|
|||||||
{
|
{
|
||||||
MResumePoint* resumePoint_;
|
MResumePoint* resumePoint_;
|
||||||
|
|
||||||
protected:
|
|
||||||
// All MInstructions are using the "MFoo::New(alloc)" notation instead of
|
|
||||||
// the TempObject new operator. This code redefines the new operator as
|
|
||||||
// protected, and delegates to the TempObject new operator. Thus, the
|
|
||||||
// following code prevents calls to "new(alloc) MFoo" outside the MFoo
|
|
||||||
// members.
|
|
||||||
template <typename... Args>
|
|
||||||
inline void* operator new(size_t nbytes, Args&&... args) {
|
|
||||||
return TempObject::operator new(nbytes, mozilla::Forward<Args>(args)...);
|
|
||||||
}
|
|
||||||
|
|
||||||
public:
|
public:
|
||||||
MInstruction()
|
MInstruction()
|
||||||
: resumePoint_(nullptr)
|
: resumePoint_(nullptr)
|
||||||
@ -1458,9 +1447,6 @@ class MConstant : public MNullaryInstruction
|
|||||||
static MConstant* NewInt64(TempAllocator& alloc, int64_t i);
|
static MConstant* NewInt64(TempAllocator& alloc, int64_t i);
|
||||||
static MConstant* NewAsmJS(TempAllocator& alloc, const Value& v, MIRType type);
|
static MConstant* NewAsmJS(TempAllocator& alloc, const Value& v, MIRType type);
|
||||||
static MConstant* NewConstraintlessObject(TempAllocator& alloc, JSObject* v);
|
static MConstant* NewConstraintlessObject(TempAllocator& alloc, JSObject* v);
|
||||||
static MConstant* Copy(TempAllocator& alloc, MConstant* src) {
|
|
||||||
return new(alloc) MConstant(*src);
|
|
||||||
}
|
|
||||||
|
|
||||||
// Try to convert this constant to boolean, similar to js::ToBoolean.
|
// Try to convert this constant to boolean, similar to js::ToBoolean.
|
||||||
// Returns false if the type is MIRType::Magic*.
|
// Returns false if the type is MIRType::Magic*.
|
||||||
|
Loading…
Reference in New Issue
Block a user