[llvm] [llvm-rc] Support ARM64EC resource generation (PR #78908)
Billy Laws via llvm-commits
llvm-commits at lists.llvm.org
Sun Jan 21 11:11:43 PST 2024
https://github.com/bylaws created https://github.com/llvm/llvm-project/pull/78908
This is already supported in llvm-cvtres, so only a small change is needed.
CC: @cjacek
>From bd81ecc93b7717c1e642625ada3adce9ec45636c Mon Sep 17 00:00:00 2001
From: Billy Laws <blaws05 at gmail.com>
Date: Sun, 21 Jan 2024 18:43:56 +0000
Subject: [PATCH] [llvm-rc] Support ARM64EC resource generation
---
llvm/tools/llvm-rc/llvm-rc.cpp | 5 ++++-
1 file changed, 4 insertions(+), 1 deletion(-)
diff --git a/llvm/tools/llvm-rc/llvm-rc.cpp b/llvm/tools/llvm-rc/llvm-rc.cpp
index 1c3379a3a96786..51214524adeef6 100644
--- a/llvm/tools/llvm-rc/llvm-rc.cpp
+++ b/llvm/tools/llvm-rc/llvm-rc.cpp
@@ -710,7 +710,10 @@ void doCvtres(std::string Src, std::string Dest, std::string TargetTriple) {
MachineType = COFF::IMAGE_FILE_MACHINE_ARMNT;
break;
case Triple::aarch64:
- MachineType = COFF::IMAGE_FILE_MACHINE_ARM64;
+ if (T.isWindowsArm64EC())
+ MachineType = COFF::IMAGE_FILE_MACHINE_ARM64EC;
+ else
+ MachineType = COFF::IMAGE_FILE_MACHINE_ARM64;
break;
default:
fatalError("Unsupported architecture in target '" + Twine(TargetTriple) +
More information about the llvm-commits
mailing list