mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-11-26 14:22:01 +00:00
Bug 1328148: IonMonkey - Use MConcat for more cases, r=jandem
This commit is contained in:
parent
54c8c2b1da
commit
642bdf9008
@ -107,6 +107,7 @@ namespace JS {
|
||||
_(OperandNotNumber) \
|
||||
_(OperandNotStringOrNumber) \
|
||||
_(OperandNotSimpleArith) \
|
||||
_(OperandNotEasilyCoercibleToString) \
|
||||
_(StaticTypedArrayUint32) \
|
||||
_(StaticTypedArrayCantComputeMask) \
|
||||
_(OutOfBounds) \
|
||||
|
@ -188,6 +188,10 @@ Optimization failed because of failing to speculate the operand is a string or a
|
||||
|
||||
Optimization failed because of failing to speculate the operand is a simple arithmetic type. I.e. definitely not an object, string, symbol or internal magic type.
|
||||
|
||||
### OperandNotEasilyCoercibleToString
|
||||
|
||||
Optimization failed because of failing to speculate the operand can be easily coerced to a string. I.e. definitely not an object or symbol.
|
||||
|
||||
### StaticTypedArrayUint32
|
||||
|
||||
Typed Arrays of uint32 values are not yet fully optimized.
|
||||
|
@ -3180,14 +3180,17 @@ IonBuilder::binaryArithTryConcat(bool* emitted, JSOp op, MDefinition* left, MDef
|
||||
return Ok();
|
||||
}
|
||||
|
||||
// The none-string input (if present) should be atleast a numerical type.
|
||||
// Which we can easily coerce to string.
|
||||
if (right->type() != MIRType::String && !IsNumberType(right->type())) {
|
||||
trackOptimizationOutcome(TrackedOutcome::OperandNotStringOrNumber);
|
||||
// The non-string input (if present) should be atleast easily coercible to string.
|
||||
if (right->type() != MIRType::String &&
|
||||
(right->mightBeType(MIRType::Symbol) || right->mightBeType(MIRType::Object)))
|
||||
{
|
||||
trackOptimizationOutcome(TrackedOutcome::OperandNotEasilyCoercibleToString);
|
||||
return Ok();
|
||||
}
|
||||
if (left->type() != MIRType::String && !IsNumberType(left->type())) {
|
||||
trackOptimizationOutcome(TrackedOutcome::OperandNotStringOrNumber);
|
||||
if (left->type() != MIRType::String &&
|
||||
(left->mightBeType(MIRType::Symbol) || left->mightBeType(MIRType::Object)))
|
||||
{
|
||||
trackOptimizationOutcome(TrackedOutcome::OperandNotEasilyCoercibleToString);
|
||||
return Ok();
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user