Chromium Code Reviews| Index: tools/gen-postmortem-metadata.py |
| diff --git a/tools/gen-postmortem-metadata.py b/tools/gen-postmortem-metadata.py |
| index 55f915d3ce7542671e8d61c2c8976da19c4c339c..f83996cbc088ee486d04c590625003b6cb63358f 100644 |
| --- a/tools/gen-postmortem-metadata.py |
| +++ b/tools/gen-postmortem-metadata.py |
| @@ -50,7 +50,8 @@ import re |
| import sys |
| # |
| -# Miscellaneous constants, tags, and masks used for object identification. |
| +# Miscellaneous constants such as tags and masks used for object identification, |
| +# enumeration values used as indexes in internal tables, etc.. |
| # |
| consts_misc = [ |
| { 'name': 'FirstNonstringType', 'value': 'FIRST_NONSTRING_TYPE' }, |
| @@ -156,6 +157,8 @@ consts_misc = [ |
| 'value': 'StandardFrameConstants::kContextOffset' }, |
| { 'name': 'off_fp_constant_pool', |
| 'value': 'StandardFrameConstants::kConstantPoolOffset' }, |
| + { 'name': 'off_fp_marker', |
|
julien.gilli
2016/06/09 18:19:15
This change was not supposed to be submitted, I'll
|
| + 'value': 'StandardFrameConstants::kMarkerOffset' }, |
| { 'name': 'off_fp_function', |
| 'value': 'JavaScriptFrameConstants::kFunctionOffset' }, |
| { 'name': 'off_fp_args', |
| @@ -181,17 +184,46 @@ consts_misc = [ |
| 'value': 'JSArrayBuffer::WasNeutered::kMask' }, |
| { 'name': 'jsarray_buffer_was_neutered_shift', |
| 'value': 'JSArrayBuffer::WasNeutered::kShift' }, |
| + |
| + { 'name': 'context_idx_closure', |
| + 'value': 'Context::CLOSURE_INDEX' }, |
| + { 'name': 'context_idx_native', |
| + 'value': 'Context::NATIVE_CONTEXT_INDEX' }, |
| + { 'name': 'context_idx_prev', |
| + 'value': 'Context::PREVIOUS_INDEX' }, |
| + { 'name': 'context_idx_ext', |
| + 'value': 'Context::EXTENSION_INDEX' }, |
| + { 'name': 'context_min_slots', |
| + 'value': 'Context::MIN_CONTEXT_SLOTS' }, |
| + |
| + { 'name': 'namedictionaryshape_prefix_size', |
| + 'value': 'NameDictionaryShape::kPrefixSize' }, |
| + { 'name': 'namedictionaryshape_entry_size', |
| + 'value': 'NameDictionaryShape::kEntrySize' }, |
| + |
| + { 'name': 'namedictionary_prefix_start_index', |
| + 'value': 'NameDictionary::kPrefixStartIndex' }, |
| + |
| + { 'name': 'seedednumberdictionaryshape_prefix_size', |
| + 'value': 'SeededNumberDictionaryShape::kPrefixSize' }, |
| + |
| + { 'name': 'unseedednumberdictionaryshape_prefix_size', |
| + 'value': 'UnseededNumberDictionaryShape::kPrefixSize' }, |
| + |
| + { 'name': 'numberdictionaryshape_entry_size', |
| + 'value': 'NumberDictionaryShape::kEntrySize' } |
| ]; |
| # |
| # The following useful fields are missing accessors, so we define fake ones. |
| +# Please note that extra accessors should _only_ be added to expose offsets that |
| +# can be used to access actual V8 objects' properties. They should not be added |
| +# for exposing other values. For instance, enumeration values or class' |
| +# constants should be exposed by adding an entry in the "consts_misc" table, not |
| +# in this "extras_accessors" table. |
| # |
| extras_accessors = [ |
| 'JSFunction, context, Context, kContextOffset', |
| - 'Context, closure_index, int, CLOSURE_INDEX', |
| - 'Context, native_context_index, int, NATIVE_CONTEXT_INDEX', |
| - 'Context, previous_index, int, PREVIOUS_INDEX', |
| - 'Context, min_context_slots, int, MIN_CONTEXT_SLOTS', |
| 'HeapObject, map, Map, kMapOffset', |
| 'JSObject, elements, Object, kElementsOffset', |
| 'FixedArray, data, uintptr_t, kHeaderSize', |
| @@ -205,12 +237,6 @@ extras_accessors = [ |
| 'Map, bit_field2, char, kBitField2Offset', |
| 'Map, bit_field3, int, kBitField3Offset', |
| 'Map, prototype, Object, kPrototypeOffset', |
| - 'NameDictionaryShape, prefix_size, int, kPrefixSize', |
| - 'NameDictionaryShape, entry_size, int, kEntrySize', |
| - 'NameDictionary, prefix_start_index, int, kPrefixStartIndex', |
| - 'SeededNumberDictionaryShape, prefix_size, int, kPrefixSize', |
| - 'UnseededNumberDictionaryShape, prefix_size, int, kPrefixSize', |
| - 'NumberDictionaryShape, entry_size, int, kEntrySize', |
| 'Oddball, kind_offset, int, kKindOffset', |
| 'HeapNumber, value, double, kValueOffset', |
| 'ConsString, first, String, kFirstOffset', |
| @@ -254,6 +280,7 @@ header = ''' |
| #include "src/v8.h" |
| #include "src/frames.h" |
| #include "src/frames-inl.h" /* for architecture-specific frame constants */ |
| +#include "src/contexts.h" |
| using namespace v8::internal; |