blob: c3695a31d18f63a5d13caf3adf519c8cb161388b [file] [log] [blame]
; NOTE: Assertions have been autogenerated by utils/update_test_checks.py UTC_ARGS: --version 5
; RUN: opt -S -passes=ipsccp < %s | FileCheck %s
; https://github.com/llvm/llvm-project/issues/59661
define i32 @bar() {
; CHECK-LABEL: define i32 @bar() {
; CHECK-NEXT: [[ENTRY:.*:]]
; CHECK-NEXT: [[CALL:%.*]] = call i32 @foo()
; CHECK-NEXT: ret i32 0
;
entry:
%call = call i32 @foo()
ret i32 0
}
define internal i32 @foo() {
; CHECK-LABEL: define internal i32 @foo() {
; CHECK-NEXT: [[ENTRY:.*:]]
; CHECK-NEXT: [[ARST:%.*]] = call ptr @llvm.ssa.copy.p0(ptr @foo)
; CHECK-NEXT: ret i32 0
;
entry:
%arst = call ptr @llvm.ssa.copy.p0(ptr @foo)
ret i32 0
}
declare ptr @llvm.ssa.copy.p0(ptr) #0
attributes #0 = { nocallback nofree nosync nounwind speculatable willreturn memory(none) }