alvinhochun added inline comments.

================
Comment at: clang/test/Driver/mingw-sanitizers.c:1
-// RUN: %clang -target i686-windows-gnu %s -### -fsanitize=address 2>&1 | 
FileCheck --check-prefix=ASAN-I686 %s
-// ASAN-I686: "{{.*}}libclang_rt.asan_dynamic-i386.dll.a"
-// ASAN-I686: "{{[^"]*}}libclang_rt.asan_dynamic_runtime_thunk-i386.a"
-// ASAN-I686: "--require-defined" "___asan_seh_interceptor"
-// ASAN-I686: "--whole-archive" 
"{{.*}}libclang_rt.asan_dynamic_runtime_thunk-i386.a" "--no-whole-archive"
-
-// RUN: %clang -target x86_64-windows-gnu %s -### -fsanitize=address 2>&1 | 
FileCheck --check-prefix=ASAN-X86_64 %s
-// ASAN-X86_64: "{{.*}}libclang_rt.asan_dynamic-x86_64.dll.a"
+// RUN: echo -n > %t.a
+// RUN: %clang -target i686-windows-gnu %s -### -fsanitize=address -lcomponent 
%/t.a 2>&1 | FileCheck --check-prefixes=ASAN-ALL,ASAN-I686 -DINPUT=%/t.a %s
----------------
mstorsjo wrote:
> alvinhochun wrote:
> > mstorsjo wrote:
> > > Hm, what does this do - some sort of more portable version of just 
> > > touching a file to create it?
> > Yeah that's just creating the file (though it would also overwrite the 
> > existing content). I believe lit has `echo` built-in but `touch` may not be 
> > available on Windows so this seems like a good idea to me.
> Ah, I see. FWIW, the lit tests in general do assume a handful of unix 
> utilities - we seem to have unconditional uses of `touch` in various tests. 
> The lit tests check if these tools are available in path, and if they aren't, 
> it tries to locate an installation of Git for Windows (which contains what's 
> needed) and add that to the path internally: 
> https://github.com/llvm/llvm-project/blob/llvmorg-17-init/llvm/utils/lit/lit/llvm/config.py#L29-L35
I suppose that works. Would you prefer to use touch here too?


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D146908/new/

https://reviews.llvm.org/D146908

_______________________________________________
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to