Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

V8 CI build error on ppc #52661

Closed
targos opened this issue Apr 24, 2024 · 7 comments · Fixed by #52802
Closed

V8 CI build error on ppc #52661

targos opened this issue Apr 24, 2024 · 7 comments · Fixed by #52802
Labels
build Issues and PRs related to build files or the CI. ppc Issues and PRs related to the Power architecture. v8 engine Issues and PRs related to the V8 dependency.

Comments

@targos
Copy link
Member

targos commented Apr 24, 2024

@nodejs/platform-ppc

We missed it in the 12.4 upgrade PR.

https://ci.nodejs.org/job/node-test-commit-v8-linux/5914/nodes=rhel8-ppc64le,v8test=v8test/

21:19:30 FAILED: obj/v8_base_without_compiler/turboshaft-graph-interface.o 
21:19:30 ccache g++ -MD -MF obj/v8_base_without_compiler/turboshaft-graph-interface.o.d -DUSE_UDEV -DUSE_AURA=1 -DUSE_GLIB=1 -DUSE_OZONE=1 -D__STDC_CONSTANT_MACROS -D__STDC_FORMAT_MACROS -D_FILE_OFFSET_BITS=64 -D_LARGEFILE_SOURCE -D_LARGEFILE64_SOURCE -D_LIBCPP_HARDENING_MODE=_LIBCPP_HARDENING_MODE_NONE -D_GLIBCXX_ASSERTIONS=1 -DNDEBUG -DNVALGRIND -DDYNAMIC_ANNOTATIONS_ENABLED=0 -DV8_TYPED_ARRAY_MAX_SIZE_IN_HEAP=64 -DENABLE_GDB_JIT_INTERFACE -DV8_INTL_SUPPORT -DV8_USE_EXTERNAL_STARTUP_DATA -DV8_ATOMIC_OBJECT_FIELD_WRITES -DV8_ENABLE_LAZY_SOURCE_POSITIONS -DV8_SHARED_RO_HEAP -DV8_WIN64_UNWINDING_INFO -DV8_ENABLE_REGEXP_INTERPRETER_THREADED_DISPATCH -DV8_ENABLE_SPARKPLUG -DV8_ENABLE_TURBOFAN -DV8_ENABLE_WEBASSEMBLY -DV8_ENABLE_CONTINUATION_PRESERVED_EMBEDDER_DATA -DV8_ALLOCATION_FOLDING -DV8_ALLOCATION_SITE_TRACKING -DV8_ADVANCED_BIGINT_ALGORITHMS -DV8_USE_ZLIB -DV8_ENABLE_MAGLEV_GRAPH_PRINTER -DV8_ENABLE_EXTENSIBLE_RO_SNAPSHOT -DV8_DEPRECATION_WARNINGS -DV8_IMMINENT_DEPRECATION_WARNINGS -DCPPGC_SLIM_WRITE_BARRIER -DV8_TARGET_ARCH_PPC64 -DV8_TARGET_ARCH_PPC_LE -DV8_HAVE_TARGET_OS -DV8_TARGET_OS_LINUX -DABSL_ALLOCATOR_NOTHROW=1 -DU_USING_ICU_NAMESPACE=0 -DU_ENABLE_DYLOAD=0 -DUSE_CHROMIUM_ICU=1 -DU_ENABLE_TRACING=1 -DU_ENABLE_RESOURCE_TRACING=0 -DU_STATIC_IMPLEMENTATION -DICU_UTIL_DATA_IMPL=ICU_UTIL_DATA_FILE -I../.. -Igen -I../../include -I../../third_party/abseil-cpp -Igen/include -I../../third_party/icu/source/common -I../../third_party/icu/source/i18n -I../../third_party/fp16/src/include -I../../third_party/zlib -Wall -Wno-unused-local-typedefs -Wno-maybe-uninitialized -Wno-deprecated-declarations -Wno-comments -Wno-packed-not-aligned -Wno-missing-field-initializers -Wno-unused-parameter -Wno-psabi -Werror -fno-ident -fno-strict-aliasing -fstack-protector -funwind-tables -fPIC -pipe -pthread -m64 -Wno-builtin-macro-redefined -D__DATE__= -D__TIME__= -D__TIMESTAMP__= -fno-omit-frame-pointer -g0 -ffp-contract=off -Wno-invalid-offsetof -Wno-strict-overflow -Wno-return-type -Wno-int-in-bool-context -Wno-deprecated -Wno-stringop-overflow -Wno-stringop-overread -Wno-restrict -Wno-array-bounds -Wno-nonnull -O3 -fdata-sections -ffunction-sections -fno-math-errno -fvisibility=default -Wno-narrowing -Wno-class-memaccess -std=gnu++2a -fno-exceptions -fno-rtti -c ../../src/wasm/turboshaft-graph-interface.cc -o obj/v8_base_without_compiler/turboshaft-graph-interface.o
21:19:30 In file included from ../../src/wasm/turboshaft-graph-interface.h:13,
21:19:30                  from ../../src/wasm/turboshaft-graph-interface.cc:5:
21:19:30 ../../src/compiler/turboshaft/assembler.h: In static member function ‘static _Res std::_Function_handler<_Res(_ArgTypes ...), _Functor>::_M_invoke(const std::_Any_data&, _ArgTypes&& ...) [with _Res = v8::internal::compiler::turboshaft::V<v8::internal::compiler::turboshaft::WordWithBits<32> >; _Functor = v8::internal::wasm::TurboshaftGraphBuildingInterface::ArrayFillImpl(v8::internal::wasm::WasmGraphBuilderBase::V<v8::internal::HeapObject>, v8::internal::wasm::WasmGraphBuilderBase::OpIndex, v8::internal::wasm::WasmGraphBuilderBase::OpIndex, v8::internal::wasm::WasmGraphBuilderBase::OpIndex, const v8::internal::wasm::ArrayType*, bool)::<lambda()>; _ArgTypes = {}]’:
21:19:30 ../../src/compiler/turboshaft/assembler.h:680:16: error: ‘<anonymous>’ is used uninitialized in this function [-Werror=uninitialized]
21:19:30   680 |     return Get();
21:19:30       |                ^
21:19:30 At global scope:
21:19:30 cc1plus: note: unrecognized command-line option ‘-Wno-stringop-overread’ may have been intended to silence earlier diagnostics
21:19:30 cc1plus: all warnings being treated as errors
@VoltrexKeyva VoltrexKeyva added build Issues and PRs related to build files or the CI. v8 engine Issues and PRs related to the V8 dependency. ppc Issues and PRs related to the Power architecture. labels Apr 24, 2024
@miladfarca
Copy link
Contributor

