llvmorg-github-actions[bot] wrote:
<!--LLVM PR SUMMARY COMMENT--> @llvm/pr-subscribers-backend-mips Author: Matt Arsenault (arsenm) <details> <summary>Changes</summary> Add type missing signatures for assorted functions which were missing type information. Co-authored-by: Claude Opus 5.5 <noreply@<!-- -->anthropic.com> --- Patch is 513.82 KiB, truncated to 20.00 KiB below, full version: https://github.com/llvm/llvm-project/pull/237483.diff 17 Files Affected: - (modified) llvm/include/llvm/IR/RuntimeLibcalls.td (+123-109) - (modified) llvm/test/Transforms/Util/DeclareRuntimeLibcalls/aarch64.ll (+474-474) - (modified) llvm/test/Transforms/Util/DeclareRuntimeLibcalls/arm.ll (+192-192) - (modified) llvm/test/Transforms/Util/DeclareRuntimeLibcalls/arm64ec.ll (+89-89) - (modified) llvm/test/Transforms/Util/DeclareRuntimeLibcalls/avr.ll (+71-71) - (modified) llvm/test/Transforms/Util/DeclareRuntimeLibcalls/basic.ll (+2-2) - (modified) llvm/test/Transforms/Util/DeclareRuntimeLibcalls/bsd.ll (+279-279) - (modified) llvm/test/Transforms/Util/DeclareRuntimeLibcalls/codegen-opt-flags.ll (+6-6) - (modified) llvm/test/Transforms/Util/DeclareRuntimeLibcalls/hexagon.ll (+186-186) - (modified) llvm/test/Transforms/Util/DeclareRuntimeLibcalls/m68k.ll (+85-85) - (modified) llvm/test/Transforms/Util/DeclareRuntimeLibcalls/mips.ll (+178-178) - (modified) llvm/test/Transforms/Util/DeclareRuntimeLibcalls/msp430.ll (+100-100) - (modified) llvm/test/Transforms/Util/DeclareRuntimeLibcalls/ppc.ll (+305-305) - (modified) llvm/test/Transforms/Util/DeclareRuntimeLibcalls/riscv.ll (+184-184) - (modified) llvm/test/Transforms/Util/DeclareRuntimeLibcalls/sparc.ll (+187-187) - (modified) llvm/test/Transforms/Util/DeclareRuntimeLibcalls/systemz.ll (+198-198) - (modified) llvm/test/Transforms/Util/DeclareRuntimeLibcalls/windows.ll (+276-276) ``````````diff diff --git a/llvm/include/llvm/IR/RuntimeLibcalls.td b/llvm/include/llvm/IR/RuntimeLibcalls.td index ce6a3d4e90ef0..6805f2871c557 100644 --- a/llvm/include/llvm/IR/RuntimeLibcalls.td +++ b/llvm/include/llvm/IR/RuntimeLibcalls.td @@ -219,44 +219,55 @@ def ExceptionModelIsSjLj // Declare all kinds of used libcalls //-------------------------------------------------------------------- +class TypeSuffix<string S, FuncArgType Ty> { + string Suffix = S; + FuncArgType Type = Ty; +} + // Integer -foreach IntTy = ["I16", "I32", "I64", "I128"] in { - def SHL_#IntTy : RuntimeLibcall; - def SRL_#IntTy : RuntimeLibcall; - def SRA_#IntTy : RuntimeLibcall; +foreach IntTy = [TypeSuffix<"I16", Int16>, TypeSuffix<"I32", Int32>, + TypeSuffix<"I64", Int64>, TypeSuffix<"I128", Int128>] in { + def SHL_#IntTy.Suffix : RuntimeLibcall<IntTy.Type, [IntTy.Type, Int]>; + def SRL_#IntTy.Suffix : RuntimeLibcall<IntTy.Type, [IntTy.Type, Int]>; + def SRA_#IntTy.Suffix : RuntimeLibcall<IntTy.Type, [IntTy.Type, Int]>; } -foreach IntTy = ["I8", "I16", "I32", "I64", "I128"] in { - def MUL_#IntTy : RuntimeLibcall; +foreach IntTy = [TypeSuffix<"I8", Int8>, TypeSuffix<"I16", Int16>, + TypeSuffix<"I32", Int32>, TypeSuffix<"I64", Int64>, + TypeSuffix<"I128", Int128>] in { + def MUL_#IntTy.Suffix : RuntimeLibcall<IntTy.Type, [IntTy.Type, IntTy.Type]>; + def SDIV_#IntTy.Suffix : RuntimeLibcall<IntTy.Type, [IntTy.Type, IntTy.Type]>; + def SREM_#IntTy.Suffix : RuntimeLibcall<IntTy.Type, [IntTy.Type, IntTy.Type]>; } -foreach IntTy = ["I32", "I64", "I128" ] in { - def MULO_#IntTy : RuntimeLibcall; +foreach IntTy = [TypeSuffix<"I8", UInt8>, TypeSuffix<"I16", UInt16>, + TypeSuffix<"I32", UInt32>, TypeSuffix<"I64", UInt64>, + TypeSuffix<"I128", UInt128>] in { + def UDIV_#IntTy.Suffix : RuntimeLibcall<IntTy.Type, [IntTy.Type, IntTy.Type]>; + def UREM_#IntTy.Suffix : RuntimeLibcall<IntTy.Type, [IntTy.Type, IntTy.Type]>; +} + +foreach IntTy = [TypeSuffix<"I32", Int32>, TypeSuffix<"I64", Int64>, + TypeSuffix<"I128", Int128>] in { + def MULO_#IntTy.Suffix + : RuntimeLibcall<IntTy.Type, [IntTy.Type, IntTy.Type, Ptr]>; } foreach IntTy = ["I8", "I16", "I32", "I64", "I128"] in { - def SDIV_#IntTy : RuntimeLibcall; - def UDIV_#IntTy : RuntimeLibcall; - def SREM_#IntTy : RuntimeLibcall; - def UREM_#IntTy : RuntimeLibcall; def SDIVREM_#IntTy : RuntimeLibcall; def UDIVREM_#IntTy : RuntimeLibcall; } -foreach IntTy = ["I32", "I64" ] in { - def NEG_#IntTy : RuntimeLibcall; +foreach IntTy = [TypeSuffix<"I32", Int32>, TypeSuffix<"I64", Int64>] in { + def NEG_#IntTy.Suffix : RuntimeLibcall<IntTy.Type, [IntTy.Type]>; } -foreach IntTy = ["I32", "I64", "I128"] in { - def CTLZ_#IntTy : RuntimeLibcall; - def CTPOP_#IntTy : RuntimeLibcall; +foreach IntTy = [TypeSuffix<"I32", Int32>, TypeSuffix<"I64", Int64>, + TypeSuffix<"I128", Int128>] in { + def CTLZ_#IntTy.Suffix : RuntimeLibcall<Int, [IntTy.Type]>; + def CTPOP_#IntTy.Suffix : RuntimeLibcall<Int, [IntTy.Type]>; } - -class TypeSuffix<string S, FuncArgType Ty> { - string Suffix = S; - FuncArgType Type = Ty; -} def F32 : TypeSuffix<"F32", Flt>; def F64 : TypeSuffix<"F64", Dbl>; def F80 : TypeSuffix<"F80", X86FP80>; @@ -337,10 +348,10 @@ foreach FPTy = [F32, F64, F80, F128, PPCF128] in { : RuntimeLibcall<FPTy.Type, [FPTy.Type, FPTy.Type]>; def FMAXIMUM_NUM_#FPTy.Suffix : RuntimeLibcall<FPTy.Type, [FPTy.Type, FPTy.Type]>; - def LROUND_#FPTy.Suffix : RuntimeLibcall; - def LLROUND_#FPTy.Suffix : RuntimeLibcall; - def LRINT_#FPTy.Suffix : RuntimeLibcall; - def LLRINT_#FPTy.Suffix : RuntimeLibcall; + def LROUND_#FPTy.Suffix : RuntimeLibcall<Long, [FPTy.Type]>; + def LLROUND_#FPTy.Suffix : RuntimeLibcall<LLong, [FPTy.Type]>; + def LRINT_#FPTy.Suffix : RuntimeLibcall<Long, [FPTy.Type]>; + def LLRINT_#FPTy.Suffix : RuntimeLibcall<LLong, [FPTy.Type]>; def LDEXP_#FPTy.Suffix : RuntimeLibcall<FPTy.Type, [FPTy.Type, Int]>; def FREXP_#FPTy.Suffix : RuntimeLibcall<FPTy.Type, [FPTy.Type, Ptr]>; def SINCOSPI_#FPTy.Suffix : RuntimeLibcall<Void, [FPTy.Type, Ptr, Ptr]>; @@ -480,11 +491,11 @@ foreach S = !listconcat(F32VectorSuffixes, F64VectorSuffixes) in { defm ROUND : VectorMathLibcall<S, VT, [VT]>; } -def FEGETENV : RuntimeLibcall; -def FESETENV : RuntimeLibcall; +def FEGETENV : RuntimeLibcall<Int, [Ptr]>; +def FESETENV : RuntimeLibcall<Int, [Ptr]>; -def FEGETMODE : RuntimeLibcall; -def FESETMODE : RuntimeLibcall; +def FEGETMODE : RuntimeLibcall<Int, [Ptr]>; +def FESETMODE : RuntimeLibcall<Int, [Ptr]>; def FPEXT_BF16_F32 : RuntimeLibcall; def FPEXT_F32_PPCF128 : RuntimeLibcall<PPCFP128, [Flt]>; @@ -519,37 +530,37 @@ def FPTOSINT_F16_I64 : RuntimeLibcall; def FPTOSINT_F16_I128 : RuntimeLibcall; def FPTOSINT_F32_I32 : RuntimeLibcall<Int32, [Flt]>; def FPTOSINT_F32_I64 : RuntimeLibcall<Int64, [Flt]>; -def FPTOSINT_F32_I128 : RuntimeLibcall; +def FPTOSINT_F32_I128 : RuntimeLibcall<Int128, [Flt]>; def FPTOSINT_F64_I32 : RuntimeLibcall<Int32, [Dbl]>; def FPTOSINT_F64_I64 : RuntimeLibcall<Int64, [Dbl]>; -def FPTOSINT_F64_I128 : RuntimeLibcall; +def FPTOSINT_F64_I128 : RuntimeLibcall<Int128, [Dbl]>; def FPTOSINT_F80_I32 : RuntimeLibcall<Int32, [X86FP80]>; def FPTOSINT_F80_I64 : RuntimeLibcall<Int64, [X86FP80]>; -def FPTOSINT_F80_I128 : RuntimeLibcall; +def FPTOSINT_F80_I128 : RuntimeLibcall<Int128, [X86FP80]>; def FPTOSINT_F128_I32 : RuntimeLibcall<Int32, [FP128]>; def FPTOSINT_F128_I64 : RuntimeLibcall<Int64, [FP128]>; -def FPTOSINT_F128_I128 : RuntimeLibcall; +def FPTOSINT_F128_I128 : RuntimeLibcall<Int128, [FP128]>; def FPTOSINT_PPCF128_I32 : RuntimeLibcall<Int32, [PPCFP128]>; def FPTOSINT_PPCF128_I64 : RuntimeLibcall<Int64, [PPCFP128]>; -def FPTOSINT_PPCF128_I128 : RuntimeLibcall; +def FPTOSINT_PPCF128_I128 : RuntimeLibcall<Int128, [PPCFP128]>; def FPTOUINT_F16_I32 : RuntimeLibcall; def FPTOUINT_F16_I64 : RuntimeLibcall; def FPTOUINT_F16_I128 : RuntimeLibcall; def FPTOUINT_F32_I32 : RuntimeLibcall<UInt32, [Flt]>; def FPTOUINT_F32_I64 : RuntimeLibcall<UInt64, [Flt]>; -def FPTOUINT_F32_I128 : RuntimeLibcall; +def FPTOUINT_F32_I128 : RuntimeLibcall<UInt128, [Flt]>; def FPTOUINT_F64_I32 : RuntimeLibcall<UInt32, [Dbl]>; def FPTOUINT_F64_I64 : RuntimeLibcall<UInt64, [Dbl]>; -def FPTOUINT_F64_I128 : RuntimeLibcall; +def FPTOUINT_F64_I128 : RuntimeLibcall<UInt128, [Dbl]>; def FPTOUINT_F80_I32 : RuntimeLibcall<UInt32, [X86FP80]>; def FPTOUINT_F80_I64 : RuntimeLibcall<UInt64, [X86FP80]>; -def FPTOUINT_F80_I128 : RuntimeLibcall; +def FPTOUINT_F80_I128 : RuntimeLibcall<UInt128, [X86FP80]>; def FPTOUINT_F128_I32 : RuntimeLibcall<UInt32, [FP128]>; def FPTOUINT_F128_I64 : RuntimeLibcall<UInt64, [FP128]>; -def FPTOUINT_F128_I128 : RuntimeLibcall; +def FPTOUINT_F128_I128 : RuntimeLibcall<UInt128, [FP128]>; def FPTOUINT_PPCF128_I32 : RuntimeLibcall<UInt32, [PPCFP128]>; def FPTOUINT_PPCF128_I64 : RuntimeLibcall<UInt64, [PPCFP128]>; -def FPTOUINT_PPCF128_I128 : RuntimeLibcall; +def FPTOUINT_PPCF128_I128 : RuntimeLibcall<UInt128, [PPCFP128]>; def SINTTOFP_I32_F16 : RuntimeLibcall; def SINTTOFP_I32_F32 : RuntimeLibcall<Flt, [Int32]>; def SINTTOFP_I32_F64 : RuntimeLibcall<Dbl, [Int32]>; @@ -564,11 +575,11 @@ def SINTTOFP_I64_F80 : RuntimeLibcall<X86FP80, [Int64]>; def SINTTOFP_I64_F128 : RuntimeLibcall<FP128, [Int64]>; def SINTTOFP_I64_PPCF128 : RuntimeLibcall<PPCFP128, [Int64]>; def SINTTOFP_I128_F16 : RuntimeLibcall; -def SINTTOFP_I128_F32 : RuntimeLibcall; -def SINTTOFP_I128_F64 : RuntimeLibcall; -def SINTTOFP_I128_F80 : RuntimeLibcall; -def SINTTOFP_I128_F128 : RuntimeLibcall; -def SINTTOFP_I128_PPCF128 : RuntimeLibcall; +def SINTTOFP_I128_F32 : RuntimeLibcall<Flt, [Int128]>; +def SINTTOFP_I128_F64 : RuntimeLibcall<Dbl, [Int128]>; +def SINTTOFP_I128_F80 : RuntimeLibcall<X86FP80, [Int128]>; +def SINTTOFP_I128_F128 : RuntimeLibcall<FP128, [Int128]>; +def SINTTOFP_I128_PPCF128 : RuntimeLibcall<PPCFP128, [Int128]>; def UINTTOFP_I32_F16 : RuntimeLibcall; def UINTTOFP_I32_F32 : RuntimeLibcall<Flt, [UInt32]>; def UINTTOFP_I32_F64 : RuntimeLibcall<Dbl, [UInt32]>; @@ -583,13 +594,13 @@ def UINTTOFP_I64_F80 : RuntimeLibcall<X86FP80, [UInt64]>; def UINTTOFP_I64_F128 : RuntimeLibcall<FP128, [UInt64]>; def UINTTOFP_I64_PPCF128 : RuntimeLibcall<PPCFP128, [UInt64]>; def UINTTOFP_I128_F16 : RuntimeLibcall; -def UINTTOFP_I128_F32 : RuntimeLibcall; -def UINTTOFP_I128_F64 : RuntimeLibcall; -def UINTTOFP_I128_F80 : RuntimeLibcall; -def UINTTOFP_I128_F128 : RuntimeLibcall; -def UINTTOFP_I128_PPCF128 : RuntimeLibcall; -def CONVERT_F128_PPCF128 : RuntimeLibcall; -def CONVERT_PPCF128_F128 : RuntimeLibcall; +def UINTTOFP_I128_F32 : RuntimeLibcall<Flt, [UInt128]>; +def UINTTOFP_I128_F64 : RuntimeLibcall<Dbl, [UInt128]>; +def UINTTOFP_I128_F80 : RuntimeLibcall<X86FP80, [UInt128]>; +def UINTTOFP_I128_F128 : RuntimeLibcall<FP128, [UInt128]>; +def UINTTOFP_I128_PPCF128 : RuntimeLibcall<PPCFP128, [UInt128]>; +def CONVERT_F128_PPCF128 : RuntimeLibcall<PPCFP128, [FP128]>; +def CONVERT_PPCF128_F128 : RuntimeLibcall<FP128, [PPCFP128]>; // Comparisons. // @@ -633,17 +644,20 @@ def STRLEN : RuntimeLibcall<SizeT, [Ptr]>; // Element-wise unordered-atomic memory of different sizes foreach MemSize = [1, 2, 4, 8, 16] in { - def MEMCPY_ELEMENT_UNORDERED_ATOMIC_#MemSize : RuntimeLibcall; - def MEMMOVE_ELEMENT_UNORDERED_ATOMIC_#MemSize : RuntimeLibcall; - def MEMSET_ELEMENT_UNORDERED_ATOMIC_#MemSize : RuntimeLibcall; + def MEMCPY_ELEMENT_UNORDERED_ATOMIC_#MemSize + : RuntimeLibcall<Void, [Ptr, Ptr, SizeT]>; + def MEMMOVE_ELEMENT_UNORDERED_ATOMIC_#MemSize + : RuntimeLibcall<Void, [Ptr, Ptr, SizeT]>; + def MEMSET_ELEMENT_UNORDERED_ATOMIC_#MemSize + : RuntimeLibcall<Void, [Ptr, Int, SizeT]>; } // Exception handling -def UNWIND_RESUME : RuntimeLibcall; -def UNWIND_REGISTER : RuntimeLibcall; -def UNWIND_UNREGISTER : RuntimeLibcall; -def UNWIND_GET_WASM_LPAD_CONTEXT : RuntimeLibcall; -def CXA_END_CLEANUP : RuntimeLibcall; +def UNWIND_RESUME : RuntimeLibcall<Void, [Ptr]>; +def UNWIND_REGISTER : RuntimeLibcall<Void, [Ptr]>; +def UNWIND_UNREGISTER : RuntimeLibcall<Void, [Ptr]>; +def UNWIND_GET_WASM_LPAD_CONTEXT : RuntimeLibcall<Ptr, []>; +def CXA_END_CLEANUP : RuntimeLibcall<Void, []>; // Note: there are two sets of atomics libcalls; see // <https://llvm.org/docs/Atomics.html> for more info on the @@ -759,31 +773,31 @@ defset list<RuntimeLibcall> LibCalls__OutOfLineAtomic = { } // Stack Protector Fail -def STACKPROTECTOR_CHECK_FAIL : RuntimeLibcall; +def STACKPROTECTOR_CHECK_FAIL : RuntimeLibcall<Void, []>; def STACK_SMASH_HANDLER : RuntimeLibcall; // Safe stack -def SAFESTACK_POINTER_ADDRESS : RuntimeLibcall; +def SAFESTACK_POINTER_ADDRESS : RuntimeLibcall<Ptr, []>; // Really a global variable, not a function def SAFESTACK_UNSAFE_STACK_PTR : RuntimeLibcall; def STACK_PROBE : RuntimeLibcall; -def SECURITY_CHECK_COOKIE : RuntimeLibcall; +def SECURITY_CHECK_COOKIE : RuntimeLibcall<Void, [Ptr]>; // Deoptimization def DEOPTIMIZE : RuntimeLibcall; // Return address -def RETURN_ADDRESS : RuntimeLibcall; +def RETURN_ADDRESS : RuntimeLibcall<Ptr, [Int]>; // GPU profiling def PROFILE_INSTRUMENT_GPU : RuntimeLibcall; def PROFILE_SAMPLING_GPU : RuntimeLibcall; // Clear cache -def CLEAR_CACHE : RuntimeLibcall; -def RISCV_FLUSH_ICACHE : RuntimeLibcall; +def CLEAR_CACHE : RuntimeLibcall<Void, [Ptr, Ptr]>; +def RISCV_FLUSH_ICACHE : RuntimeLibcall<Int, [Ptr, Ptr, ULong]>; // Mips16 calls def MIPS16_RET_DC : RuntimeLibcall; @@ -808,10 +822,10 @@ multiclass LibmLibcallImpls<string libcall_basename = !toupper(NAME), } // AArch64 calls -def SC_MEMCPY : RuntimeLibcall; -def SC_MEMMOVE : RuntimeLibcall; -def SC_MEMSET : RuntimeLibcall; -def SC_MEMCHR: RuntimeLibcall; +def SC_MEMCPY : RuntimeLibcall<Ptr, [Ptr, Ptr, SizeT]>; +def SC_MEMMOVE : RuntimeLibcall<Ptr, [Ptr, Ptr, SizeT]>; +def SC_MEMSET : RuntimeLibcall<Ptr, [Ptr, Int, SizeT]>; +def SC_MEMCHR : RuntimeLibcall<Ptr, [Ptr, Int, SizeT]>; // AArch64 SME ABI calls def SMEABI_SME_STATE : RuntimeLibcall; @@ -824,19 +838,19 @@ def SMEABI_SME_SAVE : RuntimeLibcall; def SMEABI_SME_RESTORE : RuntimeLibcall; // ARM EABI calls -def AEABI_MEMCPY4 : RuntimeLibcall; // Align 4 -def AEABI_MEMCPY8 : RuntimeLibcall; // Align 8 -def AEABI_MEMMOVE4 : RuntimeLibcall; -def AEABI_MEMMOVE8 : RuntimeLibcall; -def AEABI_MEMSET4 : RuntimeLibcall; -def AEABI_MEMSET8 : RuntimeLibcall; -def AEABI_MEMCLR : RuntimeLibcall; -def AEABI_MEMCLR4 : RuntimeLibcall; -def AEABI_MEMCLR8 : RuntimeLibcall; -def AEABI_UREAD4 : RuntimeLibcall; -def AEABI_UREAD8 : RuntimeLibcall; -def AEABI_UWRITE4 : RuntimeLibcall; -def AEABI_UWRITE8 : RuntimeLibcall; +def AEABI_MEMCPY4 : RuntimeLibcall<Void, [Ptr, Ptr, SizeT]>; // Align 4 +def AEABI_MEMCPY8 : RuntimeLibcall<Void, [Ptr, Ptr, SizeT]>; // Align 8 +def AEABI_MEMMOVE4 : RuntimeLibcall<Void, [Ptr, Ptr, SizeT]>; +def AEABI_MEMMOVE8 : RuntimeLibcall<Void, [Ptr, Ptr, SizeT]>; +def AEABI_MEMSET4 : RuntimeLibcall<Void, [Ptr, SizeT, Int]>; +def AEABI_MEMSET8 : RuntimeLibcall<Void, [Ptr, SizeT, Int]>; +def AEABI_MEMCLR : RuntimeLibcall<Void, [Ptr, SizeT]>; +def AEABI_MEMCLR4 : RuntimeLibcall<Void, [Ptr, SizeT]>; +def AEABI_MEMCLR8 : RuntimeLibcall<Void, [Ptr, SizeT]>; +def AEABI_UREAD4 : RuntimeLibcall<Int, [Ptr]>; +def AEABI_UREAD8 : RuntimeLibcall<LLong, [Ptr]>; +def AEABI_UWRITE4 : RuntimeLibcall<Int, [Int, Ptr]>; +def AEABI_UWRITE8 : RuntimeLibcall<LLong, [LLong, Ptr]>; // Hexagon calls def HEXAGON_MEMCPY_LIKELY_ALIGNED_MIN32BYTES_MULT8BYTES : RuntimeLibcall; @@ -846,32 +860,32 @@ def HEXAGON_VOLATILE_MEMCPY : RuntimeLibcall; def MEMCPY_ALIGN_4 : RuntimeLibcall; // Objective-C calls -def OBJC_AUTORELEASE : RuntimeLibcall; -def OBJC_AUTORELEASEPOOLPOP : RuntimeLibcall; -def OBJC_AUTORELEASEPOOLPUSH : RuntimeLibcall; -def OBJC_AUTORELEASERETURNVALUE : RuntimeLibcall; -def OBJC_COPYWEAK : RuntimeLibcall; -def OBJC_DESTROYWEAK : RuntimeLibcall; -def OBJC_INITWEAK : RuntimeLibcall; -def OBJC_LOADWEAK : RuntimeLibcall; -def OBJC_LOADWEAKRETAINED : RuntimeLibcall; -def OBJC_MOVEWEAK : RuntimeLibcall; -def OBJC_RELEASE : RuntimeLibcall; -def OBJC_RETAIN : RuntimeLibcall; -def OBJC_RETAINAUTORELEASE : RuntimeLibcall; -def OBJC_RETAINAUTORELEASERETURNVALUE : RuntimeLibcall; -def OBJC_RETAINAUTORELEASEDRETURNVALUE : RuntimeLibcall; -def OBJC_CLAIMAUTORELEASEDRETURNVALUE : RuntimeLibcall; -def OBJC_RETAINBLOCK : RuntimeLibcall; -def OBJC_STORESTRONG : RuntimeLibcall; -def OBJC_STOREWEAK : RuntimeLibcall; -def OBJC_UNSAFECLAIMAUTORELEASEDRETURNVALUE : RuntimeLibcall; -def OBJC_RETAINEDOBJECT : RuntimeLibcall; -def OBJC_UNRETAINEDOBJECT : RuntimeLibcall; -def OBJC_UNRETAINEDPOINTER : RuntimeLibcall; -def OBJC_RETAIN_AUTORELEASE : RuntimeLibcall; -def OBJC_SYNC_ENTER : RuntimeLibcall; -def OBJC_SYNC_EXIT : RuntimeLibcall; +def OBJC_AUTORELEASE : RuntimeLibcall<Ptr, [Ptr]>; +def OBJC_AUTORELEASEPOOLPOP : RuntimeLibcall<Void, [Ptr]>; +def OBJC_AUTORELEASEPOOLPUSH : RuntimeLibcall<Ptr, []>; +def OBJC_AUTORELEASERETURNVALUE : RuntimeLibcall<Ptr, [Ptr]>; +def OBJC_COPYWEAK : RuntimeLibcall<Void, [Ptr, Ptr]>; +def OBJC_DESTROYWEAK : RuntimeLibcall<Void, [Ptr]>; +def OBJC_INITWEAK : RuntimeLibcall<Ptr, [Ptr, Ptr]>; +def OBJC_LOADWEAK : RuntimeLibcall<Ptr, [Ptr]>; +def OBJC_LOADWEAKRETAINED : RuntimeLibcall<Ptr, [Ptr]>; +def OBJC_MOVEWEAK : RuntimeLibcall<Void, [Ptr, Ptr]>; +def OBJC_RELEASE : RuntimeLibcall<Void, [Ptr]>; +def OBJC_RETAIN : RuntimeLibcall<Ptr, [Ptr]>; +def OBJC_RETAINAUTORELEASE : RuntimeLibcall<Ptr, [Ptr]>; +def OBJC_RETAINAUTORELEASERETURNVALUE : RuntimeLibcall<Ptr, [Ptr]>; +def OBJC_RETAINAUTORELEASEDRETURNVALUE : RuntimeLibcall<Ptr, [Ptr]>; +def OBJC_CLAIMAUTORELEASEDRETURNVALUE : RuntimeLibcall<Ptr, [Ptr]>; +def OBJC_RETAINBLOCK : RuntimeLibcall<Ptr, [Ptr]>; +def OBJC_STORESTRONG : RuntimeLibcall<Void, [Ptr, Ptr]>; +def OBJC_STOREWEAK : RuntimeLibcall<Ptr, [Ptr, Ptr]>; +def OBJC_UNSAFECLAIMAUTORELEASEDRETURNVALUE : RuntimeLibcall<Ptr, [Ptr]>; +def OBJC_RETAINEDOBJECT : RuntimeLibcall<Ptr, [Ptr]>; +def OBJC_UNRETAINEDOBJECT : RuntimeLibcall<Ptr, [Ptr]>; +def OBJC_UNRETAINEDPOINTER : RuntimeLibcall<Ptr, [Ptr]>; +def OBJC_RETAIN_AUTORELEASE : RuntimeLibcall<Ptr, [Ptr]>; +def OBJC_SYNC_ENTER : RuntimeLibcall<Int, [Ptr]>; +def OBJC_SYNC_EXIT : RuntimeLibcall<Int, [Ptr]>; def ABORT : RuntimeLibcall<Void, []>; def ABS : RuntimeLibcall<Int, [Int]>; diff --git a/llvm/test/Transforms/Util/DeclareRuntimeLibcalls/aarch64.ll b/llvm/test/Transforms/Util/DeclareRuntimeLibcalls/aarch64.ll index a364011b48751..1fbf9c241769f 100644 --- a/llvm/test/Transforms/Util/DeclareRuntimeLibcalls/aarch64.ll +++ b/llvm/test/Transforms/Util/DeclareRuntimeLibcalls/aarch64.ll @@ -8,7 +8,7 @@ ; RUN: opt -S -passes=declare-runtime-libcalls -mtriple=aarch64-w64-windows-gnu < %s | sed '/^$/d;/^; Function Attrs:/d' | FileCheck -check-prefix=MINGW %s ; RUN: opt -S -passes=declare-runtime-libcalls -mtriple=aarch64-unknown-linux-android < %s | sed '/^$/d;/^; Function Attrs:/d' | FileCheck -check-prefix=ANDROID %s -; LINUX: declare void @_Unwind_Resume(...) +; LINUX: declare void @_Unwind_Resume(ptr) ; LINUX-NEXT: declare i128 @__aarch64_cas16_acq(i128, i128, ptr) ; LINUX-NEXT: declare i128 @__aarch64_cas16_acq_rel(i128, i128, ptr) ; LINUX-NEXT: declare i128 @__aarch64_cas16_rel(i128, i128, ptr) @@ -113,10 +113,10 @@ ; LINUX-NEXT: declare float @__addsf3(float, float) ; LINUX-NEXT: declare fp128 @__addtf3(fp128, fp128) ; LINUX-NEXT: declare aarch64_sme_preservemost_from_x1 void @__arm_get_current_vg(...) -; LINUX-NEXT: declare void @__arm_sc_memchr(...) -; LINUX-NEXT: declare void @__arm_sc_memcpy(...) -; LINUX-NEXT: declare void @__arm_sc_memmove(...) -; LINUX-NEXT: declare void @__arm_sc_memset(...) +; LINUX-NEXT: declare ptr @__arm_sc_memchr(ptr, i32, i64) +; LINUX-NEXT: declare ptr @__arm_sc_memcpy(ptr, ptr, i64) +; LINUX-NEXT: declare ptr @__arm_sc_memmove(ptr, ptr, i64) +; LINUX-NEXT: declare ptr @__arm_sc_memset(ptr, i32, i64) ; LINUX-NEXT: declare aarch64_sme_preservemost_from_x1 void @__arm_sme_restore(...) ; LINUX-NEXT: declare aarch64_sme_preservemost_from_x1 void @__arm_sme_save(...) ; LINUX-NEXT: declare aarch64_sme_preservemost_from_x2 void @__arm_sme_state(...) @@ -124,14 +124,14 @@ ; LINUX-NEXT: declare aarch64_sme_preservemost_from_x0 void @__arm_tpidr2_restore(...) ; LINUX-NEXT: declare aarch64_sme_preservemost_from_x0 void @__arm_tpidr2_save(...) ; LINUX-NEXT: declare aarch64_sme_preservemost_from_x0 void @__arm_za_disable(...) -; LINUX-NEXT: declare void @__ashldi3(...) -; LINUX-NEXT: declare void @__ashlhi3(...) -; LINUX-NEXT: declare void @__ashlsi3(...) -; LINUX-NEXT: declare void @__ashlti3(...) -; LINUX-NEXT: declare void @__ashrdi3(...) -; LINUX-NEXT: declare void @__ashrhi3(...) -; LINUX-NEXT: declare void @__ashrsi3(...) -; LINUX-NEXT: declare void @__ashrti3(...) +; LINUX-NEXT: declare i64 @__ashldi3(i64, i32) +; LINUX-NEXT: declare signext i16 @__ashlhi3(i16 signext, i32) +; LINUX-NEXT: declare i32 @__ashlsi3(i32, i32) +; LINUX-NEXT: declare i128 @__ashlti3(i128, i32) +; LINUX-NEXT: declare i64 @__ashrdi3(i64, i32) +; LINUX-NEXT: declare signext i16 @__ashrhi3(i16 signext, i32) +; LINUX-NEXT: declare i32 @__ashrsi3(i32, i32) +; LINUX-NEXT: declare i128 @__ashrti3(i128, i32) ; LINUX-NEXT: declare zeroext i1 @__atomic_compare_exchange(i64, ptr, ptr, ptr, i32, i32) ; LINUX-NEXT: declare zeroext i1 @__atomic_compare_exchange_1(ptr, ptr, i8 zeroext, i32, i32) ; LINUX-NEXT: declare zeroext i1 @__atomic_compare_exchange_16(ptr, ptr, i128, i32, i32) @@ -186,19 +186,19 @@ ; LINUX-NEXT: declare void @__atomic_store_2(ptr, i16 zeroext, i32) ; LINUX-NEXT: declare void @__atomic_store_4(ptr, i32, i32) ; LINUX-NEXT: declare void @__atomic_store_8(ptr, i64, i32) -; LINUX-NEXT: declare void @__clear_cache(...) -; LINUX-NEXT: declare void @__clzdi2(...) -; LINUX-NEXT: declare void @__clzsi2(...) -; LINUX-NEXT: declare void @__clzti2(...) -; LINUX-NEXT: declare void @__cxa_end_cleanup(...) +; LINUX-NEXT: declare void @__clear_cache(ptr, ptr) +; LINUX-NEXT: declare i32 @__clzdi2(i64) +; LINUX-NEXT: declare i32 @__clzsi2(i32) +; LINUX-NEXT: declare i32 @__clzti2(i128) +; LINUX-NEXT: declare void @__cxa_end_cleanup() ; LINUX-NEXT: declare double @__divdf3(double, double) -; LINUX-NEXT: declare void @__divdi3(...) -; LINUX-NEXT: ... [truncated] `````````` </details> https://github.com/llvm/llvm-project/pull/237483 _______________________________________________ llvm-branch-commits mailing list [email protected] https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-branch-commits
