From f99fa6d5fd3c176ffdd9e723fe97d640667b34e6 Mon Sep 17 00:00:00 2001 From: NAKAMURA Takumi Date: Tue, 17 Mar 2015 22:55:01 +0000 Subject: [PATCH] Appease AArch64ISelLowering.cpp miscompiled by g++-4.7.2. I will revert this when 4.7.3 is ready. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@232561 91177308-0d34-0410-b5e6-96231b3b80d8 --- lib/Target/AArch64/AArch64ISelLowering.cpp | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/lib/Target/AArch64/AArch64ISelLowering.cpp b/lib/Target/AArch64/AArch64ISelLowering.cpp index f1073beb32f..464f56780df 100644 --- a/lib/Target/AArch64/AArch64ISelLowering.cpp +++ b/lib/Target/AArch64/AArch64ISelLowering.cpp @@ -7201,6 +7201,12 @@ static SDValue performConcatVectorsCombine(SDNode *N, (N00VT == MVT::v2i64 || N00VT == MVT::v4i32) && N00VT.getScalarSizeInBits() == 4 * VT.getScalarSizeInBits()) { MVT MidVT = (N00VT == MVT::v2i64 ? MVT::v2i32 : MVT::v4i16); +#if defined(__GNUC__) +#if __GNUC__ == 4 && __GNUC_MINOR__ == 7 && __GNUC_PATCHLEVEL__ == 2 + // FIXME: g++-4.7.2 might miscompile PerformDAGCombine(). + asm volatile("":::"memory"); +#endif +#endif MVT ConcatMidVT = MVT::getVectorVT(MidVT.getVectorElementType(), MidVT.getVectorNumElements() * 2); return DAG.getNode( -- 2.34.1