MCPcopy Create free account
hub / github.com/nodejs/node / get_target_cpu

Method get_target_cpu

deps/v8/tools/dev/gm.py:551–571  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

549 self.mode = mode
550
551 def get_target_cpu(self):
552 cpu = "x86"
553 if self.arch == "android_arm":
554 cpu = "arm"
555 elif self.arch == "android_arm64" or self.arch == "fuchsia_arm64":
556 cpu = "arm64"
557 elif self.arch == "android_riscv64":
558 cpu = "riscv64"
559 elif self.arch == "arm64" and _get_machine() in ("aarch64", "arm64"):
560 # arm64 build host:
561 cpu = "arm64"
562 elif self.arch == "arm" and _get_machine() in ("aarch64", "arm64"):
563 cpu = "arm"
564 elif self.arch == "loong64" and _get_machine() == "loongarch64":
565 cpu = "loong64"
566 elif self.arch == "mips64el" and _get_machine() == "mips64":
567 cpu = "mips64el"
568 elif "64" in self.arch or self.arch == "s390x":
569 # Native x64 or simulator build.
570 cpu = "x64"
571 return [f"target_cpu = \"{cpu}\""]
572
573 def get_v8_target_cpu(self):
574 if self.arch == "android_arm":

Callers 1

get_gn_argsMethod · 0.95

Calls 1

_get_machineFunction · 0.85

Tested by

no test coverage detected