Skip to content

chore: update V8 to 13.8.258.26 #442

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

Merged
merged 13 commits into from
Jul 26, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
19 changes: 9 additions & 10 deletions .bazelrc
Original file line number Diff line number Diff line change
Expand Up @@ -55,6 +55,7 @@ build:clang-tsan --config=clang-xsan
build:clang-tsan --copt -DTHREAD_SANITIZER=1
build:clang-tsan --copt -fsanitize=thread
build:clang-tsan --linkopt -fsanitize=thread
build:clang-tsan --test_env=TSAN_OPTIONS=suppressions=bazel/tsan_suppressions.txt

# Use Clang-Tidy tool.
build:clang-tidy --config=clang
Expand All @@ -67,17 +68,14 @@ build:gcc --action_env=BAZEL_COMPILER=gcc
build:gcc --action_env=CC=gcc
build:gcc --action_env=CXX=g++

# Use Zig C/C++ compiler.
build:zig-cc --incompatible_enable_cc_toolchain_resolution
build:zig-cc --extra_toolchains @zig_sdk//:aarch64-linux-gnu.2.28_toolchain
build:zig-cc --extra_toolchains @zig_sdk//:x86_64-linux-gnu.2.28_toolchain
build:zig-cc --host_copt=-fno-sanitize=undefined
build:hermetic-llvm --incompatible_enable_cc_toolchain_resolution
build:hermetic-llvm --action_env BAZEL_DO_NOT_DETECT_CPP_TOOLCHAIN=1
build:hermetic-llvm --extra_toolchains @emsdk//emscripten_toolchain:cc-toolchain-wasm

# Use Zig C/C++ compiler (cross-compile to Linux/aarch64).
build:zig-cc-linux-aarch64 --config=zig-cc
build:zig-cc-linux-aarch64 --platforms @zig_sdk//:linux_aarch64_platform
build:zig-cc-linux-aarch64 --run_under=qemu-aarch64-static
build:zig-cc-linux-aarch64 --test_env=QEMU_LD_PREFIX=/usr/aarch64-linux-gnu/
build:hermetic-llvm-macos --config=hermetic-llvm
# Below flags mitigate https://github.com/bazel-contrib/toolchains_llvm/pull/229.
build:hermetic-llvm-macos --features=-libtool
build:hermetic-llvm-macos --features=-supports_dynamic_linker

build --enable_platform_specific_config

Expand All @@ -86,6 +84,7 @@ build:linux --cxxopt=-std=c++20 --host_cxxopt=-std=c++20
build:macos --cxxopt=-std=c++20 --host_cxxopt=-std=c++20
build:windows --cxxopt="/std:c++20" --host_cxxopt="/std:c++20"


# Enable symlinks and runfiles on Windows (enabled by default on other platforms).
startup --windows_enable_symlinks
build:windows --enable_runfiles
17 changes: 8 additions & 9 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -139,23 +139,23 @@ jobs:
os: ubuntu-24.04
arch: x86_64
action: test
flags: --config=clang --define=crypto=system
flags: --config=hermetic-llvm --define=crypto=system
cache: true
- name: 'V8 on Linux/x86_64 with ASan'
engine: 'v8'
repo: 'v8'
os: ubuntu-24.04
arch: x86_64
action: test
flags: --config=clang-asan
flags: --config=hermetic-llvm --config=clang-asan
cache: true
- name: 'V8 on Linux/x86_64 with TSan'
engine: 'v8'
repo: 'v8'
os: ubuntu-24.04
arch: x86_64
action: test
flags: --config=clang-tsan
flags: --config=hermetic-llvm --config=clang-tsan
cache: true
- name: 'V8 on Linux/x86_64 with GCC'
engine: 'v8'
Expand All @@ -168,19 +168,19 @@ jobs:
- name: 'V8 on Linux/aarch64'
engine: 'v8'
repo: 'v8'
os: ubuntu-24.04
os: ubuntu-24.04-arm
arch: aarch64
action: test
targets: -//test/fuzz/...
flags: --config=zig-cc-linux-aarch64 --@v8//bazel/config:v8_target_cpu=arm64
deps: qemu-user-static libc6-arm64-cross
flags: --config=hermetic-llvm --@v8//bazel/config:v8_target_cpu=arm64
cache: true
- name: 'V8 on macOS/x86_64'
engine: 'v8'
repo: 'v8'
os: macos-13
arch: x86_64
action: test
flags: --config=hermetic-llvm-macos
cache: true
- name: 'WAMR interp on Linux/x86_64'
engine: 'wamr-interp'
Expand Down Expand Up @@ -241,11 +241,10 @@ jobs:
- name: 'Wasmtime on Linux/aarch64'
engine: 'wasmtime'
repo: 'com_github_bytecodealliance_wasmtime'
os: ubuntu-24.04
os: ubuntu-24.04-arm
arch: aarch64
action: build
flags: --config=zig-cc-linux-aarch64
deps: qemu-user-static libc6-arm64-cross
flags: --config=hermetic-llvm
- name: 'Wasmtime on Linux/s390x'
engine: 'wasmtime'
repo: 'com_github_bytecodealliance_wasmtime'
Expand Down
2 changes: 2 additions & 0 deletions bazel/BUILD
Original file line number Diff line number Diff line change
Expand Up @@ -68,3 +68,5 @@ selects.config_setting_group(
":linux_s390x",
],
)

