| Index: src/objects.h
|
| diff --git a/src/objects.h b/src/objects.h
|
| index 559ada63f41922bdb30efb209884a6b9a1280be3..5538088103813962b3a0fda765e675e54ffd9877 100644
|
| --- a/src/objects.h
|
| +++ b/src/objects.h
|
| @@ -4370,7 +4370,6 @@ class SharedFunctionInfo: public HeapObject {
|
| kThisPropertyAssignmentsOffset + kPointerSize,
|
| kSize> BodyDescriptor;
|
|
|
| - private:
|
| // Bit positions in start_position_and_type.
|
| // The source code start position is in the 30 most significant bits of
|
| // the start_position_and_type field.
|
| @@ -4389,6 +4388,35 @@ class SharedFunctionInfo: public HeapObject {
|
| static const int kOptimizationDisabled = 7;
|
| static const int kStrictModeFunction = 8;
|
|
|
| + private:
|
| +#if V8_HOST_ARCH_32_BIT
|
| + // On 32 bit platforms, compiler hints is a smi.
|
| + static const int kCompilerHintsSmiTagSize = kSmiTagSize;
|
| + static const int kCompilerHintsSize = kPointerSize;
|
| +#else
|
| + // On 64 bit platforms, compiler hints is not a smi, see comment above.
|
| + static const int kCompilerHintsSmiTagSize = 0;
|
| + static const int kCompilerHintsSize = kIntSize;
|
| +#endif
|
| +
|
| + public:
|
| + // Constants for optimizing codegen for strict mode function tests.
|
| + // Allows to use byte-widgh instructions.
|
| + static const int kStrictModeBitWithinByte =
|
| + (kStrictModeFunction + kCompilerHintsSmiTagSize) % kBitsPerByte;
|
| +
|
| +#if __BYTE_ORDER == __LITTLE_ENDIAN
|
| + static const int kStrictModeByteOffset = kCompilerHintsOffset +
|
| + (kStrictModeFunction + kCompilerHintsSmiTagSize) / kBitsPerByte;
|
| +#elif __BYTE_ORDER == __BIG_ENDIAN
|
| + static const int kStrictModeByteOffset = kCompilerHintsOffset +
|
| + (kCompilerHintsSize - 1) -
|
| + ((kStrictModeFunction + kCompilerHintsSmiTagSize) / kBitsPerByte);
|
| +#else
|
| +#error Unknown byte ordering
|
| +#endif
|
| +
|
| + private:
|
| DISALLOW_IMPLICIT_CONSTRUCTORS(SharedFunctionInfo);
|
| };
|
|
|
|
|