Bug 1249961 - Rename MacroAssembler::branchEqualTypeIfNeeded to MacroAssembler::maybeBranchTestType. r=nbp

This commit is contained in:
Tooru Fujisawa 2016-03-05 07:41:54 +09:00
Родитель e8ffd9aa80
Коммит f865bb4b1c
2 изменённых файлов: 8 добавлений и 9 удалений

Просмотреть файл

@ -1838,10 +1838,10 @@ MacroAssembler::convertValueToInt(ValueOperand value, MDefinition* maybeInput,
Label done, isInt32, isBool, isDouble, isNull, isString;
branchEqualTypeIfNeeded(MIRType_Int32, maybeInput, tag, &isInt32);
maybeBranchTestType(MIRType_Int32, maybeInput, tag, &isInt32);
if (conversion == IntConversion_Any || conversion == IntConversion_NumbersOrBoolsOnly)
branchEqualTypeIfNeeded(MIRType_Boolean, maybeInput, tag, &isBool);
branchEqualTypeIfNeeded(MIRType_Double, maybeInput, tag, &isDouble);
maybeBranchTestType(MIRType_Boolean, maybeInput, tag, &isBool);
maybeBranchTestType(MIRType_Double, maybeInput, tag, &isDouble);
if (conversion == IntConversion_Any) {
// If we are not truncating, we fail for anything that's not
@ -1854,10 +1854,10 @@ MacroAssembler::convertValueToInt(ValueOperand value, MDefinition* maybeInput,
case IntConversion_Truncate:
case IntConversion_ClampToUint8:
branchEqualTypeIfNeeded(MIRType_Null, maybeInput, tag, &isNull);
maybeBranchTestType(MIRType_Null, maybeInput, tag, &isNull);
if (handleStrings)
branchEqualTypeIfNeeded(MIRType_String, maybeInput, tag, &isString);
branchEqualTypeIfNeeded(MIRType_Object, maybeInput, tag, fail);
maybeBranchTestType(MIRType_String, maybeInput, tag, &isString);
maybeBranchTestType(MIRType_Object, maybeInput, tag, fail);
branchTestUndefined(Assembler::NotEqual, tag, fail);
break;
}
@ -2516,8 +2516,7 @@ MacroAssembler::branchIfNotInterpretedConstructor(Register fun, Register scratch
}
void
MacroAssembler::branchEqualTypeIfNeeded(MIRType type, MDefinition* maybeDef, Register tag,
Label* label)
MacroAssembler::maybeBranchTestType(MIRType type, MDefinition* maybeDef, Register tag, Label* label)
{
if (!maybeDef || maybeDef->mightBeType(type)) {
switch (type) {

Просмотреть файл

@ -920,7 +920,7 @@ class MacroAssembler : public MacroAssemblerSpecific
// Emit type case branch on tag matching if the type tag in the definition
// might actually be that type.
void branchEqualTypeIfNeeded(MIRType type, MDefinition* maybeDef, Register tag, Label* label);
void maybeBranchTestType(MIRType type, MDefinition* maybeDef, Register tag, Label* label);
template <typename T>
inline void branchKey(Condition cond, const T& length, const Int32Key& key, Label* label);