From 6ef5adeb3300124c9d800a70f4bf6c5aa720a7f8 Mon Sep 17 00:00:00 2001 From: Ivan Butygin Date: Mon, 24 Feb 2025 18:45:39 +0100 Subject: [PATCH 1/2] [mlir] Strip spaces from host_cxx/host_cc Continuation of https://github.com/llvm/llvm-project/pull/128439 Some builders have spaces at the end of the host_cc path, which now breaks. --- mlir/test/lit.cfg.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/mlir/test/lit.cfg.py b/mlir/test/lit.cfg.py index 32b2f8b53d5fa..6222acfafdcdd 100644 --- a/mlir/test/lit.cfg.py +++ b/mlir/test/lit.cfg.py @@ -55,8 +55,8 @@ config.substitutions.append(("%shlibext", config.llvm_shlib_ext)) config.substitutions.append(("%llvm_src_root", config.llvm_src_root)) config.substitutions.append(("%mlir_src_root", config.mlir_src_root)) -config.substitutions.append(("%host_cxx", config.host_cxx)) -config.substitutions.append(("%host_cc", config.host_cc)) +config.substitutions.append(("%host_cxx", config.host_cxx.strip())) +config.substitutions.append(("%host_cc", config.host_cc.strip())) # Searches for a runtime library with the given name and returns the found path. From 804b41dd85be589164ecb322cb9d69b354e53a16 Mon Sep 17 00:00:00 2001 From: Ivan Butygin Date: Mon, 24 Feb 2025 22:01:38 +0100 Subject: [PATCH 2/2] escape "%host_cc" --- mlir/test/Integration/Dialect/MemRef/memref_abi.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/mlir/test/Integration/Dialect/MemRef/memref_abi.c b/mlir/test/Integration/Dialect/MemRef/memref_abi.c index 3fb19177deb09..110ab449b5a34 100644 --- a/mlir/test/Integration/Dialect/MemRef/memref_abi.c +++ b/mlir/test/Integration/Dialect/MemRef/memref_abi.c @@ -12,7 +12,7 @@ // RUN: llc %t.ll -o %t.o -filetype=obj // Compile the current C file and link it to the MLIR code: -// RUN: %host_cc %s %t.o -o %t.exe +// RUN: "%host_cc" %s %t.o -o %t.exe // Exec // RUN: %t.exe | FileCheck %s