| Index: src/objects.h
|
| diff --git a/src/objects.h b/src/objects.h
|
| index 3eda230a939a1b5163516c1bdec461972e117a34..47ca57218476fc9c323c064dd0135e6cde822aa4 100644
|
| --- a/src/objects.h
|
| +++ b/src/objects.h
|
| @@ -7363,6 +7363,9 @@ class SharedFunctionInfo: public HeapObject {
|
| // The function's name if it is non-empty, otherwise the inferred name.
|
| String* DebugName();
|
|
|
| + // The function cannot cause any side effects.
|
| + bool IsReadOnly();
|
| +
|
| // Used for flags such as --hydrogen-filter.
|
| bool PassesFilter(const char* raw_filter);
|
|
|
| @@ -7472,6 +7475,12 @@ class SharedFunctionInfo: public HeapObject {
|
| // Indicates that asm->wasm conversion failed and should not be re-attempted.
|
| DECL_BOOLEAN_ACCESSORS(is_asm_wasm_broken)
|
|
|
| + // Indicates that the function cannot cause side-effects.
|
| + DECL_BOOLEAN_ACCESSORS(is_readonly)
|
| +
|
| + // Indicates that |is_readonly| has been computed and set.
|
| + DECL_BOOLEAN_ACCESSORS(is_readonly_computed)
|
| +
|
| inline FunctionKind kind() const;
|
| inline void set_kind(FunctionKind kind);
|
|
|
| @@ -7758,6 +7767,8 @@ class SharedFunctionInfo: public HeapObject {
|
| // byte 3
|
| kDeserialized = kFunctionKind + 10,
|
| kIsAsmWasmBroken,
|
| + kIsReadOnly,
|
| + kIsReadOnlyComputed,
|
| kCompilerHintsCount, // Pseudo entry
|
| };
|
| // kFunctionKind has to be byte-aligned
|
|
|