Don't mark MGetFirstDollarIndex as movable.

This commit is contained in:
wolfbeast 2018-10-31 17:30:52 +01:00 committed by Roy Tam
commit c554052ddd

View file

@ -8272,7 +8272,10 @@ class MGetFirstDollarIndex
: MUnaryInstruction(str)
{
setResultType(MIRType::Int32);
setMovable();
// Codegen assumes string length > 0 but that's not guaranteed in RegExp.
// Don't allow LICM to move this.
MOZ_ASSERT(!isMovable());
}
public: