[PATCH] D146908: [clang][MinGW] Add asan link flags before other libs and objects

2023-03-28 Thread Martin Storsjö via Phabricator via cfe-commits
mstorsjo 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: "{{[^"]*}

[PATCH] D146908: [clang][MinGW] Add asan link flags before other libs and objects

2023-03-28 Thread Alvin Wong via Phabricator via cfe-commits
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: "{{[^"

[PATCH] D146908: [clang][MinGW] Add asan link flags before other libs and objects

2023-03-28 Thread Martin Storsjö via Phabricator via cfe-commits
mstorsjo 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: "{{[^"]*}

[PATCH] D146908: [clang][MinGW] Add asan link flags before other libs and objects

2023-03-28 Thread Alvin Wong via Phabricator via cfe-commits
alvinhochun added a comment. In D146908#4226926 , @mstorsjo wrote: > I tested this, and this does fix the repro from the linked issue. Thanks for testing! > I wonder if we do want to move all of these before the app itself, or if it's > enough to just

[PATCH] D146908: [clang][MinGW] Add asan link flags before other libs and objects

2023-03-28 Thread Martin Storsjö via Phabricator via cfe-commits
mstorsjo added a comment. I tested this, and this does fix the repro from the linked issue. I wonder if we do want to move all of these before the app itself, or if it's enough to just move the reference to `asan_dynamic-.dll.a` earlier, and keep the rest as it was? Especially the whole-archive

[PATCH] D146908: [clang][MinGW] Add asan link flags before other libs and objects

2023-03-27 Thread Alvin Wong via Phabricator via cfe-commits
alvinhochun updated this revision to Diff 508751. alvinhochun added a comment. Trying to fix the test... Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D146908/new/ https://reviews.llvm.org/D146908 Files: clang/lib/Driver/ToolChains/MinGW.cpp cl

[PATCH] D146908: [clang][MinGW] Add asan link flags before other libs and objects

2023-03-26 Thread Alvin Wong via Phabricator via cfe-commits
alvinhochun created this revision. alvinhochun added reviewers: mstorsjo, MaskRay. Herald added a project: All. alvinhochun requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. As stated in https://github.com/llvm/llvm-project/issues/61685, by p