From 8baa14ee4254888c3e8ceb454281f035aec2cce1 Mon Sep 17 00:00:00 2001 From: Max Horn Date: Thu, 19 Nov 2020 11:26:38 +0100 Subject: [PATCH] Fix LLVM deprecation warnings --- src/abi_aarch64.cpp | 2 +- src/abi_ppc64le.cpp | 2 +- src/cgutils.cpp | 4 ++-- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/src/abi_aarch64.cpp b/src/abi_aarch64.cpp index e429885717b65..a5d998b527b8e 100644 --- a/src/abi_aarch64.cpp +++ b/src/abi_aarch64.cpp @@ -23,7 +23,7 @@ Type *get_llvm_vectype(jl_datatype_t *dt) const assert(nfields > 0); if (nfields < 2) return nullptr; -#if JL_LLVM_VERSION >= 120000 +#if JL_LLVM_VERSION >= 110000 static Type *T_vec64 = FixedVectorType::get(T_int32, 2); static Type *T_vec128 = FixedVectorType::get(T_int32, 4); #else diff --git a/src/abi_ppc64le.cpp b/src/abi_ppc64le.cpp index 8689a6f4fc0ab..d4b4f0542f30e 100644 --- a/src/abi_ppc64le.cpp +++ b/src/abi_ppc64le.cpp @@ -134,7 +134,7 @@ Type *preferred_llvm_type(jl_datatype_t *dt, bool isret) const override jl_datatype_t *vecty = (jl_datatype_t*)jl_field_type(ty0, 0); assert(jl_is_datatype(vecty) && vecty->name == jl_vecelement_typename); Type *ety = bitstype_to_llvm(jl_tparam0(vecty)); -#if JL_LLVM_VERSION >= 120000 +#if JL_LLVM_VERSION >= 110000 Type *vty = FixedVectorType::get(ety, jl_datatype_nfields(ty0)); #else Type *vty = VectorType::get(ety, jl_datatype_nfields(ty0)); diff --git a/src/cgutils.cpp b/src/cgutils.cpp index d981971b92018..af2b8c2274ea8 100644 --- a/src/cgutils.cpp +++ b/src/cgutils.cpp @@ -625,7 +625,7 @@ static Type *_julia_struct_to_llvm(jl_codegen_params_t *ctx, jl_value_t *jt, jl_ // We may need to insert padding first to get to the right offset if (al > MAX_ALIGN) { Type *AlignmentType; -#if JL_LLVM_VERSION >= 120000 +#if JL_LLVM_VERSION >= 110000 AlignmentType = ArrayType::get(FixedVectorType::get(T_int8, al), 0); #else AlignmentType = ArrayType::get(VectorType::get(T_int8, al), 0); @@ -669,7 +669,7 @@ static Type *_julia_struct_to_llvm(jl_codegen_params_t *ctx, jl_value_t *jt, jl_ } else if (isarray && !type_is_ghost(lasttype)) { if (isTuple && isvector && jl_special_vector_alignment(ntypes, jlasttype) != 0) -#if JL_LLVM_VERSION >= 120000 +#if JL_LLVM_VERSION >= 110000 struct_decl = FixedVectorType::get(lasttype, ntypes); #else struct_decl = VectorType::get(lasttype, ntypes);