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

deps: update V8 to 10.7 #44741

Closed
wants to merge 27 commits into from
Closed

deps: update V8 to 10.7 #44741

wants to merge 27 commits into from

Commits on Oct 10, 2022

  1. deps: update V8 to 10.7.193.13

    targos committed Oct 10, 2022
    Configuration menu
    Copy the full SHA
    9a9cff1 View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    8624c5c View commit details
    Browse the repository at this point in the history
  3. src: update NODE_MODULE_VERSION to 111

    Major V8 updates are usually API/ABI incompatible with previous
    versions. This commit adapts NODE_MODULE_VERSION for V8 10.7.
    
    Refs: https://github.com/nodejs/CTC/blob/master/meetings/2016-09-28.md
    targos committed Oct 10, 2022
    Configuration menu
    Copy the full SHA
    9bf918b View commit details
    Browse the repository at this point in the history
  4. deps: V8: forward declaration of Rtl*FunctionTable

    This should be semver-patch since actual invocation is version
    conditional.
    
    PR-URL: nodejs#32116
    Reviewed-By: Michaël Zasso <targos@protonmail.com>
    Reviewed-By: Jiawen Geng <technicalcute@gmail.com>
    Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
    refack authored and targos committed Oct 10, 2022
    Configuration menu
    Copy the full SHA
    441f96b View commit details
    Browse the repository at this point in the history
  5. deps: fix V8 build issue with inline methods

    PR-URL: nodejs#35415
    Reviewed-By: Rich Trott <rtrott@gmail.com>
    Reviewed-By: Jiawen Geng <technicalcute@gmail.com>
    Reviewed-By: Daniel Bevenius <daniel.bevenius@gmail.com>
    Reviewed-By: Matteo Collina <matteo.collina@gmail.com>
    Reviewed-By: Myles Borins <myles.borins@gmail.com>
    
    deps: patch for v8 on windows
    
    PR-URL: nodejs#40010
    Reviewed-By: Michaël Zasso <targos@protonmail.com>
    Reviewed-By: James M Snell <jasnell@gmail.com>
    
    deps: patch v8 for vs2019 in std17
    
    PR-URL: nodejs#40060
    Reviewed-By: Richard Lau <rlau@redhat.com>
    Reviewed-By: James M Snell <jasnell@gmail.com>
    Reviewed-By: Michaël Zasso <targos@protonmail.com>
    
    deps: workaround debug link error on Windows
    
    PR-URL: nodejs#38807
    Refs: nodejs#38788
    Reviewed-By: Antoine du Hamel <duhamelantoine1995@gmail.com>
    Reviewed-By: Jiawen Geng <technicalcute@gmail.com>
    Reviewed-By: James M Snell <jasnell@gmail.com>
    Reviewed-By: Juan José Arboleda <soyjuanarbol@gmail.com>
    Reviewed-By: Michaël Zasso <targos@protonmail.com>
    Reviewed-By: Ash Cripps <acripps@redhat.com>
    gengjiawen authored and targos committed Oct 10, 2022
    Configuration menu
    Copy the full SHA
    8302cb0 View commit details
    Browse the repository at this point in the history
  6. deps: V8: fix v8-cppgc.h for MSVC

    Refs: https://bugs.chromium.org/p/v8/issues/detail?id=12661
    Refs: nodejs#42375
    
    PR-URL: nodejs#42657
    Reviewed-By: Darshan Sen <raisinten@gmail.com>
    Reviewed-By: Richard Lau <rlau@redhat.com>
    Reviewed-By: Jiawen Geng <technicalcute@gmail.com>
    Reviewed-By: Michael Dawson <midawson@redhat.com>
    gengjiawen authored and targos committed Oct 10, 2022
    Configuration menu
    Copy the full SHA
    8e11750 View commit details
    Browse the repository at this point in the history
  7. deps: make V8 compilable with older glibc

    Remove call to `memfd_create`.
    The function that references it is only used for V8 testing.
    
    PR-URL: nodejs#42657
    Reviewed-By: Darshan Sen <raisinten@gmail.com>
    Reviewed-By: Richard Lau <rlau@redhat.com>
    Reviewed-By: Jiawen Geng <technicalcute@gmail.com>
    Reviewed-By: Michael Dawson <midawson@redhat.com>
    targos committed Oct 10, 2022
    Configuration menu
    Copy the full SHA
    7a3c79b View commit details
    Browse the repository at this point in the history
  8. Configuration menu
    Copy the full SHA
    78b4f04 View commit details
    Browse the repository at this point in the history
  9. deps: fix V8 build on SmartOS

    targos committed Oct 10, 2022
    Configuration menu
    Copy the full SHA
    7f759c8 View commit details
    Browse the repository at this point in the history
  10. Configuration menu
    Copy the full SHA
    631a4ce View commit details
    Browse the repository at this point in the history
  11. deps: V8: cherry-pick b161a0823165

    Original commit message:
    
        [msvc] implement symbols without inline assembly
    
        MSVC does not support inline assembly (clang-cl does).
    
        Those two functions needs to be implemented using C++ only. Implemented
        a version for MSVC only, based on an intrinsic (that guarantees load,
        even with optimization) available for any architecture.
    
        Bug: v8:13312
        Change-Id: I3aa4eac03c099535c5d3a9a40221bd5f8bbcb0d1
        Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/3913036
        Reviewed-by: Jakob Kummerow <jkummerow@chromium.org>
        Reviewed-by: Thibaud Michaud <thibaudm@chromium.org>
        Commit-Queue: Jakob Kummerow <jkummerow@chromium.org>
        Cr-Commit-Position: refs/heads/main@{#83407}
    
    Refs: v8/v8@b161a08
    targos committed Oct 10, 2022
    Configuration menu
    Copy the full SHA
    583b75a View commit details
    Browse the repository at this point in the history
  12. deps: V8: cherry-pick 1b3a4f0c34a1

    Original commit message:
    
        [msvc] fix build with neon intrinsics
    
        This compilation error was found by NodeJS when updating V8:
        nodejs/node-v8#240
    
        MSVC reports an error with "too many initializer" for type uint32x4_t.
    
        ---
    
        Under gcc/clang, this is a typedef to a builtin type.
    
        For MSVC, it is a typedef to this union:
        typedef union __n128
        {
             unsigned __int64   n128_u64[2];
             unsigned __int32   n128_u32[4];
             ...
        } __n128;
    
        C++ mandates that only first member of union can be initialized at
        declaration. Thus, it can only be initialized with {uint64_t, uint64_t}.
    
        VS people proposed to use designated initializer instead:
        var = {.n128_u32={1, 2, 3, 8}}
        https://developercommunity.visualstudio.com/t/error-c2078-too-many-initializers-when-using-arm-n/402911
        But, you need to use /std:c++20 for this, which is not the case in v8.
    
        ---
    
        Thus, the only solution is to implement a hack specifically for MSVC,
        where you build two uint64, from four uint32.
    
        ---------------------------------------
    
        Once solved, another error is reported:
        templated function extract_first_nonzero_index is specialized twice.
    
        This is because, with MSVC, uint32x4_t and uint64x2_t are typedef to the
        same __n128 union. The fix is to drop templates, and use explicit
        function names instead.
    
        Bug: v8:13312
        Change-Id: I231d8cf01c05af01af319d56d5666c415f8b989b
        Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/3913035
        Reviewed-by: Igor Sheludko <ishell@chromium.org>
        Reviewed-by: Jakob Kummerow <jkummerow@chromium.org>
        Commit-Queue: Jakob Kummerow <jkummerow@chromium.org>
        Cr-Commit-Position: refs/heads/main@{#83404}
    
    Refs: v8/v8@1b3a4f0
    targos committed Oct 10, 2022
    Configuration menu
    Copy the full SHA
    825e326 View commit details
    Browse the repository at this point in the history
  13. deps: V8: cherry-pick 7ddb8399f9f1

    Original commit message:
    
        [msvc] fix ambiguous call to function in assembler test
    
        MSVC is confused by initializer list and default parameter, and reports
        an ambiguous call.
    
        test/cctest/test-assembler-arm64.cc(12208): error C2668: 'v8::internal::Clobber': ambiguous call to overloaded function
        test-utils-arm64.h(251): note: could be 'void v8::internal::Clobber(v8::internal::MacroAssembler *,v8::internal::CPURegList)'
        test-utils-arm64.h(241): note: or       'void v8::internal::Clobber(v8::internal::MacroAssembler *,v8::internal::RegList,const uint64_t)'
    
        Solution is to construct with explicit type.
    
        Bug: v8:13312
        Change-Id: I66f5ba48bcdf6eb30035beaf7214a3d26fc9f18b
        Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/3913034
        Reviewed-by: Igor Sheludko <ishell@chromium.org>
        Commit-Queue: Jakob Kummerow <jkummerow@chromium.org>
        Reviewed-by: Jakob Kummerow <jkummerow@chromium.org>
        Cr-Commit-Position: refs/heads/main@{#83406}
    
    Refs: v8/v8@7ddb839
    targos committed Oct 10, 2022
    Configuration menu
    Copy the full SHA
    86ec914 View commit details
    Browse the repository at this point in the history
  14. deps: V8: cherry-pick 0cccb6f27d78

    Original commit message:
    
        [msvc] fix missing include <optional>
    
        clang/clang-cl compiled happily (probably included transitively this
        header), but not MSVC.
    
        Bug: v8:13312
    
        Change-Id: I69b6c15f76d8ef13e4fac33f733717429ba96f71
        Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/3913033
        Reviewed-by: Jakob Kummerow <jkummerow@chromium.org>
        Commit-Queue: Jakob Kummerow <jkummerow@chromium.org>
        Cr-Commit-Position: refs/heads/main@{#83402}
    
    Refs: v8/v8@0cccb6f
    targos committed Oct 10, 2022
    Configuration menu
    Copy the full SHA
    a5cd6b4 View commit details
    Browse the repository at this point in the history
  15. Configuration menu
    Copy the full SHA
    ea7534b View commit details
    Browse the repository at this point in the history
  16. Configuration menu
    Copy the full SHA
    f2e6dee View commit details
    Browse the repository at this point in the history
  17. build: enable V8's trap handler on Windows

    It can now be compiled with MSVC.
    targos committed Oct 10, 2022
    Configuration menu
    Copy the full SHA
    a05b783 View commit details
    Browse the repository at this point in the history
  18. Configuration menu
    Copy the full SHA
    6cb6863 View commit details
    Browse the repository at this point in the history
  19. src: use V8_ENABLE_SANDBOX macro

    It was renamed from V8_SANDBOX
    targos committed Oct 10, 2022
    Configuration menu
    Copy the full SHA
    40ee240 View commit details
    Browse the repository at this point in the history
  20. src,test: disable freezing V8 flags on initialization

    Node.js still changes flags after initializationg; either because
    tests need to set their own flags (which V8 tests also still allow),
    or because it's explicitly requested via the "v8.setFlagsFromString"
    method that Node.js provides.
    backes authored and targos committed Oct 10, 2022
    Configuration menu
    Copy the full SHA
    ddc52e3 View commit details
    Browse the repository at this point in the history
  21. src: override CreateJob instead of PostJob

    PostJob will call out to CreateJob in its default implementation, so
    it's sufficient to only override CreateJob.
    backes authored and targos committed Oct 10, 2022
    Configuration menu
    Copy the full SHA
    507dd20 View commit details
    Browse the repository at this point in the history
  22. Configuration menu
    Copy the full SHA
    57141ae View commit details
    Browse the repository at this point in the history
  23. test: fix test-hash-seed for new V8 versions

    The test relied on V8 not optimizing functions that use `set.has()`.
    Force V8 to not optimize it now that TurboFan knows about this method.
    targos committed Oct 10, 2022
    Configuration menu
    Copy the full SHA
    2072839 View commit details
    Browse the repository at this point in the history
  24. Configuration menu
    Copy the full SHA
    8ffa0a6 View commit details
    Browse the repository at this point in the history
  25. Configuration menu
    Copy the full SHA
    fd9258c View commit details
    Browse the repository at this point in the history
  26. Configuration menu
    Copy the full SHA
    e8c7083 View commit details
    Browse the repository at this point in the history
  27. test: adapt test-repl for V8 update

    The inspector console now has a new `createTask` method.
    targos committed Oct 10, 2022
    Configuration menu
    Copy the full SHA
    f69fe5d View commit details
    Browse the repository at this point in the history