Skip to content

Commit

Permalink
deps: cherry-pick 70c4340 from upstream V8
Browse files Browse the repository at this point in the history
Original commit message:

    [log][api] Fix GCC 4.9 build failure

    GCC 4.9 used on some Node.js CI machines complains when the control
    reaches the end of a non-void function and no return is encountered.

    [email protected], [email protected], [email protected]

    Cq-Include-Trybots: luci.chromium.try:linux_chromium_rel_ng
    Change-Id: I5af0192cb187eccbf34dbb60ff3ac2e4774af803
    Reviewed-on: https://chromium-review.googlesource.com/1105619
    Reviewed-by: Yang Guo <[email protected]>
    Commit-Queue: Yang Guo <[email protected]>
    Cr-Commit-Position: refs/heads/master@{nodejs#53861}

Refs: v8/v8@70c4340

PR-URL: nodejs#21126
Refs: v8/v8@aa6ce3e
Reviewed-By: Michaël Zasso <[email protected]>
Reviewed-By: Michael Dawson <[email protected]>
Reviewed-By: James M Snell <[email protected]>
  • Loading branch information
Matheus Marchini authored and targos committed Jul 25, 2018
1 parent 06c0358 commit e39f302
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 1 deletion.
2 changes: 1 addition & 1 deletion common.gypi
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,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.5',
'v8_embedder_string': '-node.6',

# Enable disassembler for `--print-code` v8 options
'v8_enable_disassembler': 1,
Expand Down
4 changes: 4 additions & 0 deletions deps/v8/src/api.cc
Original file line number Diff line number Diff line change
Expand Up @@ -10148,6 +10148,10 @@ const char* CodeEvent::GetCodeEventTypeName(CodeEventType code_event_type) {
CODE_EVENTS_LIST(V)
#undef V
}
// The execution should never pass here
UNREACHABLE();
// NOTE(mmarchini): Workaround to fix a compiler failure on GCC 4.9
return "Unknown";
}

CodeEventHandler::CodeEventHandler(Isolate* isolate) {
Expand Down
4 changes: 4 additions & 0 deletions deps/v8/src/log.cc
Original file line number Diff line number Diff line change
Expand Up @@ -59,6 +59,10 @@ static v8::CodeEventType GetCodeEventTypeForTag(
TAGS_LIST(V)
#undef V
}
// The execution should never pass here
UNREACHABLE();
// NOTE(mmarchini): Workaround to fix a compiler failure on GCC 4.9
return v8::CodeEventType::kUnknownType;
}
#define CALL_CODE_EVENT_HANDLER(Call) \
if (listener_) { \
Expand Down

0 comments on commit e39f302

Please sign in to comment.