r210584 - Fix crash with x86_64-pc-win32-macho target. <rdar://problem/17235840>
Eric Christopher
echristo at gmail.com
Tue Jun 10 14:29:04 PDT 2014
What are you trying to test with this test? It's currently invoking
the backend and I'm not sure I see a reason for it given the original
change is only to header search?
-eric
On Tue, Jun 10, 2014 at 2:07 PM, Bob Wilson <bob.wilson at apple.com> wrote:
> Author: bwilson
> Date: Tue Jun 10 16:07:12 2014
> New Revision: 210584
>
> URL: http://llvm.org/viewvc/llvm-project?rev=210584&view=rev
> Log:
> Fix crash with x86_64-pc-win32-macho target. <rdar://problem/17235840>
>
> The changes in r204978 broke win32-macho targets. There were checks added for
> MSVC and Itanium environments as special cases, and win32-macho needs to be
> treated the same way.
>
> Added:
> cfe/trunk/test/Misc/win32-macho.c
> Modified:
> cfe/trunk/lib/Frontend/InitHeaderSearch.cpp
>
> Modified: cfe/trunk/lib/Frontend/InitHeaderSearch.cpp
> URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/lib/Frontend/InitHeaderSearch.cpp?rev=210584&r1=210583&r2=210584&view=diff
> ==============================================================================
> --- cfe/trunk/lib/Frontend/InitHeaderSearch.cpp (original)
> +++ cfe/trunk/lib/Frontend/InitHeaderSearch.cpp Tue Jun 10 16:07:12 2014
> @@ -472,7 +472,8 @@ void InitHeaderSearch::AddDefaultInclude
>
> case llvm::Triple::Win32:
> if (triple.getEnvironment() == llvm::Triple::MSVC ||
> - triple.getEnvironment() == llvm::Triple::Itanium)
> + triple.getEnvironment() == llvm::Triple::Itanium ||
> + triple.getObjectFormat() == llvm::Triple::MachO)
> return;
> break;
> }
>
> Added: cfe/trunk/test/Misc/win32-macho.c
> URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/test/Misc/win32-macho.c?rev=210584&view=auto
> ==============================================================================
> --- cfe/trunk/test/Misc/win32-macho.c (added)
> +++ cfe/trunk/test/Misc/win32-macho.c Tue Jun 10 16:07:12 2014
> @@ -0,0 +1,2 @@
> +// Check that basic use of win32-macho targets works.
> +// RUN: %clang -c -target x86_64-pc-win32-macho %s
>
>
> _______________________________________________
> cfe-commits mailing list
> cfe-commits at cs.uiuc.edu
> http://lists.cs.uiuc.edu/mailman/listinfo/cfe-commits
More information about the cfe-commits
mailing list