1
0
mirror of https://github.com/RPCS3/llvm-mirror.git synced 2025-01-31 20:51:52 +01:00

[FunctionAttrs] Annotate "willreturn" for intrinsics

Summary:
In D62801, new function attribute `willreturn` was introduced. In short, a function with `willreturn` is guaranteed to come back to the call site(more precise definition is in LangRef).

In this patch, willreturn is annotated for LLVM intrinsics.

Reviewers: jdoerfert

Reviewed By: jdoerfert

Subscribers: jvesely, nhaehnle, sstefan1, llvm-commits

Tags: #llvm

Differential Revision: https://reviews.llvm.org/D64904

llvm-svn: 367184
This commit is contained in:
Hideto Ueno 2019-07-28 06:09:56 +00:00
parent f05799cd65
commit 97957b2f53
27 changed files with 207 additions and 215 deletions

View File

@ -452,7 +452,7 @@ def int_thread_pointer : Intrinsic<[llvm_ptr_ty], [], [IntrNoMem]>,
// memory while not impeding optimization. // memory while not impeding optimization.
def int_prefetch def int_prefetch
: Intrinsic<[], [ llvm_anyptr_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty ], : Intrinsic<[], [ llvm_anyptr_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty ],
[ IntrInaccessibleMemOrArgMemOnly, ReadOnly<0>, NoCapture<0>, [ IntrInaccessibleMemOrArgMemOnly, IntrWillReturn, ReadOnly<0>, NoCapture<0>,
ImmArg<1>, ImmArg<2>]>; ImmArg<1>, ImmArg<2>]>;
def int_pcmarker : Intrinsic<[], [llvm_i32_ty]>; def int_pcmarker : Intrinsic<[], [llvm_i32_ty]>;
@ -460,7 +460,7 @@ def int_readcyclecounter : Intrinsic<[llvm_i64_ty]>;
// The assume intrinsic is marked as arbitrarily writing so that proper // The assume intrinsic is marked as arbitrarily writing so that proper
// control dependencies will be maintained. // control dependencies will be maintained.
def int_assume : Intrinsic<[], [llvm_i1_ty], []>; def int_assume : Intrinsic<[], [llvm_i1_ty], [IntrWillReturn]>;
// Stack Protector Intrinsic - The stackprotector intrinsic writes the stack // Stack Protector Intrinsic - The stackprotector intrinsic writes the stack
// guard to the correct place on the stack frame. // guard to the correct place on the stack frame.
@ -493,23 +493,23 @@ def int_instrprof_value_profile : Intrinsic<[],
def int_memcpy : Intrinsic<[], def int_memcpy : Intrinsic<[],
[llvm_anyptr_ty, llvm_anyptr_ty, llvm_anyint_ty, [llvm_anyptr_ty, llvm_anyptr_ty, llvm_anyint_ty,
llvm_i1_ty], llvm_i1_ty],
[IntrArgMemOnly, NoCapture<0>, NoCapture<1>, [IntrArgMemOnly, IntrWillReturn, NoCapture<0>, NoCapture<1>,
WriteOnly<0>, ReadOnly<1>, ImmArg<3>]>; WriteOnly<0>, ReadOnly<1>, ImmArg<3>]>;
def int_memmove : Intrinsic<[], def int_memmove : Intrinsic<[],
[llvm_anyptr_ty, llvm_anyptr_ty, llvm_anyint_ty, [llvm_anyptr_ty, llvm_anyptr_ty, llvm_anyint_ty,
llvm_i1_ty], llvm_i1_ty],
[IntrArgMemOnly, NoCapture<0>, NoCapture<1>, [IntrArgMemOnly, IntrWillReturn, NoCapture<0>, NoCapture<1>,
ReadOnly<1>, ImmArg<3>]>; ReadOnly<1>, ImmArg<3>]>;
def int_memset : Intrinsic<[], def int_memset : Intrinsic<[],
[llvm_anyptr_ty, llvm_i8_ty, llvm_anyint_ty, [llvm_anyptr_ty, llvm_i8_ty, llvm_anyint_ty,
llvm_i1_ty], llvm_i1_ty],
[IntrArgMemOnly, NoCapture<0>, WriteOnly<0>, [IntrArgMemOnly, IntrWillReturn, NoCapture<0>, WriteOnly<0>,
ImmArg<3>]>; ImmArg<3>]>;
// FIXME: Add version of these floating point intrinsics which allow non-default // FIXME: Add version of these floating point intrinsics which allow non-default
// rounding modes and FP exception handling. // rounding modes and FP exception handling.
let IntrProperties = [IntrNoMem, IntrSpeculatable] in { let IntrProperties = [IntrNoMem, IntrSpeculatable, IntrWillReturn] in {
def int_fma : Intrinsic<[llvm_anyfloat_ty], def int_fma : Intrinsic<[llvm_anyfloat_ty],
[LLVMMatchType<0>, LLVMMatchType<0>, [LLVMMatchType<0>, LLVMMatchType<0>,
LLVMMatchType<0>]>; LLVMMatchType<0>]>;
@ -551,19 +551,19 @@ let IntrProperties = [IntrNoMem, IntrSpeculatable] in {
def int_minnum : Intrinsic<[llvm_anyfloat_ty], def int_minnum : Intrinsic<[llvm_anyfloat_ty],
[LLVMMatchType<0>, LLVMMatchType<0>], [LLVMMatchType<0>, LLVMMatchType<0>],
[IntrNoMem, IntrSpeculatable, Commutative] [IntrNoMem, IntrSpeculatable, IntrWillReturn, Commutative]
>; >;
def int_maxnum : Intrinsic<[llvm_anyfloat_ty], def int_maxnum : Intrinsic<[llvm_anyfloat_ty],
[LLVMMatchType<0>, LLVMMatchType<0>], [LLVMMatchType<0>, LLVMMatchType<0>],
[IntrNoMem, IntrSpeculatable, Commutative] [IntrNoMem, IntrSpeculatable, IntrWillReturn, Commutative]
>; >;
def int_minimum : Intrinsic<[llvm_anyfloat_ty], def int_minimum : Intrinsic<[llvm_anyfloat_ty],
[LLVMMatchType<0>, LLVMMatchType<0>], [LLVMMatchType<0>, LLVMMatchType<0>],
[IntrNoMem, IntrSpeculatable, Commutative] [IntrNoMem, IntrSpeculatable, IntrWillReturn, Commutative]
>; >;
def int_maximum : Intrinsic<[llvm_anyfloat_ty], def int_maximum : Intrinsic<[llvm_anyfloat_ty],
[LLVMMatchType<0>, LLVMMatchType<0>], [LLVMMatchType<0>, LLVMMatchType<0>],
[IntrNoMem, IntrSpeculatable, Commutative] [IntrNoMem, IntrSpeculatable, IntrWillReturn, Commutative]
>; >;
// NOTE: these are internal interfaces. // NOTE: these are internal interfaces.
@ -582,7 +582,7 @@ def int_objectsize : Intrinsic<[llvm_anyint_ty],
//===--------------- Constrained Floating Point Intrinsics ----------------===// //===--------------- Constrained Floating Point Intrinsics ----------------===//
// //
let IntrProperties = [IntrInaccessibleMemOnly] in { let IntrProperties = [IntrInaccessibleMemOnly, IntrWillReturn] in {
def int_experimental_constrained_fadd : Intrinsic<[ llvm_anyfloat_ty ], def int_experimental_constrained_fadd : Intrinsic<[ llvm_anyfloat_ty ],
[ LLVMMatchType<0>, [ LLVMMatchType<0>,
LLVMMatchType<0>, LLVMMatchType<0>,
@ -711,13 +711,13 @@ let IntrProperties = [IntrInaccessibleMemOnly] in {
//===------------------------- Expect Intrinsics --------------------------===// //===------------------------- Expect Intrinsics --------------------------===//
// //
def int_expect : Intrinsic<[llvm_anyint_ty], def int_expect : Intrinsic<[llvm_anyint_ty],
[LLVMMatchType<0>, LLVMMatchType<0>], [IntrNoMem]>; [LLVMMatchType<0>, LLVMMatchType<0>], [IntrNoMem, IntrWillReturn]>;
//===-------------------- Bit Manipulation Intrinsics ---------------------===// //===-------------------- Bit Manipulation Intrinsics ---------------------===//
// //
// None of these intrinsics accesses memory at all. // None of these intrinsics accesses memory at all.
let IntrProperties = [IntrNoMem, IntrSpeculatable] in { let IntrProperties = [IntrNoMem, IntrSpeculatable, IntrWillReturn] in {
def int_bswap: Intrinsic<[llvm_anyint_ty], [LLVMMatchType<0>]>; def int_bswap: Intrinsic<[llvm_anyint_ty], [LLVMMatchType<0>]>;
def int_ctpop: Intrinsic<[llvm_anyint_ty], [LLVMMatchType<0>]>; def int_ctpop: Intrinsic<[llvm_anyint_ty], [LLVMMatchType<0>]>;
def int_bitreverse : Intrinsic<[llvm_anyint_ty], [LLVMMatchType<0>]>; def int_bitreverse : Intrinsic<[llvm_anyint_ty], [LLVMMatchType<0>]>;
@ -727,7 +727,7 @@ let IntrProperties = [IntrNoMem, IntrSpeculatable] in {
[LLVMMatchType<0>, LLVMMatchType<0>, LLVMMatchType<0>]>; [LLVMMatchType<0>, LLVMMatchType<0>, LLVMMatchType<0>]>;
} }
let IntrProperties = [IntrNoMem, IntrSpeculatable, ImmArg<1>] in { let IntrProperties = [IntrNoMem, IntrSpeculatable, IntrWillReturn, ImmArg<1>] in {
def int_ctlz : Intrinsic<[llvm_anyint_ty], [LLVMMatchType<0>, llvm_i1_ty]>; def int_ctlz : Intrinsic<[llvm_anyint_ty], [LLVMMatchType<0>, llvm_i1_ty]>;
def int_cttz : Intrinsic<[llvm_anyint_ty], [LLVMMatchType<0>, llvm_i1_ty]>; def int_cttz : Intrinsic<[llvm_anyint_ty], [LLVMMatchType<0>, llvm_i1_ty]>;
} }
@ -739,7 +739,7 @@ let IntrProperties = [IntrNoMem, IntrSpeculatable, ImmArg<1>] in {
// mean the optimizers can change them aggressively. Special handling // mean the optimizers can change them aggressively. Special handling
// needed in a few places. These synthetic intrinsics have no // needed in a few places. These synthetic intrinsics have no
// side-effects and just mark information about their operands. // side-effects and just mark information about their operands.
let IntrProperties = [IntrNoMem, IntrSpeculatable] in { let IntrProperties = [IntrNoMem, IntrSpeculatable, IntrWillReturn] in {
def int_dbg_declare : Intrinsic<[], def int_dbg_declare : Intrinsic<[],
[llvm_metadata_ty, [llvm_metadata_ty,
llvm_metadata_ty, llvm_metadata_ty,
@ -796,21 +796,21 @@ def int_eh_sjlj_setup_dispatch : Intrinsic<[], []>;
def int_var_annotation : Intrinsic<[], def int_var_annotation : Intrinsic<[],
[llvm_ptr_ty, llvm_ptr_ty, [llvm_ptr_ty, llvm_ptr_ty,
llvm_ptr_ty, llvm_i32_ty], llvm_ptr_ty, llvm_i32_ty],
[], "llvm.var.annotation">; [IntrWillReturn], "llvm.var.annotation">;
def int_ptr_annotation : Intrinsic<[LLVMAnyPointerType<llvm_anyint_ty>], def int_ptr_annotation : Intrinsic<[LLVMAnyPointerType<llvm_anyint_ty>],
[LLVMMatchType<0>, llvm_ptr_ty, llvm_ptr_ty, [LLVMMatchType<0>, llvm_ptr_ty, llvm_ptr_ty,
llvm_i32_ty], llvm_i32_ty],
[], "llvm.ptr.annotation">; [IntrWillReturn], "llvm.ptr.annotation">;
def int_annotation : Intrinsic<[llvm_anyint_ty], def int_annotation : Intrinsic<[llvm_anyint_ty],
[LLVMMatchType<0>, llvm_ptr_ty, [LLVMMatchType<0>, llvm_ptr_ty,
llvm_ptr_ty, llvm_i32_ty], llvm_ptr_ty, llvm_i32_ty],
[], "llvm.annotation">; [IntrWillReturn], "llvm.annotation">;
// Annotates the current program point with metadata strings which are emitted // Annotates the current program point with metadata strings which are emitted
// as CodeView debug info records. This is expensive, as it disables inlining // as CodeView debug info records. This is expensive, as it disables inlining
// and is modelled as having side effects. // and is modelled as having side effects.
def int_codeview_annotation : Intrinsic<[], [llvm_metadata_ty], def int_codeview_annotation : Intrinsic<[], [llvm_metadata_ty],
[IntrInaccessibleMemOnly, IntrNoDuplicate], [IntrInaccessibleMemOnly, IntrNoDuplicate, IntrWillReturn],
"llvm.codeview.annotation">; "llvm.codeview.annotation">;
//===------------------------ Trampoline Intrinsics -----------------------===// //===------------------------ Trampoline Intrinsics -----------------------===//
@ -828,79 +828,74 @@ def int_adjust_trampoline : Intrinsic<[llvm_ptr_ty], [llvm_ptr_ty],
// //
// Expose the carry flag from add operations on two integrals. // Expose the carry flag from add operations on two integrals.
def int_sadd_with_overflow : Intrinsic<[llvm_anyint_ty, let IntrProperties = [IntrNoMem, IntrSpeculatable, IntrWillReturn] in {
def int_sadd_with_overflow : Intrinsic<[llvm_anyint_ty,
LLVMScalarOrSameVectorWidth<0, llvm_i1_ty>], LLVMScalarOrSameVectorWidth<0, llvm_i1_ty>],
[LLVMMatchType<0>, LLVMMatchType<0>], [LLVMMatchType<0>, LLVMMatchType<0>]>;
[IntrNoMem, IntrSpeculatable]>; def int_uadd_with_overflow : Intrinsic<[llvm_anyint_ty,
def int_uadd_with_overflow : Intrinsic<[llvm_anyint_ty,
LLVMScalarOrSameVectorWidth<0, llvm_i1_ty>], LLVMScalarOrSameVectorWidth<0, llvm_i1_ty>],
[LLVMMatchType<0>, LLVMMatchType<0>], [LLVMMatchType<0>, LLVMMatchType<0>]>;
[IntrNoMem, IntrSpeculatable]>;
def int_ssub_with_overflow : Intrinsic<[llvm_anyint_ty, def int_ssub_with_overflow : Intrinsic<[llvm_anyint_ty,
LLVMScalarOrSameVectorWidth<0, llvm_i1_ty>], LLVMScalarOrSameVectorWidth<0, llvm_i1_ty>],
[LLVMMatchType<0>, LLVMMatchType<0>], [LLVMMatchType<0>, LLVMMatchType<0>]>;
[IntrNoMem, IntrSpeculatable]>; def int_usub_with_overflow : Intrinsic<[llvm_anyint_ty,
def int_usub_with_overflow : Intrinsic<[llvm_anyint_ty,
LLVMScalarOrSameVectorWidth<0, llvm_i1_ty>], LLVMScalarOrSameVectorWidth<0, llvm_i1_ty>],
[LLVMMatchType<0>, LLVMMatchType<0>], [LLVMMatchType<0>, LLVMMatchType<0>]>;
[IntrNoMem, IntrSpeculatable]>;
def int_smul_with_overflow : Intrinsic<[llvm_anyint_ty, def int_smul_with_overflow : Intrinsic<[llvm_anyint_ty,
LLVMScalarOrSameVectorWidth<0, llvm_i1_ty>], LLVMScalarOrSameVectorWidth<0, llvm_i1_ty>],
[LLVMMatchType<0>, LLVMMatchType<0>], [LLVMMatchType<0>, LLVMMatchType<0>]>;
[IntrNoMem, IntrSpeculatable]>; def int_umul_with_overflow : Intrinsic<[llvm_anyint_ty,
def int_umul_with_overflow : Intrinsic<[llvm_anyint_ty,
LLVMScalarOrSameVectorWidth<0, llvm_i1_ty>], LLVMScalarOrSameVectorWidth<0, llvm_i1_ty>],
[LLVMMatchType<0>, LLVMMatchType<0>], [LLVMMatchType<0>, LLVMMatchType<0>]>;
[IntrNoMem, IntrSpeculatable]>; }
//===------------------------- Saturation Arithmetic Intrinsics ---------------------===// //===------------------------- Saturation Arithmetic Intrinsics ---------------------===//
// //
def int_sadd_sat : Intrinsic<[llvm_anyint_ty], def int_sadd_sat : Intrinsic<[llvm_anyint_ty],
[LLVMMatchType<0>, LLVMMatchType<0>], [LLVMMatchType<0>, LLVMMatchType<0>],
[IntrNoMem, IntrSpeculatable, Commutative]>; [IntrNoMem, IntrSpeculatable, IntrWillReturn, Commutative]>;
def int_uadd_sat : Intrinsic<[llvm_anyint_ty], def int_uadd_sat : Intrinsic<[llvm_anyint_ty],
[LLVMMatchType<0>, LLVMMatchType<0>], [LLVMMatchType<0>, LLVMMatchType<0>],
[IntrNoMem, IntrSpeculatable, Commutative]>; [IntrNoMem, IntrSpeculatable, IntrWillReturn, Commutative]>;
def int_ssub_sat : Intrinsic<[llvm_anyint_ty], def int_ssub_sat : Intrinsic<[llvm_anyint_ty],
[LLVMMatchType<0>, LLVMMatchType<0>], [LLVMMatchType<0>, LLVMMatchType<0>],
[IntrNoMem, IntrSpeculatable]>; [IntrNoMem, IntrSpeculatable, IntrWillReturn]>;
def int_usub_sat : Intrinsic<[llvm_anyint_ty], def int_usub_sat : Intrinsic<[llvm_anyint_ty],
[LLVMMatchType<0>, LLVMMatchType<0>], [LLVMMatchType<0>, LLVMMatchType<0>],
[IntrNoMem, IntrSpeculatable]>; [IntrNoMem, IntrSpeculatable, IntrWillReturn]>;
//===------------------------- Fixed Point Arithmetic Intrinsics ---------------------===// //===------------------------- Fixed Point Arithmetic Intrinsics ---------------------===//
// //
def int_smul_fix : Intrinsic<[llvm_anyint_ty], def int_smul_fix : Intrinsic<[llvm_anyint_ty],
[LLVMMatchType<0>, LLVMMatchType<0>, llvm_i32_ty], [LLVMMatchType<0>, LLVMMatchType<0>, llvm_i32_ty],
[IntrNoMem, IntrSpeculatable, Commutative, ImmArg<2>]>; [IntrNoMem, IntrSpeculatable, IntrWillReturn, Commutative, ImmArg<2>]>;
def int_umul_fix : Intrinsic<[llvm_anyint_ty], def int_umul_fix : Intrinsic<[llvm_anyint_ty],
[LLVMMatchType<0>, LLVMMatchType<0>, llvm_i32_ty], [LLVMMatchType<0>, LLVMMatchType<0>, llvm_i32_ty],
[IntrNoMem, IntrSpeculatable, Commutative, ImmArg<2>]>; [IntrNoMem, IntrSpeculatable, IntrWillReturn, Commutative, ImmArg<2>]>;
//===------------------- Fixed Point Saturation Arithmetic Intrinsics ----------------===// //===------------------- Fixed Point Saturation Arithmetic Intrinsics ----------------===//
// //
def int_smul_fix_sat : Intrinsic<[llvm_anyint_ty], def int_smul_fix_sat : Intrinsic<[llvm_anyint_ty],
[LLVMMatchType<0>, LLVMMatchType<0>, llvm_i32_ty], [LLVMMatchType<0>, LLVMMatchType<0>, llvm_i32_ty],
[IntrNoMem, IntrSpeculatable, Commutative, ImmArg<2>]>; [IntrNoMem, IntrSpeculatable, IntrWillReturn, Commutative, ImmArg<2>]>;
//===------------------------- Memory Use Markers -------------------------===// //===------------------------- Memory Use Markers -------------------------===//
// //
def int_lifetime_start : Intrinsic<[], def int_lifetime_start : Intrinsic<[],
[llvm_i64_ty, llvm_anyptr_ty], [llvm_i64_ty, llvm_anyptr_ty],
[IntrArgMemOnly, NoCapture<1>, ImmArg<0>]>; [IntrArgMemOnly, IntrWillReturn, NoCapture<1>, ImmArg<0>]>;
def int_lifetime_end : Intrinsic<[], def int_lifetime_end : Intrinsic<[],
[llvm_i64_ty, llvm_anyptr_ty], [llvm_i64_ty, llvm_anyptr_ty],
[IntrArgMemOnly, NoCapture<1>, ImmArg<0>]>; [IntrArgMemOnly, IntrWillReturn, NoCapture<1>, ImmArg<0>]>;
def int_invariant_start : Intrinsic<[llvm_descriptor_ty], def int_invariant_start : Intrinsic<[llvm_descriptor_ty],
[llvm_i64_ty, llvm_anyptr_ty], [llvm_i64_ty, llvm_anyptr_ty],
[IntrArgMemOnly, NoCapture<1>, ImmArg<0>]>; [IntrArgMemOnly, IntrWillReturn, NoCapture<1>, ImmArg<0>]>;
def int_invariant_end : Intrinsic<[], def int_invariant_end : Intrinsic<[],
[llvm_descriptor_ty, llvm_i64_ty, [llvm_descriptor_ty, llvm_i64_ty,
llvm_anyptr_ty], llvm_anyptr_ty],
[IntrArgMemOnly, NoCapture<2>, ImmArg<1>]>; [IntrArgMemOnly, IntrWillReturn, NoCapture<2>, ImmArg<1>]>;
// launder.invariant.group can't be marked with 'readnone' (IntrNoMem), // launder.invariant.group can't be marked with 'readnone' (IntrNoMem),
// because it would cause CSE of two barriers with the same argument. // because it would cause CSE of two barriers with the same argument.
@ -916,12 +911,12 @@ def int_invariant_end : Intrinsic<[],
// might change in the future. // might change in the future.
def int_launder_invariant_group : Intrinsic<[llvm_anyptr_ty], def int_launder_invariant_group : Intrinsic<[llvm_anyptr_ty],
[LLVMMatchType<0>], [LLVMMatchType<0>],
[IntrInaccessibleMemOnly, IntrSpeculatable]>; [IntrInaccessibleMemOnly, IntrSpeculatable, IntrWillReturn]>;
def int_strip_invariant_group : Intrinsic<[llvm_anyptr_ty], def int_strip_invariant_group : Intrinsic<[llvm_anyptr_ty],
[LLVMMatchType<0>], [LLVMMatchType<0>],
[IntrSpeculatable, IntrNoMem]>; [IntrSpeculatable, IntrNoMem, IntrWillReturn]>;
//===------------------------ Stackmap Intrinsics -------------------------===// //===------------------------ Stackmap Intrinsics -------------------------===//
// //
@ -1021,7 +1016,7 @@ def int_experimental_widenable_condition : Intrinsic<[llvm_i1_ty], [],
[IntrInaccessibleMemOnly]>; [IntrInaccessibleMemOnly]>;
// NOP: calls/invokes to this intrinsic are removed by codegen // NOP: calls/invokes to this intrinsic are removed by codegen
def int_donothing : Intrinsic<[], [], [IntrNoMem]>; def int_donothing : Intrinsic<[], [], [IntrNoMem, IntrWillReturn]>;
// This instruction has no actual effect, though it is treated by the optimizer // This instruction has no actual effect, though it is treated by the optimizer
// has having opaque side effects. This may be inserted into loops to ensure // has having opaque side effects. This may be inserted into loops to ensure
@ -1030,7 +1025,7 @@ def int_donothing : Intrinsic<[], [], [IntrNoMem]>;
def int_sideeffect : Intrinsic<[], [], [IntrInaccessibleMemOnly]>; def int_sideeffect : Intrinsic<[], [], [IntrInaccessibleMemOnly]>;
// Intrisics to support half precision floating point format // Intrisics to support half precision floating point format
let IntrProperties = [IntrNoMem] in { let IntrProperties = [IntrNoMem, IntrWillReturn] in {
def int_convert_to_fp16 : Intrinsic<[llvm_i16_ty], [llvm_anyfloat_ty]>; def int_convert_to_fp16 : Intrinsic<[llvm_i16_ty], [llvm_anyfloat_ty]>;
def int_convert_from_fp16 : Intrinsic<[llvm_anyfloat_ty], [llvm_i16_ty]>; def int_convert_from_fp16 : Intrinsic<[llvm_anyfloat_ty], [llvm_i16_ty]>;
} }
@ -1041,7 +1036,7 @@ def int_clear_cache : Intrinsic<[], [llvm_ptr_ty, llvm_ptr_ty],
[], "llvm.clear_cache">; [], "llvm.clear_cache">;
// Intrinsic to detect whether its argument is a constant. // Intrinsic to detect whether its argument is a constant.
def int_is_constant : Intrinsic<[llvm_i1_ty], [llvm_any_ty], [IntrNoMem], "llvm.is.constant">; def int_is_constant : Intrinsic<[llvm_i1_ty], [llvm_any_ty], [IntrNoMem, IntrWillReturn], "llvm.is.constant">;
//===-------------------------- Masked Intrinsics -------------------------===// //===-------------------------- Masked Intrinsics -------------------------===//
// //
@ -1049,45 +1044,45 @@ def int_masked_store : Intrinsic<[], [llvm_anyvector_ty,
LLVMAnyPointerType<LLVMMatchType<0>>, LLVMAnyPointerType<LLVMMatchType<0>>,
llvm_i32_ty, llvm_i32_ty,
LLVMScalarOrSameVectorWidth<0, llvm_i1_ty>], LLVMScalarOrSameVectorWidth<0, llvm_i1_ty>],
[IntrArgMemOnly, ImmArg<2>]>; [IntrArgMemOnly, IntrWillReturn, ImmArg<2>]>;
def int_masked_load : Intrinsic<[llvm_anyvector_ty], def int_masked_load : Intrinsic<[llvm_anyvector_ty],
[LLVMAnyPointerType<LLVMMatchType<0>>, llvm_i32_ty, [LLVMAnyPointerType<LLVMMatchType<0>>, llvm_i32_ty,
LLVMScalarOrSameVectorWidth<0, llvm_i1_ty>, LLVMMatchType<0>], LLVMScalarOrSameVectorWidth<0, llvm_i1_ty>, LLVMMatchType<0>],
[IntrReadMem, IntrArgMemOnly, ImmArg<1>]>; [IntrReadMem, IntrArgMemOnly, IntrWillReturn, ImmArg<1>]>;
def int_masked_gather: Intrinsic<[llvm_anyvector_ty], def int_masked_gather: Intrinsic<[llvm_anyvector_ty],
[LLVMVectorOfAnyPointersToElt<0>, llvm_i32_ty, [LLVMVectorOfAnyPointersToElt<0>, llvm_i32_ty,
LLVMScalarOrSameVectorWidth<0, llvm_i1_ty>, LLVMScalarOrSameVectorWidth<0, llvm_i1_ty>,
LLVMMatchType<0>], LLVMMatchType<0>],
[IntrReadMem, ImmArg<1>]>; [IntrReadMem, IntrWillReturn, ImmArg<1>]>;
def int_masked_scatter: Intrinsic<[], def int_masked_scatter: Intrinsic<[],
[llvm_anyvector_ty, [llvm_anyvector_ty,
LLVMVectorOfAnyPointersToElt<0>, llvm_i32_ty, LLVMVectorOfAnyPointersToElt<0>, llvm_i32_ty,
LLVMScalarOrSameVectorWidth<0, llvm_i1_ty>], LLVMScalarOrSameVectorWidth<0, llvm_i1_ty>],
[ImmArg<2>]>; [IntrWillReturn, ImmArg<2>]>;
def int_masked_expandload: Intrinsic<[llvm_anyvector_ty], def int_masked_expandload: Intrinsic<[llvm_anyvector_ty],
[LLVMPointerToElt<0>, [LLVMPointerToElt<0>,
LLVMScalarOrSameVectorWidth<0, llvm_i1_ty>, LLVMScalarOrSameVectorWidth<0, llvm_i1_ty>,
LLVMMatchType<0>], LLVMMatchType<0>],
[IntrReadMem]>; [IntrReadMem, IntrWillReturn]>;
def int_masked_compressstore: Intrinsic<[], def int_masked_compressstore: Intrinsic<[],
[llvm_anyvector_ty, [llvm_anyvector_ty,
LLVMPointerToElt<0>, LLVMPointerToElt<0>,
LLVMScalarOrSameVectorWidth<0, llvm_i1_ty>], LLVMScalarOrSameVectorWidth<0, llvm_i1_ty>],
[IntrArgMemOnly]>; [IntrArgMemOnly, IntrWillReturn]>;
// Test whether a pointer is associated with a type metadata identifier. // Test whether a pointer is associated with a type metadata identifier.
def int_type_test : Intrinsic<[llvm_i1_ty], [llvm_ptr_ty, llvm_metadata_ty], def int_type_test : Intrinsic<[llvm_i1_ty], [llvm_ptr_ty, llvm_metadata_ty],
[IntrNoMem]>; [IntrNoMem, IntrWillReturn]>;
// Safely loads a function pointer from a virtual table pointer using type metadata. // Safely loads a function pointer from a virtual table pointer using type metadata.
def int_type_checked_load : Intrinsic<[llvm_ptr_ty, llvm_i1_ty], def int_type_checked_load : Intrinsic<[llvm_ptr_ty, llvm_i1_ty],
[llvm_ptr_ty, llvm_i32_ty, llvm_metadata_ty], [llvm_ptr_ty, llvm_i32_ty, llvm_metadata_ty],
[IntrNoMem]>; [IntrNoMem, IntrWillReturn]>;
// Create a branch funnel that implements an indirect call to a limited set of // Create a branch funnel that implements an indirect call to a limited set of
// callees. This needs to be a musttail call. // callees. This needs to be a musttail call.
@ -1121,7 +1116,7 @@ def int_memcpy_element_unordered_atomic
llvm_anyptr_ty, llvm_anyptr_ty, llvm_anyint_ty, llvm_i32_ty llvm_anyptr_ty, llvm_anyptr_ty, llvm_anyint_ty, llvm_i32_ty
], ],
[ [
IntrArgMemOnly, NoCapture<0>, NoCapture<1>, WriteOnly<0>, IntrArgMemOnly, IntrWillReturn, NoCapture<0>, NoCapture<1>, WriteOnly<0>,
ReadOnly<1>, ImmArg<3> ReadOnly<1>, ImmArg<3>
]>; ]>;
@ -1132,58 +1127,47 @@ def int_memmove_element_unordered_atomic
llvm_anyptr_ty, llvm_anyptr_ty, llvm_anyint_ty, llvm_i32_ty llvm_anyptr_ty, llvm_anyptr_ty, llvm_anyint_ty, llvm_i32_ty
], ],
[ [
IntrArgMemOnly, NoCapture<0>, NoCapture<1>, WriteOnly<0>, IntrArgMemOnly, IntrWillReturn, NoCapture<0>, NoCapture<1>, WriteOnly<0>,
ReadOnly<1>, ImmArg<3> ReadOnly<1>, ImmArg<3>
]>; ]>;
// @llvm.memset.element.unordered.atomic.*(dest, value, length, elementsize) // @llvm.memset.element.unordered.atomic.*(dest, value, length, elementsize)
def int_memset_element_unordered_atomic def int_memset_element_unordered_atomic
: Intrinsic<[], [ llvm_anyptr_ty, llvm_i8_ty, llvm_anyint_ty, llvm_i32_ty ], : Intrinsic<[], [ llvm_anyptr_ty, llvm_i8_ty, llvm_anyint_ty, llvm_i32_ty ],
[ IntrArgMemOnly, NoCapture<0>, WriteOnly<0>, ImmArg<3> ]>; [ IntrArgMemOnly, IntrWillReturn, NoCapture<0>, WriteOnly<0>, ImmArg<3> ]>;
//===------------------------ Reduction Intrinsics ------------------------===// //===------------------------ Reduction Intrinsics ------------------------===//
// //
def int_experimental_vector_reduce_v2_fadd : Intrinsic<[llvm_anyfloat_ty], let IntrProperties = [IntrNoMem, IntrWillReturn] in {
def int_experimental_vector_reduce_v2_fadd : Intrinsic<[llvm_anyfloat_ty],
[LLVMMatchType<0>, [LLVMMatchType<0>,
llvm_anyvector_ty], llvm_anyvector_ty]>;
[IntrNoMem]>; def int_experimental_vector_reduce_v2_fmul : Intrinsic<[llvm_anyfloat_ty],
def int_experimental_vector_reduce_v2_fmul : Intrinsic<[llvm_anyfloat_ty],
[LLVMMatchType<0>, [LLVMMatchType<0>,
llvm_anyvector_ty], llvm_anyvector_ty]>;
[IntrNoMem]>; def int_experimental_vector_reduce_add : Intrinsic<[LLVMVectorElementType<0>],
def int_experimental_vector_reduce_add : Intrinsic<[LLVMVectorElementType<0>], [llvm_anyvector_ty]>;
[llvm_anyvector_ty], def int_experimental_vector_reduce_mul : Intrinsic<[LLVMVectorElementType<0>],
[IntrNoMem]>; [llvm_anyvector_ty]>;
def int_experimental_vector_reduce_mul : Intrinsic<[LLVMVectorElementType<0>], def int_experimental_vector_reduce_and : Intrinsic<[LLVMVectorElementType<0>],
[llvm_anyvector_ty], [llvm_anyvector_ty]>;
[IntrNoMem]>; def int_experimental_vector_reduce_or : Intrinsic<[LLVMVectorElementType<0>],
def int_experimental_vector_reduce_and : Intrinsic<[LLVMVectorElementType<0>], [llvm_anyvector_ty]>;
[llvm_anyvector_ty], def int_experimental_vector_reduce_xor : Intrinsic<[LLVMVectorElementType<0>],
[IntrNoMem]>; [llvm_anyvector_ty]>;
def int_experimental_vector_reduce_or : Intrinsic<[LLVMVectorElementType<0>], def int_experimental_vector_reduce_smax : Intrinsic<[LLVMVectorElementType<0>],
[llvm_anyvector_ty], [llvm_anyvector_ty]>;
[IntrNoMem]>; def int_experimental_vector_reduce_smin : Intrinsic<[LLVMVectorElementType<0>],
def int_experimental_vector_reduce_xor : Intrinsic<[LLVMVectorElementType<0>], [llvm_anyvector_ty]>;
[llvm_anyvector_ty], def int_experimental_vector_reduce_umax : Intrinsic<[LLVMVectorElementType<0>],
[IntrNoMem]>; [llvm_anyvector_ty]>;
def int_experimental_vector_reduce_smax : Intrinsic<[LLVMVectorElementType<0>], def int_experimental_vector_reduce_umin : Intrinsic<[LLVMVectorElementType<0>],
[llvm_anyvector_ty], [llvm_anyvector_ty]>;
[IntrNoMem]>; def int_experimental_vector_reduce_fmax : Intrinsic<[LLVMVectorElementType<0>],
def int_experimental_vector_reduce_smin : Intrinsic<[LLVMVectorElementType<0>], [llvm_anyvector_ty]>;
[llvm_anyvector_ty], def int_experimental_vector_reduce_fmin : Intrinsic<[LLVMVectorElementType<0>],
[IntrNoMem]>; [llvm_anyvector_ty]>;
def int_experimental_vector_reduce_umax : Intrinsic<[LLVMVectorElementType<0>], }
[llvm_anyvector_ty],
[IntrNoMem]>;
def int_experimental_vector_reduce_umin : Intrinsic<[LLVMVectorElementType<0>],
[llvm_anyvector_ty],
[IntrNoMem]>;
def int_experimental_vector_reduce_fmax : Intrinsic<[LLVMVectorElementType<0>],
[llvm_anyvector_ty],
[IntrNoMem]>;
def int_experimental_vector_reduce_fmin : Intrinsic<[LLVMVectorElementType<0>],
[llvm_anyvector_ty],
[IntrNoMem]>;
//===---------- Intrinsics to control hardware supported loops ----------===// //===---------- Intrinsics to control hardware supported loops ----------===//

View File

@ -364,26 +364,26 @@ entry:
call void @an_argmemonly_func(i8* %q) #9 [ "unknown"() ] call void @an_argmemonly_func(i8* %q) #9 [ "unknown"() ]
ret void ret void
; CHECK: Just Ref: Ptr: i8* %p <-> call void @a_readonly_func(i8* %p) #6 [ "unknown"() ] ; CHECK: Just Ref: Ptr: i8* %p <-> call void @a_readonly_func(i8* %p) #7 [ "unknown"() ]
; CHECK: Just Ref: Ptr: i8* %q <-> call void @a_readonly_func(i8* %p) #6 [ "unknown"() ] ; CHECK: Just Ref: Ptr: i8* %q <-> call void @a_readonly_func(i8* %p) #7 [ "unknown"() ]
; CHECK: NoModRef: Ptr: i8* %p <-> call void @an_inaccessiblememonly_func() #7 [ "unknown"() ] ; CHECK: NoModRef: Ptr: i8* %p <-> call void @an_inaccessiblememonly_func() #8 [ "unknown"() ]
; CHECK: NoModRef: Ptr: i8* %q <-> call void @an_inaccessiblememonly_func() #7 [ "unknown"() ] ; CHECK: NoModRef: Ptr: i8* %q <-> call void @an_inaccessiblememonly_func() #8 [ "unknown"() ]
; CHECK: NoModRef: Ptr: i8* %p <-> call void @an_inaccessibleorargmemonly_func(i8* %q) #8 [ "unknown"() ] ; CHECK: NoModRef: Ptr: i8* %p <-> call void @an_inaccessibleorargmemonly_func(i8* %q) #9 [ "unknown"() ]
; CHECK: Both ModRef (MustAlias): Ptr: i8* %q <-> call void @an_inaccessibleorargmemonly_func(i8* %q) #8 [ "unknown"() ] ; CHECK: Both ModRef (MustAlias): Ptr: i8* %q <-> call void @an_inaccessibleorargmemonly_func(i8* %q) #9 [ "unknown"() ]
; CHECK: NoModRef: Ptr: i8* %p <-> call void @an_argmemonly_func(i8* %q) #9 [ "unknown"() ] ; CHECK: NoModRef: Ptr: i8* %p <-> call void @an_argmemonly_func(i8* %q) #10 [ "unknown"() ]
; CHECK: Both ModRef (MustAlias): Ptr: i8* %q <-> call void @an_argmemonly_func(i8* %q) #9 [ "unknown"() ] ; CHECK: Both ModRef (MustAlias): Ptr: i8* %q <-> call void @an_argmemonly_func(i8* %q) #10 [ "unknown"() ]
; CHECK: Just Ref: call void @a_readonly_func(i8* %p) #6 [ "unknown"() ] <-> call void @an_inaccessiblememonly_func() #7 [ "unknown"() ] ; CHECK: Just Ref: call void @a_readonly_func(i8* %p) #7 [ "unknown"() ] <-> call void @an_inaccessiblememonly_func() #8 [ "unknown"() ]
; CHECK: Just Ref: call void @a_readonly_func(i8* %p) #6 [ "unknown"() ] <-> call void @an_inaccessibleorargmemonly_func(i8* %q) #8 [ "unknown"() ] ; CHECK: Just Ref: call void @a_readonly_func(i8* %p) #7 [ "unknown"() ] <-> call void @an_inaccessibleorargmemonly_func(i8* %q) #9 [ "unknown"() ]
; CHECK: Just Ref: call void @a_readonly_func(i8* %p) #6 [ "unknown"() ] <-> call void @an_argmemonly_func(i8* %q) #9 [ "unknown"() ] ; CHECK: Just Ref: call void @a_readonly_func(i8* %p) #7 [ "unknown"() ] <-> call void @an_argmemonly_func(i8* %q) #10 [ "unknown"() ]
; CHECK: Both ModRef: call void @an_inaccessiblememonly_func() #7 [ "unknown"() ] <-> call void @a_readonly_func(i8* %p) #6 [ "unknown"() ] ; CHECK: Both ModRef: call void @an_inaccessiblememonly_func() #8 [ "unknown"() ] <-> call void @a_readonly_func(i8* %p) #7 [ "unknown"() ]
; CHECK: Both ModRef: call void @an_inaccessiblememonly_func() #7 [ "unknown"() ] <-> call void @an_inaccessibleorargmemonly_func(i8* %q) #8 [ "unknown"() ] ; CHECK: Both ModRef: call void @an_inaccessiblememonly_func() #8 [ "unknown"() ] <-> call void @an_inaccessibleorargmemonly_func(i8* %q) #9 [ "unknown"() ]
; CHECK: NoModRef: call void @an_inaccessiblememonly_func() #7 [ "unknown"() ] <-> call void @an_argmemonly_func(i8* %q) #9 [ "unknown"() ] ; CHECK: NoModRef: call void @an_inaccessiblememonly_func() #8 [ "unknown"() ] <-> call void @an_argmemonly_func(i8* %q) #10 [ "unknown"() ]
; CHECK: Both ModRef: call void @an_inaccessibleorargmemonly_func(i8* %q) #8 [ "unknown"() ] <-> call void @a_readonly_func(i8* %p) #6 [ "unknown"() ] ; CHECK: Both ModRef: call void @an_inaccessibleorargmemonly_func(i8* %q) #9 [ "unknown"() ] <-> call void @a_readonly_func(i8* %p) #7 [ "unknown"() ]
; CHECK: Both ModRef: call void @an_inaccessibleorargmemonly_func(i8* %q) #8 [ "unknown"() ] <-> call void @an_inaccessiblememonly_func() #7 [ "unknown"() ] ; CHECK: Both ModRef: call void @an_inaccessibleorargmemonly_func(i8* %q) #9 [ "unknown"() ] <-> call void @an_inaccessiblememonly_func() #8 [ "unknown"() ]
; CHECK: Both ModRef (MustAlias): call void @an_inaccessibleorargmemonly_func(i8* %q) #8 [ "unknown"() ] <-> call void @an_argmemonly_func(i8* %q) #9 [ "unknown"() ] ; CHECK: Both ModRef (MustAlias): call void @an_inaccessibleorargmemonly_func(i8* %q) #9 [ "unknown"() ] <-> call void @an_argmemonly_func(i8* %q) #10 [ "unknown"() ]
; CHECK: Both ModRef: call void @an_argmemonly_func(i8* %q) #9 [ "unknown"() ] <-> call void @a_readonly_func(i8* %p) #6 [ "unknown"() ] ; CHECK: Both ModRef: call void @an_argmemonly_func(i8* %q) #10 [ "unknown"() ] <-> call void @a_readonly_func(i8* %p) #7 [ "unknown"() ]
; CHECK: NoModRef: call void @an_argmemonly_func(i8* %q) #9 [ "unknown"() ] <-> call void @an_inaccessiblememonly_func() #7 [ "unknown"() ] ; CHECK: NoModRef: call void @an_argmemonly_func(i8* %q) #10 [ "unknown"() ] <-> call void @an_inaccessiblememonly_func() #8 [ "unknown"() ]
; CHECK: Both ModRef (MustAlias): call void @an_argmemonly_func(i8* %q) #9 [ "unknown"() ] <-> call void @an_inaccessibleorargmemonly_func(i8* %q) #8 [ "unknown"() ] ; CHECK: Both ModRef (MustAlias): call void @an_argmemonly_func(i8* %q) #10 [ "unknown"() ] <-> call void @an_inaccessibleorargmemonly_func(i8* %q) #9 [ "unknown"() ]
} }
attributes #0 = { argmemonly nounwind } attributes #0 = { argmemonly nounwind }

View File

@ -22,6 +22,6 @@ entry:
declare <8 x i16> @llvm.masked.load.v8i16.p0v8i16(<8 x i16>*, i32, <8 x i1>, <8 x i16>) nounwind readonly declare <8 x i16> @llvm.masked.load.v8i16.p0v8i16(<8 x i16>*, i32, <8 x i1>, <8 x i16>) nounwind readonly
declare void @llvm.masked.store.v8i16.p0v8i16(<8 x i16>, <8 x i16>*, i32, <8 x i1>) nounwind declare void @llvm.masked.store.v8i16.p0v8i16(<8 x i16>, <8 x i16>*, i32, <8 x i1>) nounwind
; CHECK: attributes #0 = { argmemonly nounwind readonly } ; CHECK: attributes #0 = { argmemonly nounwind readonly willreturn }
; CHECK: attributes #1 = { argmemonly nounwind } ; CHECK: attributes #1 = { argmemonly nounwind willreturn }
; CHECK: attributes [[ATTR]] = { nounwind } ; CHECK: attributes [[ATTR]] = { nounwind }

View File

@ -78,7 +78,7 @@ declare void @llvm.memcpy.p0i8.p0i8.i64(i8*, i8*, i64, i1) nounwind
; CHECK: attributes #3 = { nounwind } ; CHECK: attributes #3 = { nounwind }
; CHECK: attributes #4 = { nounwind readnone } ; CHECK: attributes #4 = { nounwind readnone }
; CHECK: attributes #5 = { nofree norecurse nounwind } ; CHECK: attributes #5 = { nofree norecurse nounwind }
; CHECK: attributes #6 = { argmemonly nounwind } ; CHECK: attributes #6 = { argmemonly nounwind willreturn }
; Root note. ; Root note.
!0 = !{ } !0 = !{ }

View File

@ -22,8 +22,8 @@ entry:
declare <8 x i16> @llvm.masked.load.v8i16.p0v8i16(<8 x i16>*, i32, <8 x i1>, <8 x i16>) nounwind readonly declare <8 x i16> @llvm.masked.load.v8i16.p0v8i16(<8 x i16>*, i32, <8 x i1>, <8 x i16>) nounwind readonly
declare void @llvm.masked.store.v8i16.p0v8i16(<8 x i16>, <8 x i16>*, i32, <8 x i1>) nounwind declare void @llvm.masked.store.v8i16.p0v8i16(<8 x i16>, <8 x i16>*, i32, <8 x i1>) nounwind
; CHECK: attributes #0 = { argmemonly nounwind readonly } ; CHECK: attributes #0 = { argmemonly nounwind readonly willreturn }
; CHECK: attributes #1 = { argmemonly nounwind } ; CHECK: attributes #1 = { argmemonly nounwind willreturn }
; CHECK: attributes [[NUW]] = { nounwind } ; CHECK: attributes [[NUW]] = { nounwind }
!0 = !{!"tbaa root"} !0 = !{!"tbaa root"}

View File

@ -18,7 +18,7 @@
; CHECK: ; Function Attrs: nounwind readnone speculatable ; CHECK: ; Function Attrs: nounwind readnone speculatable
; CHECK-NEXT: declare void @llvm.dbg.value(metadata, metadata, metadata) #0 ; CHECK-NEXT: declare void @llvm.dbg.value(metadata, metadata, metadata) #0
; CHECK: attributes #0 = { nounwind readnone speculatable } ; CHECK: attributes #0 = { nounwind readnone speculatable willreturn }
; CHECK: !llvm.dbg.cu = !{!0} ; CHECK: !llvm.dbg.cu = !{!0}
; CHECK-NEXT: !FooType = !{!16} ; CHECK-NEXT: !FooType = !{!16}

View File

@ -981,7 +981,7 @@ exit:
; CHECK: select <2 x i1> <i1 true, i1 false>, <2 x i8> <i8 2, i8 3>, <2 x i8> <i8 3, i8 2> ; CHECK: select <2 x i1> <i1 true, i1 false>, <2 x i8> <i8 2, i8 3>, <2 x i8> <i8 3, i8 2>
call void @f.nobuiltin() builtin call void @f.nobuiltin() builtin
; CHECK: call void @f.nobuiltin() #34 ; CHECK: call void @f.nobuiltin() #35
call fastcc noalias i32* @f.noalias() noinline call fastcc noalias i32* @f.noalias() noinline
; CHECK: call fastcc noalias i32* @f.noalias() #11 ; CHECK: call fastcc noalias i32* @f.noalias() #11
@ -1179,12 +1179,13 @@ define void @intrinsics.codegen() {
; CHECK: attributes #26 = { sspstrong } ; CHECK: attributes #26 = { sspstrong }
; CHECK: attributes #27 = { uwtable } ; CHECK: attributes #27 = { uwtable }
; CHECK: attributes #28 = { "cpu"="cortex-a8" } ; CHECK: attributes #28 = { "cpu"="cortex-a8" }
; CHECK: attributes #29 = { nounwind readnone } ; CHECK: attributes #29 = { nounwind readnone willreturn }
; CHECK: attributes #30 = { argmemonly nounwind readonly } ; CHECK: attributes #30 = { argmemonly nounwind readonly }
; CHECK: attributes #31 = { argmemonly nounwind } ; CHECK: attributes #31 = { argmemonly nounwind }
; CHECK: attributes #32 = { nounwind readonly } ; CHECK: attributes #32 = { nounwind readnone }
; CHECK: attributes #33 = { inaccessiblemem_or_argmemonly nounwind } ; CHECK: attributes #33 = { nounwind readonly }
; CHECK: attributes #34 = { builtin } ; CHECK: attributes #34 = { inaccessiblemem_or_argmemonly nounwind willreturn }
; CHECK: attributes #35 = { builtin }
;; Metadata ;; Metadata

View File

@ -1022,7 +1022,7 @@ exit:
; CHECK: select <2 x i1> <i1 true, i1 false>, <2 x i8> <i8 2, i8 3>, <2 x i8> <i8 3, i8 2> ; CHECK: select <2 x i1> <i1 true, i1 false>, <2 x i8> <i8 2, i8 3>, <2 x i8> <i8 3, i8 2>
call void @f.nobuiltin() builtin call void @f.nobuiltin() builtin
; CHECK: call void @f.nobuiltin() #37 ; CHECK: call void @f.nobuiltin() #38
call fastcc noalias i32* @f.noalias() noinline call fastcc noalias i32* @f.noalias() noinline
; CHECK: call fastcc noalias i32* @f.noalias() #12 ; CHECK: call fastcc noalias i32* @f.noalias() #12
@ -1242,12 +1242,13 @@ define void @misc.metadata() {
; CHECK: attributes #29 = { "thunk" } ; CHECK: attributes #29 = { "thunk" }
; CHECK: attributes #30 = { uwtable } ; CHECK: attributes #30 = { uwtable }
; CHECK: attributes #31 = { "cpu"="cortex-a8" } ; CHECK: attributes #31 = { "cpu"="cortex-a8" }
; CHECK: attributes #32 = { nounwind readnone } ; CHECK: attributes #32 = { nounwind readnone willreturn }
; CHECK: attributes #33 = { argmemonly nounwind readonly } ; CHECK: attributes #33 = { argmemonly nounwind readonly }
; CHECK: attributes #34 = { argmemonly nounwind } ; CHECK: attributes #34 = { argmemonly nounwind }
; CHECK: attributes #35 = { nounwind readonly } ; CHECK: attributes #35 = { nounwind readnone }
; CHECK: attributes #36 = { inaccessiblemem_or_argmemonly nounwind } ; CHECK: attributes #36 = { nounwind readonly }
; CHECK: attributes #37 = { builtin } ; CHECK: attributes #37 = { inaccessiblemem_or_argmemonly nounwind willreturn }
; CHECK: attributes #38 = { builtin }
;; Metadata ;; Metadata

View File

@ -1170,7 +1170,7 @@ exit:
; CHECK: select <2 x i1> <i1 true, i1 false>, <2 x i8> <i8 2, i8 3>, <2 x i8> <i8 3, i8 2> ; CHECK: select <2 x i1> <i1 true, i1 false>, <2 x i8> <i8 2, i8 3>, <2 x i8> <i8 3, i8 2>
call void @f.nobuiltin() builtin call void @f.nobuiltin() builtin
; CHECK: call void @f.nobuiltin() #40 ; CHECK: call void @f.nobuiltin() #41
call fastcc noalias i32* @f.noalias() noinline call fastcc noalias i32* @f.noalias() noinline
; CHECK: call fastcc noalias i32* @f.noalias() #12 ; CHECK: call fastcc noalias i32* @f.noalias() #12
@ -1552,12 +1552,13 @@ normal:
; CHECK: attributes #32 = { norecurse } ; CHECK: attributes #32 = { norecurse }
; CHECK: attributes #33 = { inaccessiblememonly } ; CHECK: attributes #33 = { inaccessiblememonly }
; CHECK: attributes #34 = { inaccessiblemem_or_argmemonly } ; CHECK: attributes #34 = { inaccessiblemem_or_argmemonly }
; CHECK: attributes #35 = { nounwind readnone } ; CHECK: attributes #35 = { nounwind readnone willreturn }
; CHECK: attributes #36 = { argmemonly nounwind readonly } ; CHECK: attributes #36 = { argmemonly nounwind readonly }
; CHECK: attributes #37 = { argmemonly nounwind } ; CHECK: attributes #37 = { argmemonly nounwind }
; CHECK: attributes #38 = { nounwind readonly } ; CHECK: attributes #38 = { nounwind readnone }
; CHECK: attributes #39 = { inaccessiblemem_or_argmemonly nounwind } ; CHECK: attributes #39 = { nounwind readonly }
; CHECK: attributes #40 = { builtin } ; CHECK: attributes #40 = { inaccessiblemem_or_argmemonly nounwind willreturn }
; CHECK: attributes #41 = { builtin }
;; Metadata ;; Metadata

View File

@ -1241,7 +1241,7 @@ exit:
; CHECK: select <2 x i1> <i1 true, i1 false>, <2 x i8> <i8 2, i8 3>, <2 x i8> <i8 3, i8 2> ; CHECK: select <2 x i1> <i1 true, i1 false>, <2 x i8> <i8 2, i8 3>, <2 x i8> <i8 3, i8 2>
call void @f.nobuiltin() builtin call void @f.nobuiltin() builtin
; CHECK: call void @f.nobuiltin() #41 ; CHECK: call void @f.nobuiltin() #42
call fastcc noalias i32* @f.noalias() noinline call fastcc noalias i32* @f.noalias() noinline
; CHECK: call fastcc noalias i32* @f.noalias() #12 ; CHECK: call fastcc noalias i32* @f.noalias() #12
@ -1588,7 +1588,7 @@ normal:
} }
declare void @f.writeonly() writeonly declare void @f.writeonly() writeonly
; CHECK: declare void @f.writeonly() #39 ; CHECK: declare void @f.writeonly() #40
; CHECK: attributes #0 = { alignstack=4 } ; CHECK: attributes #0 = { alignstack=4 }
; CHECK: attributes #1 = { alignstack=8 } ; CHECK: attributes #1 = { alignstack=8 }
@ -1625,13 +1625,14 @@ declare void @f.writeonly() writeonly
; CHECK: attributes #32 = { norecurse } ; CHECK: attributes #32 = { norecurse }
; CHECK: attributes #33 = { inaccessiblememonly } ; CHECK: attributes #33 = { inaccessiblememonly }
; CHECK: attributes #34 = { inaccessiblemem_or_argmemonly } ; CHECK: attributes #34 = { inaccessiblemem_or_argmemonly }
; CHECK: attributes #35 = { nounwind readnone } ; CHECK: attributes #35 = { nounwind readnone willreturn }
; CHECK: attributes #36 = { argmemonly nounwind readonly } ; CHECK: attributes #36 = { argmemonly nounwind readonly }
; CHECK: attributes #37 = { argmemonly nounwind } ; CHECK: attributes #37 = { argmemonly nounwind }
; CHECK: attributes #38 = { nounwind readonly } ; CHECK: attributes #38 = { nounwind readnone }
; CHECK: attributes #39 = { writeonly } ; CHECK: attributes #39 = { nounwind readonly }
; CHECK: attributes #40 = { inaccessiblemem_or_argmemonly nounwind } ; CHECK: attributes #40 = { writeonly }
; CHECK: attributes #41 = { builtin } ; CHECK: attributes #41 = { inaccessiblemem_or_argmemonly nounwind willreturn }
; CHECK: attributes #42 = { builtin }
;; Metadata ;; Metadata

View File

@ -1241,7 +1241,7 @@ exit:
; CHECK: select <2 x i1> <i1 true, i1 false>, <2 x i8> <i8 2, i8 3>, <2 x i8> <i8 3, i8 2> ; CHECK: select <2 x i1> <i1 true, i1 false>, <2 x i8> <i8 2, i8 3>, <2 x i8> <i8 3, i8 2>
call void @f.nobuiltin() builtin call void @f.nobuiltin() builtin
; CHECK: call void @f.nobuiltin() #41 ; CHECK: call void @f.nobuiltin() #42
call fastcc noalias i32* @f.noalias() noinline call fastcc noalias i32* @f.noalias() noinline
; CHECK: call fastcc noalias i32* @f.noalias() #12 ; CHECK: call fastcc noalias i32* @f.noalias() #12
@ -1606,7 +1606,7 @@ normal:
declare void @f.writeonly() writeonly declare void @f.writeonly() writeonly
; CHECK: declare void @f.writeonly() #39 ; CHECK: declare void @f.writeonly() #40
;; Constant Expressions ;; Constant Expressions
@ -1650,13 +1650,14 @@ define i8** @constexpr() {
; CHECK: attributes #32 = { norecurse } ; CHECK: attributes #32 = { norecurse }
; CHECK: attributes #33 = { inaccessiblememonly } ; CHECK: attributes #33 = { inaccessiblememonly }
; CHECK: attributes #34 = { inaccessiblemem_or_argmemonly } ; CHECK: attributes #34 = { inaccessiblemem_or_argmemonly }
; CHECK: attributes #35 = { nounwind readnone } ; CHECK: attributes #35 = { nounwind readnone willreturn }
; CHECK: attributes #36 = { argmemonly nounwind readonly } ; CHECK: attributes #36 = { argmemonly nounwind readonly }
; CHECK: attributes #37 = { argmemonly nounwind } ; CHECK: attributes #37 = { argmemonly nounwind }
; CHECK: attributes #38 = { nounwind readonly } ; CHECK: attributes #38 = { nounwind readnone }
; CHECK: attributes #39 = { writeonly } ; CHECK: attributes #39 = { nounwind readonly }
; CHECK: attributes #40 = { inaccessiblemem_or_argmemonly nounwind } ; CHECK: attributes #40 = { writeonly }
; CHECK: attributes #41 = { builtin } ; CHECK: attributes #41 = { inaccessiblemem_or_argmemonly nounwind willreturn }
; CHECK: attributes #42 = { builtin }
;; Metadata ;; Metadata

View File

@ -1248,10 +1248,10 @@ exit:
; CHECK: select <2 x i1> <i1 true, i1 false>, <2 x i8> <i8 2, i8 3>, <2 x i8> <i8 3, i8 2> ; CHECK: select <2 x i1> <i1 true, i1 false>, <2 x i8> <i8 2, i8 3>, <2 x i8> <i8 3, i8 2>
call void @f.nobuiltin() builtin call void @f.nobuiltin() builtin
; CHECK: call void @f.nobuiltin() #42 ; CHECK: call void @f.nobuiltin() #43
call void @f.strictfp() strictfp call void @f.strictfp() strictfp
; CHECK: call void @f.strictfp() #43 ; CHECK: call void @f.strictfp() #44
call fastcc noalias i32* @f.noalias() noinline call fastcc noalias i32* @f.noalias() noinline
; CHECK: call fastcc noalias i32* @f.noalias() #12 ; CHECK: call fastcc noalias i32* @f.noalias() #12
@ -1616,10 +1616,10 @@ normal:
declare void @f.writeonly() writeonly declare void @f.writeonly() writeonly
; CHECK: declare void @f.writeonly() #39 ; CHECK: declare void @f.writeonly() #40
declare void @f.speculatable() speculatable declare void @f.speculatable() speculatable
; CHECK: declare void @f.speculatable() #40 ; CHECK: declare void @f.speculatable() #41
;; Constant Expressions ;; Constant Expressions
@ -1663,15 +1663,16 @@ define i8** @constexpr() {
; CHECK: attributes #32 = { norecurse } ; CHECK: attributes #32 = { norecurse }
; CHECK: attributes #33 = { inaccessiblememonly } ; CHECK: attributes #33 = { inaccessiblememonly }
; CHECK: attributes #34 = { inaccessiblemem_or_argmemonly } ; CHECK: attributes #34 = { inaccessiblemem_or_argmemonly }
; CHECK: attributes #35 = { nounwind readnone } ; CHECK: attributes #35 = { nounwind readnone willreturn }
; CHECK: attributes #36 = { argmemonly nounwind readonly } ; CHECK: attributes #36 = { argmemonly nounwind readonly }
; CHECK: attributes #37 = { argmemonly nounwind } ; CHECK: attributes #37 = { argmemonly nounwind }
; CHECK: attributes #38 = { nounwind readonly } ; CHECK: attributes #38 = { nounwind readnone }
; CHECK: attributes #39 = { writeonly } ; CHECK: attributes #39 = { nounwind readonly }
; CHECK: attributes #40 = { speculatable } ; CHECK: attributes #40 = { writeonly }
; CHECK: attributes #41 = { inaccessiblemem_or_argmemonly nounwind } ; CHECK: attributes #41 = { speculatable }
; CHECK: attributes #42 = { builtin } ; CHECK: attributes #42 = { inaccessiblemem_or_argmemonly nounwind willreturn }
; CHECK: attributes #43 = { strictfp } ; CHECK: attributes #43 = { builtin }
; CHECK: attributes #44 = { strictfp }
;; Metadata ;; Metadata

View File

@ -1259,10 +1259,10 @@ exit:
; CHECK: select <2 x i1> <i1 true, i1 false>, <2 x i8> <i8 2, i8 3>, <2 x i8> <i8 3, i8 2> ; CHECK: select <2 x i1> <i1 true, i1 false>, <2 x i8> <i8 2, i8 3>, <2 x i8> <i8 3, i8 2>
call void @f.nobuiltin() builtin call void @f.nobuiltin() builtin
; CHECK: call void @f.nobuiltin() #42 ; CHECK: call void @f.nobuiltin() #43
call void @f.strictfp() strictfp call void @f.strictfp() strictfp
; CHECK: call void @f.strictfp() #43 ; CHECK: call void @f.strictfp() #44
call fastcc noalias i32* @f.noalias() noinline call fastcc noalias i32* @f.noalias() noinline
; CHECK: call fastcc noalias i32* @f.noalias() #12 ; CHECK: call fastcc noalias i32* @f.noalias() #12
@ -1627,10 +1627,10 @@ normal:
declare void @f.writeonly() writeonly declare void @f.writeonly() writeonly
; CHECK: declare void @f.writeonly() #39 ; CHECK: declare void @f.writeonly() #40
declare void @f.speculatable() speculatable declare void @f.speculatable() speculatable
; CHECK: declare void @f.speculatable() #40 ; CHECK: declare void @f.speculatable() #41
;; Constant Expressions ;; Constant Expressions
@ -1674,15 +1674,16 @@ define i8** @constexpr() {
; CHECK: attributes #32 = { norecurse } ; CHECK: attributes #32 = { norecurse }
; CHECK: attributes #33 = { inaccessiblememonly } ; CHECK: attributes #33 = { inaccessiblememonly }
; CHECK: attributes #34 = { inaccessiblemem_or_argmemonly } ; CHECK: attributes #34 = { inaccessiblemem_or_argmemonly }
; CHECK: attributes #35 = { nounwind readnone } ; CHECK: attributes #35 = { nounwind readnone willreturn }
; CHECK: attributes #36 = { argmemonly nounwind readonly } ; CHECK: attributes #36 = { argmemonly nounwind readonly }
; CHECK: attributes #37 = { argmemonly nounwind } ; CHECK: attributes #37 = { argmemonly nounwind }
; CHECK: attributes #38 = { nounwind readonly } ; CHECK: attributes #38 = { nounwind readnone }
; CHECK: attributes #39 = { writeonly } ; CHECK: attributes #39 = { nounwind readonly }
; CHECK: attributes #40 = { speculatable } ; CHECK: attributes #40 = { writeonly }
; CHECK: attributes #41 = { inaccessiblemem_or_argmemonly nounwind } ; CHECK: attributes #41 = { speculatable }
; CHECK: attributes #42 = { builtin } ; CHECK: attributes #42 = { inaccessiblemem_or_argmemonly nounwind willreturn }
; CHECK: attributes #43 = { strictfp } ; CHECK: attributes #43 = { builtin }
; CHECK: attributes #44 = { strictfp }
;; Metadata ;; Metadata

View File

@ -1351,10 +1351,10 @@ exit:
; CHECK: select <2 x i1> <i1 true, i1 false>, <2 x i8> <i8 2, i8 3>, <2 x i8> <i8 3, i8 2> ; CHECK: select <2 x i1> <i1 true, i1 false>, <2 x i8> <i8 2, i8 3>, <2 x i8> <i8 3, i8 2>
call void @f.nobuiltin() builtin call void @f.nobuiltin() builtin
; CHECK: call void @f.nobuiltin() #42 ; CHECK: call void @f.nobuiltin() #43
call void @f.strictfp() strictfp call void @f.strictfp() strictfp
; CHECK: call void @f.strictfp() #43 ; CHECK: call void @f.strictfp() #44
call fastcc noalias i32* @f.noalias() noinline call fastcc noalias i32* @f.noalias() noinline
; CHECK: call fastcc noalias i32* @f.noalias() #12 ; CHECK: call fastcc noalias i32* @f.noalias() #12
@ -1719,10 +1719,10 @@ normal:
declare void @f.writeonly() writeonly declare void @f.writeonly() writeonly
; CHECK: declare void @f.writeonly() #40 ; CHECK: declare void @f.writeonly() #41
declare void @f.speculatable() speculatable declare void @f.speculatable() speculatable
; CHECK: declare void @f.speculatable() #41 ; CHECK: declare void @f.speculatable() #42
;; Constant Expressions ;; Constant Expressions
@ -1779,15 +1779,16 @@ declare void @byval_named_type(%named_type* byval(%named_type))
; CHECK: attributes #32 = { norecurse } ; CHECK: attributes #32 = { norecurse }
; CHECK: attributes #33 = { inaccessiblememonly } ; CHECK: attributes #33 = { inaccessiblememonly }
; CHECK: attributes #34 = { inaccessiblemem_or_argmemonly } ; CHECK: attributes #34 = { inaccessiblemem_or_argmemonly }
; CHECK: attributes #35 = { nounwind readnone } ; CHECK: attributes #35 = { nounwind readnone willreturn }
; CHECK: attributes #36 = { argmemonly nounwind readonly } ; CHECK: attributes #36 = { argmemonly nounwind readonly }
; CHECK: attributes #37 = { argmemonly nounwind } ; CHECK: attributes #37 = { argmemonly nounwind }
; CHECK: attributes #38 = { nounwind readonly } ; CHECK: attributes #38 = { nounwind readnone }
; CHECK: attributes #39 = { inaccessiblemem_or_argmemonly nounwind } ; CHECK: attributes #39 = { nounwind readonly }
; CHECK: attributes #40 = { writeonly } ; CHECK: attributes #40 = { inaccessiblemem_or_argmemonly nounwind willreturn }
; CHECK: attributes #41 = { speculatable } ; CHECK: attributes #41 = { writeonly }
; CHECK: attributes #42 = { builtin } ; CHECK: attributes #42 = { speculatable }
; CHECK: attributes #43 = { strictfp } ; CHECK: attributes #43 = { builtin }
; CHECK: attributes #44 = { strictfp }
;; Metadata ;; Metadata

View File

@ -98,7 +98,7 @@ define i32 addrspace(3)* @ret_constant_cast_group_gv_gep_to_flat_to_group() #1 {
ret i32 addrspace(3)* addrspacecast (i32 addrspace(4)* getelementptr ([256 x i32], [256 x i32] addrspace(4)* addrspacecast ([256 x i32] addrspace(3)* @lds.arr to [256 x i32] addrspace(4)*), i64 0, i64 8) to i32 addrspace(3)*) ret i32 addrspace(3)* addrspacecast (i32 addrspace(4)* getelementptr ([256 x i32], [256 x i32] addrspace(4)* addrspacecast ([256 x i32] addrspace(3)* @lds.arr to [256 x i32] addrspace(4)*), i64 0, i64 8) to i32 addrspace(3)*)
} }
; HSA: attributes #0 = { argmemonly nounwind } ; HSA: attributes #0 = { argmemonly nounwind willreturn }
; HSA: attributes #1 = { nounwind } ; HSA: attributes #1 = { nounwind }
; HSA: attributes #2 = { nounwind "amdgpu-queue-ptr" } ; HSA: attributes #2 = { nounwind "amdgpu-queue-ptr" }

View File

@ -69,5 +69,5 @@ define void @trap() {
ret void ret void
} }
; CHECK: attributes #0 = { nounwind readnone speculatable } ; CHECK: attributes #0 = { nounwind readnone speculatable willreturn }
; CHECK: attributes #1 = { cold noreturn nounwind } ; CHECK: attributes #1 = { cold noreturn nounwind }

View File

@ -92,11 +92,11 @@ declare void @use(i8* readonly)
declare void @useBool(i1) declare void @useBool(i1)
declare void @clobber(i8*) declare void @clobber(i8*)
; CHECK: Function Attrs: inaccessiblememonly nounwind speculatable{{$}} ; CHECK: Function Attrs: inaccessiblememonly nounwind speculatable willreturn{{$}}
; CHECK-NEXT: declare i8* @llvm.launder.invariant.group.p0i8(i8*) ; CHECK-NEXT: declare i8* @llvm.launder.invariant.group.p0i8(i8*)
declare i8* @llvm.launder.invariant.group.p0i8(i8*) declare i8* @llvm.launder.invariant.group.p0i8(i8*)
; CHECK: Function Attrs: nounwind readnone speculatable{{$}} ; CHECK: Function Attrs: nounwind readnone speculatable willreturn{{$}}
; CHECK-NEXT: declare i8* @llvm.strip.invariant.group.p0i8(i8*) ; CHECK-NEXT: declare i8* @llvm.strip.invariant.group.p0i8(i8*)
declare i8* @llvm.strip.invariant.group.p0i8(i8*) declare i8* @llvm.strip.invariant.group.p0i8(i8*)

View File

@ -39,7 +39,7 @@ bb2: ; preds = %bb1, %bb
declare void @llvm.dbg.value(metadata, metadata, metadata) nounwind readnone declare void @llvm.dbg.value(metadata, metadata, metadata) nounwind readnone
; CHECK: attributes #0 = { nounwind ssp } ; CHECK: attributes #0 = { nounwind ssp }
; CHECK: attributes #1 = { nounwind readnone speculatable } ; CHECK: attributes #1 = { nounwind readnone speculatable willreturn }
; CHECK: attributes #2 = { noinline nounwind ssp } ; CHECK: attributes #2 = { noinline nounwind ssp }
; CHECK: attributes [[NUW]] = { nounwind } ; CHECK: attributes [[NUW]] = { nounwind }

View File

@ -508,7 +508,7 @@ define noalias i8* @test23() nounwind uwtable ssp {
; CHECK-NEXT: store i8 97, i8* [[ARRAYIDX]], align 1 ; CHECK-NEXT: store i8 97, i8* [[ARRAYIDX]], align 1
; CHECK-NEXT: [[ARRAYIDX1:%.*]] = getelementptr inbounds [2 x i8], [2 x i8]* [[X]], i64 0, i64 1 ; CHECK-NEXT: [[ARRAYIDX1:%.*]] = getelementptr inbounds [2 x i8], [2 x i8]* [[X]], i64 0, i64 1
; CHECK-NEXT: store i8 0, i8* [[ARRAYIDX1]], align 1 ; CHECK-NEXT: store i8 0, i8* [[ARRAYIDX1]], align 1
; CHECK-NEXT: [[CALL:%.*]] = call i8* @strdup(i8* [[ARRAYIDX]]) #1 ; CHECK-NEXT: [[CALL:%.*]] = call i8* @strdup(i8* [[ARRAYIDX]]) #2
; CHECK-NEXT: ret i8* [[CALL]] ; CHECK-NEXT: ret i8* [[CALL]]
; ;
%x = alloca [2 x i8], align 1 %x = alloca [2 x i8], align 1
@ -546,7 +546,7 @@ define i8* @test25(i8* %p) nounwind {
; CHECK-NEXT: [[P_4:%.*]] = getelementptr i8, i8* [[P:%.*]], i64 4 ; CHECK-NEXT: [[P_4:%.*]] = getelementptr i8, i8* [[P:%.*]], i64 4
; CHECK-NEXT: [[TMP:%.*]] = load i8, i8* [[P_4]], align 1 ; CHECK-NEXT: [[TMP:%.*]] = load i8, i8* [[P_4]], align 1
; CHECK-NEXT: store i8 0, i8* [[P_4]], align 1 ; CHECK-NEXT: store i8 0, i8* [[P_4]], align 1
; CHECK-NEXT: [[Q:%.*]] = call i8* @strdup(i8* [[P]]) #4 ; CHECK-NEXT: [[Q:%.*]] = call i8* @strdup(i8* [[P]]) #5
; CHECK-NEXT: store i8 [[TMP]], i8* [[P_4]], align 1 ; CHECK-NEXT: store i8 [[TMP]], i8* [[P_4]], align 1
; CHECK-NEXT: ret i8* [[Q]] ; CHECK-NEXT: ret i8* [[Q]]
; ;

View File

@ -345,5 +345,5 @@ terminate:
; CHECK: attributes [[NUW]] = { nounwind } ; CHECK: attributes [[NUW]] = { nounwind }
; CHECK: attributes #1 = { nounwind readnone } ; CHECK: attributes #1 = { nounwind readnone }
; CHECK: attributes #2 = { ssp uwtable } ; CHECK: attributes #2 = { ssp uwtable }
; CHECK: attributes #3 = { argmemonly nounwind } ; CHECK: attributes #3 = { argmemonly nounwind willreturn }
; CHECK: attributes #4 = { noreturn nounwind } ; CHECK: attributes #4 = { noreturn nounwind }

View File

@ -32,7 +32,7 @@ entry:
; CHECK: ret void ; CHECK: ret void
; CHECK: } ; CHECK: }
attributes #0 = { nounwind argmemonly } attributes #0 = { nounwind argmemonly willreturn }
attributes #1 = { nounwind } attributes #1 = { nounwind }
attributes #2 = { nounwind uwtable } attributes #2 = { nounwind uwtable }

View File

@ -248,6 +248,6 @@ declare void @f1(%struct.big* nocapture sret)
declare void @f2(%struct.big*) declare void @f2(%struct.big*)
; CHECK: attributes [[$NUW]] = { nounwind } ; CHECK: attributes [[$NUW]] = { nounwind }
; CHECK: attributes #1 = { argmemonly nounwind } ; CHECK: attributes #1 = { argmemonly nounwind willreturn }
; CHECK: attributes #2 = { nounwind ssp } ; CHECK: attributes #2 = { nounwind ssp }
; CHECK: attributes #3 = { nounwind ssp uwtable } ; CHECK: attributes #3 = { nounwind ssp uwtable }

View File

@ -3070,5 +3070,5 @@ define void @test67(i8* %x) {
!5 = !{i32 2, !"Debug Info Version", i32 3} !5 = !{i32 2, !"Debug Info Version", i32 3}
; CHECK: attributes [[NUW]] = { nounwind } ; CHECK: attributes [[NUW]] = { nounwind }
; CHECK: attributes #1 = { nounwind readnone speculatable } ; CHECK: attributes #1 = { nounwind readnone speculatable willreturn }
; CHECK: ![[RELEASE]] = !{} ; CHECK: ![[RELEASE]] = !{}

View File

@ -105,7 +105,7 @@ declare void @NSLog(i8*, ...)
declare void @llvm.dbg.value(metadata, metadata, metadata) nounwind readnone declare void @llvm.dbg.value(metadata, metadata, metadata) nounwind readnone
; CHECK: attributes #0 = { ssp uwtable } ; CHECK: attributes #0 = { ssp uwtable }
; CHECK: attributes #1 = { nounwind readnone speculatable } ; CHECK: attributes #1 = { nounwind readnone speculatable willreturn }
; CHECK: attributes #2 = { nonlazybind } ; CHECK: attributes #2 = { nonlazybind }
; CHECK: attributes [[NUW]] = { nounwind } ; CHECK: attributes [[NUW]] = { nounwind }
; CHECK: attributes #4 = { noinline ssp uwtable } ; CHECK: attributes #4 = { noinline ssp uwtable }

View File

@ -821,5 +821,5 @@ entry:
; CHECK: attributes [[NUW]] = { nounwind } ; CHECK: attributes [[NUW]] = { nounwind }
; CHECK: attributes #1 = { argmemonly nounwind } ; CHECK: attributes #1 = { argmemonly nounwind willreturn }
; CHECK: attributes #2 = { nonlazybind } ; CHECK: attributes #2 = { nonlazybind }

View File

@ -173,5 +173,5 @@ define void @round_custom(i64* %a, i64* %b) {
; CHECK: declare <2 x double> @llvm.pow.v2f64(<2 x double>, <2 x double>) [[ATTR0]] ; CHECK: declare <2 x double> @llvm.pow.v2f64(<2 x double>, <2 x double>) [[ATTR0]]
; CHECK: declare <2 x double> @llvm.exp2.v2f64(<2 x double>) [[ATTR0]] ; CHECK: declare <2 x double> @llvm.exp2.v2f64(<2 x double>) [[ATTR0]]
; CHECK: attributes [[ATTR0]] = { nounwind readnone speculatable } ; CHECK: attributes [[ATTR0]] = { nounwind readnone speculatable willreturn }

View File

@ -12,7 +12,7 @@ declare double @llvm.experimental.constrained.sqrt.f64(double, metadata, metadat
; attached to the FP intrinsic. ; attached to the FP intrinsic.
; CHECK1: declare double @llvm.experimental.constrained.fadd.f64(double, double, metadata, metadata) #[[ATTR:[0-9]+]] ; CHECK1: declare double @llvm.experimental.constrained.fadd.f64(double, double, metadata, metadata) #[[ATTR:[0-9]+]]
; CHECK1: declare double @llvm.experimental.constrained.sqrt.f64(double, metadata, metadata) #[[ATTR]] ; CHECK1: declare double @llvm.experimental.constrained.sqrt.f64(double, metadata, metadata) #[[ATTR]]
; CHECK1: attributes #[[ATTR]] = { inaccessiblememonly nounwind } ; CHECK1: attributes #[[ATTR]] = { inaccessiblememonly nounwind willreturn }
; Note: FP exceptions aren't usually caught through normal unwind mechanisms, ; Note: FP exceptions aren't usually caught through normal unwind mechanisms,
; but we may want to revisit this for asynchronous exception handling. ; but we may want to revisit this for asynchronous exception handling.
define double @f1(double %a, double %b) { define double @f1(double %a, double %b) {