From e1e2f81165ae75576a0201f342e7f1ea2ca40273 Mon Sep 17 00:00:00 2001 From: Victor Mustya Date: Thu, 25 Jul 2024 20:32:04 +0000 Subject: [PATCH] Support MMX removal in LLVM upstream This change is required to support the LLVM change: https://github.com/llvm/llvm-project/commit/dfeb3991fb489a703f631ab0c34b58f80568038d --- GenXIntrinsics/lib/GenXIntrinsics/GenXIntrinsics.cpp | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/GenXIntrinsics/lib/GenXIntrinsics/GenXIntrinsics.cpp b/GenXIntrinsics/lib/GenXIntrinsics/GenXIntrinsics.cpp index eebd007..1105311 100644 --- a/GenXIntrinsics/lib/GenXIntrinsics/GenXIntrinsics.cpp +++ b/GenXIntrinsics/lib/GenXIntrinsics/GenXIntrinsics.cpp @@ -1,6 +1,6 @@ /*========================== begin_copyright_notice ============================ -Copyright (C) 2019-2023 Intel Corporation +Copyright (C) 2019-2024 Intel Corporation SPDX-License-Identifier: MIT @@ -301,7 +301,12 @@ static Type *DecodeFixedType(ArrayRef &Infos, switch (D.Kind) { case IITDescriptor::Void: return Type::getVoidTy(Context); case IITDescriptor::VarArg: return Type::getVoidTy(Context); - case IITDescriptor::MMX: return Type::getX86_MMXTy(Context); + case IITDescriptor::MMX: +#if VC_INTR_LLVM_VERSION_MAJOR >= 20 + return FixedVectorType::get(Type::getInt64Ty(Context), 1); +#else // VC_INTR_LLVM_VERSION_MAJOR >= 20 + return Type::getX86_MMXTy(Context); +#endif // VC_INTR_LLVM_VERSION_MAJOR >= 20 case IITDescriptor::Token: return Type::getTokenTy(Context); case IITDescriptor::Metadata: return Type::getMetadataTy(Context); case IITDescriptor::Half: return Type::getHalfTy(Context);