undef setjmp in PPCCTRLoops

Trying to unbreak the VS build by copying some undef code from
Utils/LowerInvoke.cpp.

llvm-svn: 181938
This commit is contained in:
Hal Finkel 2013-05-15 22:20:24 +00:00
parent 8ce4c34d1d
commit ae8f6158eb

View File

@ -188,7 +188,23 @@ bool PPCCTRLoops::convertToCTRLoop(Loop *L) {
if (F->getIntrinsicID() != Intrinsic::not_intrinsic) {
switch (F->getIntrinsicID()) {
default: continue;
// VisualStudio defines setjmp as _setjmp
#if defined(_MSC_VER) && defined(setjmp) && \
!defined(setjmp_undefined_for_msvc)
# pragma push_macro("setjmp")
# undef setjmp
# define setjmp_undefined_for_msvc
#endif
case Intrinsic::setjmp:
#if defined(_MSC_VER) && defined(setjmp_undefined_for_msvc)
// let's return it to _setjmp state
# pragma pop_macro("setjmp")
# undef setjmp_undefined_for_msvc
#endif
case Intrinsic::longjmp:
case Intrinsic::memcpy:
case Intrinsic::memmove: