Index: src/objects.h |
diff --git a/src/objects.h b/src/objects.h |
index 682715cb52026b4ddf77e856ef7a0282d88df053..fd4c852e0781ca525cf76ae56c82f5ed2befff18 100644 |
--- a/src/objects.h |
+++ b/src/objects.h |
@@ -7107,18 +7107,25 @@ class SharedFunctionInfo: public HeapObject { |
public: |
// Constants for optimizing codegen for strict mode function and |
+ // native tests when using integer-width instructions. |
+ static const int kStrictModeBit = |
+ kStrictModeFunction + kCompilerHintsSmiTagSize; |
+ static const int kStrongModeBit = |
+ kStrongModeFunction + kCompilerHintsSmiTagSize; |
+ static const int kNativeBit = kNative + kCompilerHintsSmiTagSize; |
+ static const int kBoundBit = kBoundFunction + kCompilerHintsSmiTagSize; |
+ |
+ static const int kClassConstructorBits = |
+ FunctionKind::kClassConstructor |
+ << (kFunctionKind + kCompilerHintsSmiTagSize); |
+ |
+ // Constants for optimizing codegen for strict mode function and |
// native tests. |
// Allows to use byte-width instructions. |
- static const int kStrictModeBitWithinByte = |
- (kStrictModeFunction + kCompilerHintsSmiTagSize) % kBitsPerByte; |
- static const int kStrongModeBitWithinByte = |
- (kStrongModeFunction + kCompilerHintsSmiTagSize) % kBitsPerByte; |
- |
- static const int kNativeBitWithinByte = |
- (kNative + kCompilerHintsSmiTagSize) % kBitsPerByte; |
- |
- static const int kBoundBitWithinByte = |
- (kBoundFunction + kCompilerHintsSmiTagSize) % kBitsPerByte; |
+ static const int kStrictModeBitWithinByte = kStrictModeBit % kBitsPerByte; |
+ static const int kStrongModeBitWithinByte = kStrongModeBit % kBitsPerByte; |
+ static const int kNativeBitWithinByte = kNativeBit % kBitsPerByte; |
+ static const int kBoundBitWithinByte = kBoundBit % kBitsPerByte; |
static const int kClassConstructorBitsWithinByte = |
FunctionKind::kClassConstructor << kCompilerHintsSmiTagSize; |
@@ -7129,7 +7136,7 @@ class SharedFunctionInfo: public HeapObject { |
kCompilerHintsOffset + \ |
(compiler_hint + kCompilerHintsSmiTagSize) / kBitsPerByte |
#elif defined(V8_TARGET_BIG_ENDIAN) |
-#define BYTE_OFFSET(compiler_hint) \ |
+#define BYTE_OFFSET(compiler_hint) \ |
kCompilerHintsOffset + (kCompilerHintsSize - 1) - \ |
((compiler_hint + kCompilerHintsSmiTagSize) / kBitsPerByte) |
#else |