This doesn't happen on our gcc 12 compilers, i'm assuming you are using 10 for ppc? probably related to this bug:
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=86465

@richardlau
Copy link
Member

richardlau commented Apr 24, 2024

Yes, we're currently still using gcc-10 and C++17 (-std=gnu++17. for Node.js). The V8 build is running with -std=gnu++2a (C++20).

FWIW I've been experimenting with gcc-toolset-12 in richardlau-node-test-commit-v8-linux. The build on main from yesterday (today's is still in progress) succeeded with gcc 12: https://ci.nodejs.org/job/richardlau-node-test-commit-v8-linux/nodes=rhel8-ppc64le,v8test=v8test/589/

@richardlau
Copy link
Member

richardlau commented Apr 25, 2024

I ran some Node.js builds based on main (91dc8c9) plus commits to use C++20 but these still succeed with gcc-toolset-10:

so there's some other flag difference between the V8 and Node.js builds causing the compilation error to show up in the V8 one but not in the Node.js one when gcc-toolset-10 is used.

@targos
Copy link
Member Author

targos commented Apr 25, 2024

Isn't the main difference that V8 builds use Clang?

@richardlau
Copy link
Member

Isn't the main difference that V8 builds use Clang?

AFAIK not on ppc64le. You can see in the quoted compile failure in #52661 (comment) that it's executed ccache g++ which would be gcc from the gcc-toolset we select in select-compiler.sh.

@richardlau
Copy link
Member

richardlau commented Apr 29, 2024

The reason the Node.js V8 CI fails with gcc 10 but the Node.js CI does not is because the V8 build passes -Werror and -Wall to enable all warnings (with additional flags to turn some of the warning off) and fail on error while the Node.js build does not. Adding -Wall or just -Wuninitialized to the Node.js compile command line flags the same warning, and adding -Werror causes the build to fail.