exports_files(["tsan_suppressions.txt"])
22 changes: 22 additions & 0 deletions bazel/cc_defs.bzl
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
# Copyright 2025 Google LLC
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.

load("@rules_cc//cc:defs.bzl", _cc_test = "cc_test")
load("@rules_fuzzing//fuzzing:cc_defs.bzl", _cc_fuzz_test = "cc_fuzz_test")

def cc_test(data = [], **kwargs):
_cc_test(data = data + ["//bazel:tsan_suppressions.txt"], **kwargs)

def cc_fuzz_test(data = [], **kwargs):
_cc_fuzz_test(data = data + ["//bazel:tsan_suppressions.txt"], **kwargs)
45 changes: 36 additions & 9 deletions bazel/dependencies.bzl
Original file line number Diff line number Diff line change
Expand Up @@ -12,13 +12,15 @@
# See the License for the specific language governing permissions and
# limitations under the License.

load("@bazel-zig-cc//toolchain:defs.bzl", zig_register_toolchains = "register_toolchains")
load("@com_google_protobuf//:protobuf_deps.bzl", "protobuf_deps")
load("@envoy_toolshed//sysroot:sysroot.bzl", "setup_sysroots")
load("@proxy_wasm_cpp_host//bazel/cargo/wasmsign/remote:crates.bzl", wasmsign_crate_repositories = "crate_repositories")
load("@proxy_wasm_cpp_host//bazel/cargo/wasmtime/remote:crates.bzl", wasmtime_crate_repositories = "crate_repositories")
load("@rules_python//python:repositories.bzl", "py_repositories", "python_register_toolchains")
load("@rules_rust//crate_universe:repositories.bzl", "crate_universe_dependencies")
load("@rules_rust//rust:repositories.bzl", "rust_repositories", "rust_repository_set")
load("@toolchains_llvm//toolchain:deps.bzl", "bazel_toolchain_dependencies")
load("@toolchains_llvm//toolchain:rules.bzl", "llvm_toolchain")

def proxy_wasm_cpp_host_dependencies():
# Bazel extensions.
Expand Down Expand Up @@ -52,14 +54,39 @@ def proxy_wasm_cpp_host_dependencies():
)
crate_universe_dependencies(bootstrap = True)

