From 317c3dffbb29331325a77b29b10576aaa11c17e9 Mon Sep 17 00:00:00 2001 From: Matheus Marchini Date: Mon, 9 Dec 2019 11:27:35 -0800 Subject: [PATCH] deps: V8: cherry-pick b38dfaf3a633 Original commit message: [postmortem] update Symbol and *String metadata Symbol and *String classes are now declared on Torque with generateCppClass, which means they don't use macro accessors anymore. As such, the gen-postmortem-metadata script is not able to automatically detect fields for those classes. Define metadata for those fields manually for now. In the future we might want to generate it from Torque for consistency. Also renamed a few *String fields metadata to match the expected format (className__fieldName__fieldType). For more context: https://github.com/nodejs/llnode/issues/287#issuecomment-539707117. R=bmeurer@chromium.org, hpayer@chromium.org, verwaest@chromium.org, yangguo@chromium.org Change-Id: I82fe8315cdbfd1b8c64c6a8d5dc011b1edaec39e Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/1847783 Reviewed-by: Toon Verwaest Commit-Queue: Toon Verwaest Cr-Commit-Position: refs/heads/master@{#64313} Refs: https://github.com/v8/v8/commit/b38dfaf3a6338bf5e42703d0a93d21c2622765ce PR-URL: https://github.com/nodejs/node/pull/30870 Reviewed-By: Michael Dawson --- common.gypi | 2 +- deps/v8/tools/gen-postmortem-metadata.py | 14 +++++--------- 2 files changed, 6 insertions(+), 10 deletions(-) diff --git a/common.gypi b/common.gypi index b8c1e9fabb26d2..c26ed5e0192389 100644 --- a/common.gypi +++ b/common.gypi @@ -38,7 +38,7 @@ # Reset this number to 0 on major V8 upgrades. # Increment by one for each non-official patch applied to deps/v8. - 'v8_embedder_string': '-node.28', + 'v8_embedder_string': '-node.29', ##### V8 defaults for Node.js ##### diff --git a/deps/v8/tools/gen-postmortem-metadata.py b/deps/v8/tools/gen-postmortem-metadata.py index ee167ec37e67bb..021a2f2c100263 100644 --- a/deps/v8/tools/gen-postmortem-metadata.py +++ b/deps/v8/tools/gen-postmortem-metadata.py @@ -230,15 +230,6 @@ { 'name': 'class_SharedFunctionInfo__function_data__Object', 'value': 'SharedFunctionInfo::kFunctionDataOffset' }, - - { 'name': 'class_ConsString__first_offset__int', - 'value': 'ConsString::kFirstOffset' }, - { 'name': 'class_ConsString__second_offset__int', - 'value': 'ConsString::kSecondOffset' }, - { 'name': 'class_SlicedString__offset_offset__int', - 'value': 'SlicedString::kOffsetOffset' }, - { 'name': 'class_ThinString__actual_offset__int', - 'value': 'ThinString::kActualOffset' }, ]; # @@ -287,6 +278,11 @@ 'Code, instruction_size, int, kInstructionSizeOffset', 'String, length, int32_t, kLengthOffset', 'DescriptorArray, header_size, uintptr_t, kHeaderSize', + 'ConsString, first, String, kFirstOffset', + 'ConsString, second, String, kSecondOffset', + 'SlicedString, offset, SMI, kOffsetOffset', + 'ThinString, actual, String, kActualOffset', + 'Symbol, name, Object, kNameOffset', ]; #