summaryrefslogtreecommitdiff
path: root/js/src/jit/IonBuilder.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'js/src/jit/IonBuilder.cpp')
-rw-r--r--js/src/jit/IonBuilder.cpp14
1 files changed, 13 insertions, 1 deletions
diff --git a/js/src/jit/IonBuilder.cpp b/js/src/jit/IonBuilder.cpp
index 0a9734a335..a440bfa598 100644
--- a/js/src/jit/IonBuilder.cpp
+++ b/js/src/jit/IonBuilder.cpp
@@ -721,6 +721,9 @@ IonBuilder::analyzeNewLoopTypes(MBasicBlock* entry, jsbytecode* start, jsbytecod
case JSOP_NEG:
type = inspector->expectedResultType(last);
break;
+ case JSOP_BIGINT:
+ type = MIRType::BigInt;
+ break;
default:
break;
}
@@ -1347,6 +1350,7 @@ IonBuilder::addOsrValueTypeBarrier(uint32_t slot, MInstruction** def_,
case MIRType::Double:
case MIRType::String:
case MIRType::Symbol:
+ case MIRType::BigInt:
case MIRType::Object:
if (type != def->type()) {
MUnbox* unbox = MUnbox::New(alloc(), def, type, MUnbox::Fallible);
@@ -1765,6 +1769,7 @@ IonBuilder::inspectOpcode(JSOp op)
return jsop_compare(op);
case JSOP_DOUBLE:
+ case JSOP_BIGINT:
pushConstant(info().getConst(pc));
return true;
@@ -4760,8 +4765,10 @@ IonBuilder::bitnotTrySpecialized(bool* emitted, MDefinition* input)
// Try to emit a specialized bitnot instruction based on the input type
// of the operand.
- if (input->mightBeType(MIRType::Object) || input->mightBeType(MIRType::Symbol))
+ if (input->mightBeType(MIRType::Object) || input->mightBeType(MIRType::Symbol) ||
+ input->mightBeType(MIRType::BigInt)) {
return true;
+ }
MBitNot* ins = MBitNot::New(alloc(), input);
ins->setSpecialization(MIRType::Int32);
@@ -7209,6 +7216,7 @@ ObjectOrSimplePrimitive(MDefinition* op)
// Return true if op is either undefined/null/boolean/int32 or an object.
return !op->mightBeType(MIRType::String)
&& !op->mightBeType(MIRType::Symbol)
+ && !op->mightBeType(MIRType::BigInt)
&& !op->mightBeType(MIRType::Double)
&& !op->mightBeType(MIRType::Float32)
&& !op->mightBeType(MIRType::MagicOptimizedArguments)
@@ -8348,6 +8356,10 @@ IonBuilder::testSingletonPropertyTypes(MDefinition* obj, jsid id)
key = JSProto_Symbol;
break;
+ case MIRType::BigInt:
+ key = JSProto_BigInt;
+ break;
+
case MIRType::Int32:
case MIRType::Double:
key = JSProto_Number;