diff --git a/GenXIntrinsics/lib/GenXIntrinsics/AdaptorsCommon.cpp b/GenXIntrinsics/lib/GenXIntrinsics/AdaptorsCommon.cpp index 7a43aafb..6c6459c4 100644 --- a/GenXIntrinsics/lib/GenXIntrinsics/AdaptorsCommon.cpp +++ b/GenXIntrinsics/lib/GenXIntrinsics/AdaptorsCommon.cpp @@ -40,7 +40,9 @@ void legalizeParamAttributes(Function *F) { continue; #if VC_INTR_LLVM_VERSION_MAJOR >= 13 +#if VC_INTR_LLVM_VERSION_MAJOR < 18 if (PTy->isOpaque()) +#endif // VC_INTR_LLVM_VERSION_MAJOR < 18 continue; #endif // VC_INTR_LLVM_VERSION_MAJOR >= 13 diff --git a/GenXIntrinsics/lib/GenXIntrinsics/GenXIntrinsics.cpp b/GenXIntrinsics/lib/GenXIntrinsics/GenXIntrinsics.cpp index bd386383..8597f91a 100644 --- a/GenXIntrinsics/lib/GenXIntrinsics/GenXIntrinsics.cpp +++ b/GenXIntrinsics/lib/GenXIntrinsics/GenXIntrinsics.cpp @@ -431,7 +431,9 @@ static std::string getMangledTypeStr(Type *Ty) { if (PointerType *PTyp = dyn_cast(Ty)) { Result += "p" + llvm::utostr(PTyp->getAddressSpace()); #if VC_INTR_LLVM_VERSION_MAJOR >= 13 +#if VC_INTR_LLVM_VERSION_MAJOR < 18 if (PTyp->isOpaque()) +#endif // VC_INTR_LLVM_VERSION_MAJOR < 18 return Result; #endif // VC_INTR_LLVM_VERSION_MAJOR >= 13 Result += getMangledTypeStr(VCINTR::Type::getNonOpaquePtrEltTy(PTyp));