zig_register_toolchains(
version = "0.9.1",
url_format = "https://ziglang.org/download/{version}/zig-{host_platform}-{version}.tar.xz",
host_platform_sha256 = {
"linux-aarch64": "5d99a39cded1870a3fa95d4de4ce68ac2610cca440336cfd252ffdddc2b90e66",
"linux-x86_64": "be8da632c1d3273f766b69244d80669fe4f5e27798654681d77c992f17c237d7",
"macos-aarch64": "8c473082b4f0f819f1da05de2dbd0c1e891dff7d85d2c12b6ee876887d438287",
"macos-x86_64": "2d94984972d67292b55c1eb1c00de46580e9916575d083003546e9a01166754c",
setup_sysroots()
bazel_toolchain_dependencies()
llvm_toolchain(
name = "llvm_toolchain",
llvm_version = "19.1.0",
sha256 = {
"linux-x86_64": "cee77d641690466a193d9b88c89705de1c02bbad46bde6a3b126793c0a0f2923",
"linux-aarch64": "7bb54afd330fe1a1c2d4c593fa1e2dbe2abd9bf34fb3597994ff41e443cf144b",
"darwin-aarch64": "9da86f64a99f5ce9b679caf54e938736ca269c5e069d0c94ad08b995c5f25c16",
"darwin-x86_64": "264f2f1e8b67f066749349ae8b4943d346cd44e099464164ef21b42a57663540",
},
strip_prefix = {
"linux-x86_64": "LLVM-19.1.0-Linux-X64",
"linux-aarch64": "clang+llvm-19.1.0-aarch64-linux-gnu",
"darwin-aarch64": "LLVM-19.1.0-macOS-ARM64",
"darwin-x86_64": "LLVM-19.1.0-macOS-X64",
},
urls = {
"linux-x86_64": ["https://github.com/llvm/llvm-project/releases/download/llvmorg-19.1.0/LLVM-19.1.0-Linux-X64.tar.xz"],
"linux-aarch64": ["https://github.com/llvm/llvm-project/releases/download/llvmorg-19.1.0/clang+llvm-19.1.0-aarch64-linux-gnu.tar.xz"],
"darwin-aarch64": ["https://github.com/llvm/llvm-project/releases/download/llvmorg-19.1.0/LLVM-19.1.0-macOS-ARM64.tar.xz"],
"darwin-x86_64": ["https://github.com/llvm/llvm-project/releases/download/llvmorg-19.1.0/LLVM-19.1.0-macOS-X64.tar.xz"],
},
)

llvm_toolchain(
name = "llvm_aarch64",
llvm_version = "19.1.0",
toolchain_roots = {
"": "@llvm_toolchain_llvm//",
},
sysroot = {
"linux-aarch64": "@sysroot_linux_arm64//:sysroot",
},
)

Expand Down
3 changes: 3 additions & 0 deletions bazel/dependencies_import.bzl
Original file line number Diff line number Diff line change
Expand Up @@ -13,11 +13,14 @@
# limitations under the License.

load("@fuzzing_py_deps//:requirements.bzl", pip_fuzzing_dependencies = "install_deps")
load("@llvm_toolchain//:toolchains.bzl", "llvm_register_toolchains")
load("@rules_foreign_cc//foreign_cc:repositories.bzl", "rules_foreign_cc_dependencies")
load("@rules_fuzzing//fuzzing:repositories.bzl", "rules_fuzzing_dependencies")
load("@v8_python_deps//:requirements.bzl", pip_v8_dependencies = "install_deps")

def proxy_wasm_cpp_host_dependencies_import():
llvm_register_toolchains()

rules_foreign_cc_dependencies()
rules_fuzzing_dependencies()

Expand Down
12 changes: 12 additions & 0 deletions bazel/external/dragonbox.BUILD
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
load("@rules_cc//cc:defs.bzl", "cc_library")

licenses(["notice"]) # Apache 2

package(default_visibility = ["//visibility:public"])

cc_library(
name = "dragonbox",
srcs = [],
hdrs = ["include/dragonbox/dragonbox.h"],
includes = ["include/"],
)
15 changes: 15 additions & 0 deletions bazel/external/fp16.BUILD
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
load("@rules_cc//cc:defs.bzl", "cc_library")

licenses(["notice"]) # MIT

package(default_visibility = ["//visibility:public"])

cc_library(
name = "FP16",
hdrs = [
"include/fp16.h",
"include/fp16/bitcasts.h",
"include/fp16/fp16.h",
],
includes = ["include/"],
)
21 changes: 21 additions & 0 deletions bazel/external/intel_ittapi.BUILD
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
load("@rules_cc//cc:defs.bzl", "cc_library")

licenses(["notice"])

package(default_visibility = ["//visibility:public"])

cc_library(
name = "lib_ittapi",
srcs = [
"include/ittnotify.h",
"include/jitprofiling.h",
"src/ittnotify/ittnotify_config.h",
"src/ittnotify/jitprofiling.c",
],
hdrs = [
"include/ittnotify.h",
"src/ittnotify/ittnotify_types.h",
],
includes = ["include/"],
visibility = ["//visibility:public"],
)
11 changes: 11 additions & 0 deletions bazel/external/simdutf.BUILD
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
load("@rules_cc//cc:defs.bzl", "cc_library")

licenses(["notice"]) # Apache 2

package(default_visibility = ["//visibility:public"])

cc_library(
name = "simdutf",
srcs = ["simdutf.cpp"],
hdrs = ["simdutf.h"],
)
Loading
Loading