@richardlau
Copy link
Member

This may be related to https://gcc.gnu.org/bugzilla/show_bug.cgi?id=86465. Dropping optimization to a lower level makes the warning go away (i.e. we get the warning with -O3 but not -O2 or -O1).

@miladfarca has submitted https://crrev.com/c/5503350 upstream which also makes the warning go away.
https://ci.nodejs.org/job/node-test-commit-v8-linux/5950/ passed with 2c30d3d.

nodejs-github-bot pushed a commit that referenced this issue May 3, 2024
Original commit message:

    [turboshaft] initialize constant_value_ to an empty value

    gcc-10 seems to have a bug were not initializing this value
    throws this compilation error:
    ```
    src/compiler/turboshaft/assembler.h:680:16: error: ‘<anonymous>’ is used uninitialized in this function [-Werror=uninitialized]
      680 |     return Get();
    ```
    https://gcc.gnu.org/bugzilla/show_bug.cgi?id=86465

    Bug: v8:12783
    Change-Id: I7a5fee5009b866a801326fba734c156c3cfdb1b0
    Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/5503350
    Reviewed-by: Nico Hartmann <nicohartmann@chromium.org>
    Commit-Queue: Milad Farazmand <mfarazma@redhat.com>
    Cr-Commit-Position: refs/heads/main@{#93675}

Refs: v8/v8@f6bef09
PR-URL: #52802
Fixes: #52661
Reviewed-By: Michaël Zasso <targos@protonmail.com>
Reviewed-By: Mohammed Keyvanzadeh <mohammadkeyvanzade94@gmail.com>
Reviewed-By: Marco Ippolito <marcoippolito54@gmail.com>
Reviewed-By: Yagiz Nizipli <yagiz.nizipli@sentry.io>
Ch3nYuY pushed a commit to Ch3nYuY/node that referenced this issue May 8, 2024
Original commit message:

    [turboshaft] initialize constant_value_ to an empty value

    gcc-10 seems to have a bug were not initializing this value
    throws this compilation error:
    ```
    src/compiler/turboshaft/assembler.h:680:16: error: ‘<anonymous>’ is used uninitialized in this function [-Werror=uninitialized]
      680 |     return Get();
    ```
    https://gcc.gnu.org/bugzilla/show_bug.cgi?id=86465

    Bug: v8:12783
    Change-Id: I7a5fee5009b866a801326fba734c156c3cfdb1b0
    Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/5503350
    Reviewed-by: Nico Hartmann <nicohartmann@chromium.org>
    Commit-Queue: Milad Farazmand <mfarazma@redhat.com>
    Cr-Commit-Position: refs/heads/main@{#93675}

Refs: v8/v8@f6bef09
PR-URL: nodejs#52802
Fixes: nodejs#52661
Reviewed-By: Michaël Zasso <targos@protonmail.com>
Reviewed-By: Mohammed Keyvanzadeh <mohammadkeyvanzade94@gmail.com>
Reviewed-By: Marco Ippolito <marcoippolito54@gmail.com>
Reviewed-By: Yagiz Nizipli <yagiz.nizipli@sentry.io>
targos pushed a commit that referenced this issue May 8, 2024
Original commit message:

    [turboshaft] initialize constant_value_ to an empty value

    gcc-10 seems to have a bug were not initializing this value
    throws this compilation error:
    ```
    src/compiler/turboshaft/assembler.h:680:16: error: ‘<anonymous>’ is used uninitialized in this function [-Werror=uninitialized]
      680 |     return Get();
    ```
    https://gcc.gnu.org/bugzilla/show_bug.cgi?id=86465

    Bug: v8:12783
    Change-Id: I7a5fee5009b866a801326fba734c156c3cfdb1b0
    Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/5503350
    Reviewed-by: Nico Hartmann <nicohartmann@chromium.org>
    Commit-Queue: Milad Farazmand <mfarazma@redhat.com>
    Cr-Commit-Position: refs/heads/main@{#93675}

Refs: v8/v8@f6bef09
PR-URL: #52802
Fixes: #52661
Reviewed-By: Michaël Zasso <targos@protonmail.com>
Reviewed-By: Mohammed Keyvanzadeh <mohammadkeyvanzade94@gmail.com>
Reviewed-By: Marco Ippolito <marcoippolito54@gmail.com>
Reviewed-By: Yagiz Nizipli <yagiz.nizipli@sentry.io>
targos pushed a commit to targos/node that referenced this issue May 22, 2024
Original commit message:

    [turboshaft] initialize constant_value_ to an empty value

    gcc-10 seems to have a bug were not initializing this value
    throws this compilation error:
    ```
    src/compiler/turboshaft/assembler.h:680:16: error: ‘<anonymous>’ is used uninitialized in this function [-Werror=uninitialized]
      680 |     return Get();
    ```
    https://gcc.gnu.org/bugzilla/show_bug.cgi?id=86465

    Bug: v8:12783
    Change-Id: I7a5fee5009b866a801326fba734c156c3cfdb1b0
    Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/5503350
    Reviewed-by: Nico Hartmann <nicohartmann@chromium.org>
    Commit-Queue: Milad Farazmand <mfarazma@redhat.com>
    Cr-Commit-Position: refs/heads/main@{#93675}

Refs: v8/v8@f6bef09
PR-URL: nodejs#52802
Fixes: nodejs#52661
Reviewed-By: Michaël Zasso <targos@protonmail.com>
Reviewed-By: Mohammed Keyvanzadeh <mohammadkeyvanzade94@gmail.com>
Reviewed-By: Marco Ippolito <marcoippolito54@gmail.com>
Reviewed-By: Yagiz Nizipli <yagiz.nizipli@sentry.io>
sophoniie pushed a commit to sophoniie/node that referenced this issue Jun 20, 2024
Original commit message:

    [turboshaft] initialize constant_value_ to an empty value

    gcc-10 seems to have a bug were not initializing this value
    throws this compilation error:
    ```
    src/compiler/turboshaft/assembler.h:680:16: error: ‘<anonymous>’ is used uninitialized in this function [-Werror=uninitialized]
      680 |     return Get();
    ```
    https://gcc.gnu.org/bugzilla/show_bug.cgi?id=86465

    Bug: v8:12783
    Change-Id: I7a5fee5009b866a801326fba734c156c3cfdb1b0
    Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/5503350
    Reviewed-by: Nico Hartmann <nicohartmann@chromium.org>
    Commit-Queue: Milad Farazmand <mfarazma@redhat.com>
    Cr-Commit-Position: refs/heads/main@{#93675}

Refs: v8/v8@f6bef09
PR-URL: nodejs#52802
Fixes: nodejs#52661
Reviewed-By: Michaël Zasso <targos@protonmail.com>
Reviewed-By: Mohammed Keyvanzadeh <mohammadkeyvanzade94@gmail.com>
Reviewed-By: Marco Ippolito <marcoippolito54@gmail.com>
Reviewed-By: Yagiz Nizipli <yagiz.nizipli@sentry.io>
bmeck pushed a commit to bmeck/node that referenced this issue Jun 22, 2024
Original commit message:

    [turboshaft] initialize constant_value_ to an empty value

    gcc-10 seems to have a bug were not initializing this value
    throws this compilation error:
    ```
    src/compiler/turboshaft/assembler.h:680:16: error: ‘<anonymous>’ is used uninitialized in this function [-Werror=uninitialized]
      680 |     return Get();
    ```
    https://gcc.gnu.org/bugzilla/show_bug.cgi?id=86465

    Bug: v8:12783
    Change-Id: I7a5fee5009b866a801326fba734c156c3cfdb1b0
    Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/5503350
    Reviewed-by: Nico Hartmann <nicohartmann@chromium.org>
    Commit-Queue: Milad Farazmand <mfarazma@redhat.com>
    Cr-Commit-Position: refs/heads/main@{#93675}

Refs: v8/v8@f6bef09
PR-URL: nodejs#52802
Fixes: nodejs#52661
Reviewed-By: Michaël Zasso <targos@protonmail.com>
Reviewed-By: Mohammed Keyvanzadeh <mohammadkeyvanzade94@gmail.com>
Reviewed-By: Marco Ippolito <marcoippolito54@gmail.com>
Reviewed-By: Yagiz Nizipli <yagiz.nizipli@sentry.io>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
build Issues and PRs related to build files or the CI. ppc Issues and PRs related to the Power architecture. v8 engine Issues and PRs related to the V8 dependency.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants