| Index: src/code-stub-assembler.h
|
| diff --git a/src/code-stub-assembler.h b/src/code-stub-assembler.h
|
| index 71647eb10be65d7473b22e4395fa0a951c5d0df2..95fcc1c3afddb8e19178a7d460379725bc8cf840 100644
|
| --- a/src/code-stub-assembler.h
|
| +++ b/src/code-stub-assembler.h
|
| @@ -94,6 +94,28 @@ class V8_EXPORT_PRIVATE CodeStubAssembler : public compiler::CodeAssembler {
|
| return value;
|
| }
|
|
|
| +#define PARAMETER_BINARY_OPERATION(OpName, IntPtrOpName, SmiOpName, \
|
| + Int32OpName) \
|
| + Node* OpName(Node* value1, Node* value2, ParameterMode mode) { \
|
| + if (mode == SMI_PARAMETERS) { \
|
| + return SmiOpName(value1, value2); \
|
| + } else if (mode == INTPTR_PARAMETERS) { \
|
| + return IntPtrOpName(value1, value2); \
|
| + } else { \
|
| + DCHECK_EQ(INTEGER_PARAMETERS, mode); \
|
| + return Int32OpName(value1, value2); \
|
| + } \
|
| + }
|
| + PARAMETER_BINARY_OPERATION(IntPtrOrSmiAdd, IntPtrAdd, SmiAdd, Int32Add)
|
| + PARAMETER_BINARY_OPERATION(IntPtrOrSmiLessThan, IntPtrLessThan, SmiLessThan,
|
| + Int32LessThan)
|
| + PARAMETER_BINARY_OPERATION(IntPtrOrSmiGreaterThan, IntPtrGreaterThan,
|
| + SmiGreaterThan, Int32GreaterThan)
|
| + PARAMETER_BINARY_OPERATION(UintPtrOrSmiLessThan, UintPtrLessThan, SmiBelow,
|
| + Uint32LessThan)
|
| +
|
| +#undef PARAMETER_BINARY_OPERATION
|
| +
|
| Node* NoContextConstant();
|
| #define HEAP_CONSTANT_ACCESSOR(rootName, name) Node* name##Constant();
|
| HEAP_CONSTANT_LIST(HEAP_CONSTANT_ACCESSOR)
|
| @@ -142,6 +164,7 @@ class V8_EXPORT_PRIVATE CodeStubAssembler : public compiler::CodeAssembler {
|
| Node* SmiBelow(Node* a, Node* b);
|
| Node* SmiLessThan(Node* a, Node* b);
|
| Node* SmiLessThanOrEqual(Node* a, Node* b);
|
| + Node* SmiGreaterThan(Node* a, Node* b);
|
| Node* SmiMax(Node* a, Node* b);
|
| Node* SmiMin(Node* a, Node* b);
|
| // Computes a % b for Smi inputs a and b; result is not necessarily a Smi.
|
|
|