v8/gni
Nico Weber 5f644d7e71 Make creating x64 snapshots on arm64 hosts mostly work
The motivation is being able to build Chrome/Mac/Intel on an
Apple Silicon mac.

Depends on https://chromium-review.googlesource.com/c/chromium/src/+/3348020

- Correctly set v8_snapshot_toolchain when targeting x64 on an arm64
  host (always use the clang_ toolchain for now since that's all
  that's needed at the moment)

- Check V8_HOST_ARCH in immediate-crash.h. In V8 terminology, "host"
  is the machine the snapshot generation runs on, while "target" is the
  machine that V8 runs on when it JITs. IMMEDIATE_CRASH runs on the
  host. Up to now, target arch x64 implied host arch x64 so the old code
  happened to work too, but this is the correct macro (and it makes this
  cross scenario work).

- In assembler-x64.cc, only compile the code that probes the current CPU
  when running on an intel host. (There's an early return for snapshot
  generation anyways.)

Bug: chromium:1280968
Change-Id: I4821a5994de8ed5f9e4f62184dc6ab6f5223bc3f
Reviewed-on: https://chromium-review.googlesource.com/c/v8/v8/+/3348040
Reviewed-by: Leszek Swirski <leszeks@chromium.org>
Reviewed-by: Toon Verwaest <verwaest@chromium.org>
Commit-Queue: Nico Weber <thakis@chromium.org>
Cr-Commit-Position: refs/heads/main@{#78417}
2021-12-20 17:27:02 +00:00
..
OWNERS Use relative paths to OWNERS files 2019-08-12 13:52:52 +00:00
proto_library.gni tracing: Initialize track events conditionally 2021-01-18 12:39:03 +00:00
protoc.py tracing: Initialize track events conditionally 2021-01-18 12:39:03 +00:00
snapshot_toolchain.gni Make creating x64 snapshots on arm64 hosts mostly work 2021-12-20 17:27:02 +00:00
split_static_library.gni [build] Move split_static_library.gni from Chromium repo 2019-11-04 15:45:54 +00:00
v8.cmx [Fuchsia] Deprecate tests-with-exec.cmx from v8 2021-04-02 15:04:11 +00:00
v8.gni [Infra] Remove trusted variant. 2021-08-13 13:37:23 +00:00