[llvm] 9abae17 - [UpdateTestChecks][llc] Support `arm64-apple-darwin` (#165092)

via llvm-commits llvm-commits at lists.llvm.org
Mon Oct 27 12:22:26 PDT 2025


Author: Tomer Shafir
Date: 2025-10-27T21:22:23+02:00
New Revision: 9abae17b25f937376e5036b080b473f948232968

URL: https://github.com/llvm/llvm-project/commit/9abae17b25f937376e5036b080b473f948232968
DIFF: https://github.com/llvm/llvm-project/commit/9abae17b25f937376e5036b080b473f948232968.diff

LOG: [UpdateTestChecks][llc] Support `arm64-apple-darwin` (#165092)

Adds `arm64-apple-darwin` support to `asm.py` matching and removes now
invalidated `target-triple-mismatch` test (I dont have another triple
supported by llc but not the autogenerator that make this test useful).

Added: 
    

Modified: 
    llvm/utils/UpdateTestChecks/asm.py

Removed: 
    llvm/test/tools/UpdateTestChecks/update_llc_test_checks/Inputs/target-triple-mismatch.ll
    llvm/test/tools/UpdateTestChecks/update_llc_test_checks/target-triple-mismatch.test


################################################################################
diff  --git a/llvm/test/tools/UpdateTestChecks/update_llc_test_checks/Inputs/target-triple-mismatch.ll b/llvm/test/tools/UpdateTestChecks/update_llc_test_checks/Inputs/target-triple-mismatch.ll
deleted file mode 100644
index 3da27cbacd172..0000000000000
--- a/llvm/test/tools/UpdateTestChecks/update_llc_test_checks/Inputs/target-triple-mismatch.ll
+++ /dev/null
@@ -1,7 +0,0 @@
-; RUN: llc < %s -mtriple=arm64-apple-darwin | FileCheck %s
-
-define i64 @foo(i64 %a) {
-entry:
-  %b = add i64 %a, 1
-  ret i64 %b
-}

diff  --git a/llvm/test/tools/UpdateTestChecks/update_llc_test_checks/target-triple-mismatch.test b/llvm/test/tools/UpdateTestChecks/update_llc_test_checks/target-triple-mismatch.test
deleted file mode 100644
index 3bbf14d469d4b..0000000000000
--- a/llvm/test/tools/UpdateTestChecks/update_llc_test_checks/target-triple-mismatch.test
+++ /dev/null
@@ -1,11 +0,0 @@
-# REQUIRES: aarch64-registered-target
-## Check that arm64-apple-darwin target triple is wrongly captured as arm64 (non-Apple)
-
-# RUN: cp -f %S/Inputs/target-triple-mismatch.ll %t.ll
-# RUN: %update_llc_test_checks %t.ll 2>&1 | FileCheck %s --check-prefix=LOG
-# RUN: FileCheck --input-file=%t.ll %s --check-prefix=AUTOGEN
-
-# LOG: WARNING: Couldn't match any function. Possibly the wrong target triple has been provided
-
-# AUTOGEN: ;; NOTE: These prefixes are unused and the list is autogenerated. Do not add tests below this line:
-# AUTOGEN-NEXT: ; CHECK: {{.*}}

diff  --git a/llvm/utils/UpdateTestChecks/asm.py b/llvm/utils/UpdateTestChecks/asm.py
index 457b23f4a5f59..469e27facedb0 100644
--- a/llvm/utils/UpdateTestChecks/asm.py
+++ b/llvm/utils/UpdateTestChecks/asm.py
@@ -570,6 +570,7 @@ def get_run_handler(triple):
         "arm64": (scrub_asm_arm_eabi, ASM_FUNCTION_AARCH64_RE),
         "arm64e": (scrub_asm_arm_eabi, ASM_FUNCTION_AARCH64_DARWIN_RE),
         "arm64ec": (scrub_asm_arm_eabi, ASM_FUNCTION_AARCH64_RE),
+        "arm64-apple-darwin": (scrub_asm_arm_eabi, ASM_FUNCTION_AARCH64_DARWIN_RE),
         "arm64-apple-ios": (scrub_asm_arm_eabi, ASM_FUNCTION_AARCH64_DARWIN_RE),
         "arm64-apple-macosx": (scrub_asm_arm_eabi, ASM_FUNCTION_AARCH64_DARWIN_RE),
         "armv7-apple-ios": (scrub_asm_arm_eabi, ASM_FUNCTION_ARM_IOS_RE),


        


More information about the llvm-commits mailing list