Skip to content

Conversation

@UsmanNadeem
Copy link
Contributor

We have been seeing buildbot failures due to #122629. I posted #135571 to update the triple normalization logic, but that patch hasn't gotten any traction.

So in this patch I am updating the lit config to use triple from clang's output for %itanium_abi_triple substitution, instead of relying on self.config.target_triple which might not be in a canonical form.

Buildbot failure example: https://lab.llvm.org/buildbot/#/builders/40

Change-Id: Ib9c3425fddac45d7468fad20929fd29358a55e1b

We have been seeing buildbot failures due to llvm#122629
I posted llvm#135571 to update the
triple normalization logic, but that patch hasn't gotten any traction.

So in this patch I am updating the lit config to use triple from clang's
output for `%itanium_abi_triple` substitution, instead of relying on
`self.config.target_triple` which might not be in a canonical form.

Buildbot failure example: https://lab.llvm.org/buildbot/#/builders/40

Change-Id: Ib9c3425fddac45d7468fad20929fd29358a55e1b
@llvmbot
Copy link
Member

llvmbot commented May 6, 2025

@llvm/pr-subscribers-testing-tools

Author: Usman Nadeem (UsmanNadeem)

Changes

We have been seeing buildbot failures due to #122629. I posted #135571 to update the triple normalization logic, but that patch hasn't gotten any traction.

So in this patch I am updating the lit config to use triple from clang's output for %itanium_abi_triple substitution, instead of relying on self.config.target_triple which might not be in a canonical form.

Buildbot failure example: https://lab.llvm.org/buildbot/#/builders/40

Change-Id: Ib9c3425fddac45d7468fad20929fd29358a55e1b


Full diff: https://github.com/llvm/llvm-project/pull/138747.diff

1 Files Affected:

  • (modified) llvm/utils/lit/lit/llvm/config.py (+5-1)
diff --git a/llvm/utils/lit/lit/llvm/config.py b/llvm/utils/lit/lit/llvm/config.py
index c134cda90e2ee..4715936a6e51c 100644
--- a/llvm/utils/lit/lit/llvm/config.py
+++ b/llvm/utils/lit/lit/llvm/config.py
@@ -674,7 +674,11 @@ def use_clang(
                 (
                     "%itanium_abi_triple",
                     self.normalize_triple(
-                        self.make_itanium_abi_triple(self.config.target_triple)
+                        self.make_itanium_abi_triple(
+                            self.get_process_output(
+                                [self.config.clang, "--print-target-triple"]
+                            )[0].split("\n")[0]
+                        )
                     ),
                 )
             )

@UsmanNadeem UsmanNadeem marked this pull request as draft May 7, 2025 00:39
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants