; Make sure calls to the objc intrinsics are translated to calls in to the
; runtime
-declare i8* @foo()
+declare ptr @foo()
declare i32 @__gxx_personality_v0(...)
-define i8* @test_objc_autorelease(i8* %arg0) {
+define ptr @test_objc_autorelease(ptr %arg0) {
; CHECK-LABEL: test_objc_autorelease
; CHECK-NEXT: entry
-; CHECK-NEXT: %0 = notail call i8* @objc_autorelease(i8* %arg0)
-; CHECK-NEXT: ret i8* %0
+; CHECK-NEXT: %0 = notail call ptr @objc_autorelease(ptr %arg0)
+; CHECK-NEXT: ret ptr %0
entry:
- %0 = call i8* @llvm.objc.autorelease(i8* %arg0)
- ret i8* %0
+ %0 = call ptr @llvm.objc.autorelease(ptr %arg0)
+ ret ptr %0
}
-define void @test_objc_autoreleasePoolPop(i8* %arg0) {
+define void @test_objc_autoreleasePoolPop(ptr %arg0) {
; CHECK-LABEL: test_objc_autoreleasePoolPop
; CHECK-NEXT: entry
-; CHECK-NEXT: call void @objc_autoreleasePoolPop(i8* %arg0)
+; CHECK-NEXT: call void @objc_autoreleasePoolPop(ptr %arg0)
; CHECK-NEXT: ret void
entry:
- call void @llvm.objc.autoreleasePoolPop(i8* %arg0)
+ call void @llvm.objc.autoreleasePoolPop(ptr %arg0)
ret void
}
-define i8* @test_objc_autoreleasePoolPush() {
+define ptr @test_objc_autoreleasePoolPush() {
; CHECK-LABEL: test_objc_autoreleasePoolPush
; CHECK-NEXT: entry
-; CHECK-NEXT: %0 = call i8* @objc_autoreleasePoolPush()
-; CHECK-NEXT: ret i8* %0
+; CHECK-NEXT: %0 = call ptr @objc_autoreleasePoolPush()
+; CHECK-NEXT: ret ptr %0
entry:
- %0 = call i8* @llvm.objc.autoreleasePoolPush()
- ret i8* %0
+ %0 = call ptr @llvm.objc.autoreleasePoolPush()
+ ret ptr %0
}
-define i8* @test_objc_autoreleaseReturnValue(i8* %arg0) {
+define ptr @test_objc_autoreleaseReturnValue(ptr %arg0) {
; CHECK-LABEL: test_objc_autoreleaseReturnValue
; CHECK-NEXT: entry
-; CHECK-NEXT: %0 = tail call i8* @objc_autoreleaseReturnValue(i8* %arg0)
-; CHECK-NEXT: ret i8* %0
+; CHECK-NEXT: %0 = tail call ptr @objc_autoreleaseReturnValue(ptr %arg0)
+; CHECK-NEXT: ret ptr %0
entry:
- %0 = call i8* @llvm.objc.autoreleaseReturnValue(i8* %arg0)
- ret i8* %0
+ %0 = call ptr @llvm.objc.autoreleaseReturnValue(ptr %arg0)
+ ret ptr %0
}
-define void @test_objc_copyWeak(i8** %arg0, i8** %arg1) {
+define void @test_objc_copyWeak(ptr %arg0, ptr %arg1) {
; CHECK-LABEL: test_objc_copyWeak
; CHECK-NEXT: entry
-; CHECK-NEXT: call void @objc_copyWeak(i8** %arg0, i8** %arg1)
+; CHECK-NEXT: call void @objc_copyWeak(ptr %arg0, ptr %arg1)
; CHECK-NEXT: ret void
entry:
- call void @llvm.objc.copyWeak(i8** %arg0, i8** %arg1)
+ call void @llvm.objc.copyWeak(ptr %arg0, ptr %arg1)
ret void
}
-define void @test_objc_destroyWeak(i8** %arg0) {
+define void @test_objc_destroyWeak(ptr %arg0) {
; CHECK-LABEL: test_objc_destroyWeak
; CHECK-NEXT: entry
-; CHECK-NEXT: call void @objc_destroyWeak(i8** %arg0)
+; CHECK-NEXT: call void @objc_destroyWeak(ptr %arg0)
; CHECK-NEXT: ret void
entry:
- call void @llvm.objc.destroyWeak(i8** %arg0)
+ call void @llvm.objc.destroyWeak(ptr %arg0)
ret void
}
-define i8* @test_objc_initWeak(i8** %arg0, i8* %arg1) {
+define ptr @test_objc_initWeak(ptr %arg0, ptr %arg1) {
; CHECK-LABEL: test_objc_initWeak
; CHECK-NEXT: entry
-; CHECK-NEXT: %0 = call i8* @objc_initWeak(i8** %arg0, i8* %arg1)
-; CHECK-NEXT: ret i8* %0
+; CHECK-NEXT: %0 = call ptr @objc_initWeak(ptr %arg0, ptr %arg1)
+; CHECK-NEXT: ret ptr %0
entry:
- %0 = call i8* @llvm.objc.initWeak(i8** %arg0, i8* %arg1)
- ret i8* %0
+ %0 = call ptr @llvm.objc.initWeak(ptr %arg0, ptr %arg1)
+ ret ptr %0
}
-define i8* @test_objc_loadWeak(i8** %arg0) {
+define ptr @test_objc_loadWeak(ptr %arg0) {
; CHECK-LABEL: test_objc_loadWeak
; CHECK-NEXT: entry
-; CHECK-NEXT: %0 = call i8* @objc_loadWeak(i8** %arg0)
-; CHECK-NEXT: ret i8* %0
+; CHECK-NEXT: %0 = call ptr @objc_loadWeak(ptr %arg0)
+; CHECK-NEXT: ret ptr %0
entry:
- %0 = call i8* @llvm.objc.loadWeak(i8** %arg0)
- ret i8* %0
+ %0 = call ptr @llvm.objc.loadWeak(ptr %arg0)
+ ret ptr %0
}
-define i8* @test_objc_loadWeakRetained(i8** %arg0) {
+define ptr @test_objc_loadWeakRetained(ptr %arg0) {
; CHECK-LABEL: test_objc_loadWeakRetained
; CHECK-NEXT: entry
-; CHECK-NEXT: %0 = call i8* @objc_loadWeakRetained(i8** %arg0)
-; CHECK-NEXT: ret i8* %0
+; CHECK-NEXT: %0 = call ptr @objc_loadWeakRetained(ptr %arg0)
+; CHECK-NEXT: ret ptr %0
entry:
- %0 = call i8* @llvm.objc.loadWeakRetained(i8** %arg0)
- ret i8* %0
+ %0 = call ptr @llvm.objc.loadWeakRetained(ptr %arg0)
+ ret ptr %0
}
-define void @test_objc_moveWeak(i8** %arg0, i8** %arg1) {
+define void @test_objc_moveWeak(ptr %arg0, ptr %arg1) {
; CHECK-LABEL: test_objc_moveWeak
; CHECK-NEXT: entry
-; CHECK-NEXT: call void @objc_moveWeak(i8** %arg0, i8** %arg1)
+; CHECK-NEXT: call void @objc_moveWeak(ptr %arg0, ptr %arg1)
; CHECK-NEXT: ret void
entry:
- call void @llvm.objc.moveWeak(i8** %arg0, i8** %arg1)
+ call void @llvm.objc.moveWeak(ptr %arg0, ptr %arg1)
ret void
}
-define void @test_objc_release(i8* %arg0) {
+define void @test_objc_release(ptr %arg0) {
; CHECK-LABEL: test_objc_release
; CHECK-NEXT: entry
-; CHECK-NEXT: call void @objc_release(i8* %arg0)
+; CHECK-NEXT: call void @objc_release(ptr %arg0)
; CHECK-NEXT: ret void
entry:
- call void @llvm.objc.release(i8* %arg0)
+ call void @llvm.objc.release(ptr %arg0)
ret void
}
-define i8* @test_objc_retain(i8* %arg0) {
+define ptr @test_objc_retain(ptr %arg0) {
; CHECK-LABEL: test_objc_retain
; CHECK-NEXT: entry
-; CHECK-NEXT: %0 = tail call i8* @objc_retain(i8* %arg0)
-; CHECK-NEXT: ret i8* %0
+; CHECK-NEXT: %0 = tail call ptr @objc_retain(ptr %arg0)
+; CHECK-NEXT: ret ptr %0
entry:
- %0 = call i8* @llvm.objc.retain(i8* %arg0)
- ret i8* %0
+ %0 = call ptr @llvm.objc.retain(ptr %arg0)
+ ret ptr %0
}
-define i8* @test_objc_retainAutorelease(i8* %arg0) {
+define ptr @test_objc_retainAutorelease(ptr %arg0) {
; CHECK-LABEL: test_objc_retainAutorelease
; CHECK-NEXT: entry
-; CHECK-NEXT: %0 = call i8* @objc_retainAutorelease(i8* %arg0)
-; CHECK-NEXT: ret i8* %0
+; CHECK-NEXT: %0 = call ptr @objc_retainAutorelease(ptr %arg0)
+; CHECK-NEXT: ret ptr %0
entry:
- %0 = call i8* @llvm.objc.retainAutorelease(i8* %arg0)
- ret i8* %0
+ %0 = call ptr @llvm.objc.retainAutorelease(ptr %arg0)
+ ret ptr %0
}
-define i8* @test_objc_retainAutoreleaseReturnValue(i8* %arg0) {
+define ptr @test_objc_retainAutoreleaseReturnValue(ptr %arg0) {
; CHECK-LABEL: test_objc_retainAutoreleaseReturnValue
; CHECK-NEXT: entry
-; CHECK-NEXT: %0 = tail call i8* @objc_retainAutoreleaseReturnValue(i8* %arg0)
-; CHECK-NEXT: ret i8* %0
+; CHECK-NEXT: %0 = tail call ptr @objc_retainAutoreleaseReturnValue(ptr %arg0)
+; CHECK-NEXT: ret ptr %0
entry:
- %0 = tail call i8* @llvm.objc.retainAutoreleaseReturnValue(i8* %arg0)
- ret i8* %0
+ %0 = tail call ptr @llvm.objc.retainAutoreleaseReturnValue(ptr %arg0)
+ ret ptr %0
}
-define i8* @test_objc_retainAutoreleasedReturnValue(i8* %arg0) {
+define ptr @test_objc_retainAutoreleasedReturnValue(ptr %arg0) {
; CHECK-LABEL: test_objc_retainAutoreleasedReturnValue
; CHECK-NEXT: entry
-; CHECK-NEXT: %0 = tail call i8* @objc_retainAutoreleasedReturnValue(i8* %arg0)
-; CHECK-NEXT: ret i8* %0
+; CHECK-NEXT: %0 = tail call ptr @objc_retainAutoreleasedReturnValue(ptr %arg0)
+; CHECK-NEXT: ret ptr %0
entry:
- %0 = call i8* @llvm.objc.retainAutoreleasedReturnValue(i8* %arg0)
- ret i8* %0
+ %0 = call ptr @llvm.objc.retainAutoreleasedReturnValue(ptr %arg0)
+ ret ptr %0
}
define void @test_objc_retainAutoreleasedReturnValue_bundle() {
; CHECK-LABEL: test_objc_retainAutoreleasedReturnValue_bundle(
-; CHECK-NEXT: call i8* @foo() [ "clang.arc.attachedcall"(i8* (i8*)* @objc_retainAutoreleasedReturnValue) ]
- call i8* @foo() [ "clang.arc.attachedcall"(i8* (i8*)* @llvm.objc.retainAutoreleasedReturnValue) ]
+; CHECK-NEXT: call ptr @foo() [ "clang.arc.attachedcall"(ptr @objc_retainAutoreleasedReturnValue) ]
+ call ptr @foo() [ "clang.arc.attachedcall"(ptr @llvm.objc.retainAutoreleasedReturnValue) ]
ret void
}
-define void @test_objc_retainAutoreleasedReturnValue_bundle_invoke() personality i8* bitcast (i32 (...)* @__gxx_personality_v0 to i8*) {
+define void @test_objc_retainAutoreleasedReturnValue_bundle_invoke() personality ptr @__gxx_personality_v0 {
; CHECK-LABEL: test_objc_retainAutoreleasedReturnValue_bundle_invoke(
; CHECK-NEXT: entry
-; CHECK-NEXT: invoke i8* @foo() [ "clang.arc.attachedcall"(i8* (i8*)* @objc_retainAutoreleasedReturnValue) ]
+; CHECK-NEXT: invoke ptr @foo() [ "clang.arc.attachedcall"(ptr @objc_retainAutoreleasedReturnValue) ]
entry:
- invoke i8* @foo() [ "clang.arc.attachedcall"(i8* (i8*)* @llvm.objc.retainAutoreleasedReturnValue) ]
+ invoke ptr @foo() [ "clang.arc.attachedcall"(ptr @llvm.objc.retainAutoreleasedReturnValue) ]
to label %invoke.cont unwind label %lpad
invoke.cont:
ret void
lpad:
- %1 = landingpad { i8*, i32 }
+ %1 = landingpad { ptr, i32 }
cleanup
- resume { i8*, i32 } %1
+ resume { ptr, i32 } %1
}
-define i8* @test_objc_retainBlock(i8* %arg0) {
+define ptr @test_objc_retainBlock(ptr %arg0) {
; CHECK-LABEL: test_objc_retainBlock
; CHECK-NEXT: entry
-; CHECK-NEXT: %0 = call i8* @objc_retainBlock(i8* %arg0)
-; CHECK-NEXT: ret i8* %0
+; CHECK-NEXT: %0 = call ptr @objc_retainBlock(ptr %arg0)
+; CHECK-NEXT: ret ptr %0
entry:
- %0 = call i8* @llvm.objc.retainBlock(i8* %arg0)
- ret i8* %0
+ %0 = call ptr @llvm.objc.retainBlock(ptr %arg0)
+ ret ptr %0
}
-define void @test_objc_storeStrong(i8** %arg0, i8* %arg1) {
+define void @test_objc_storeStrong(ptr %arg0, ptr %arg1) {
; CHECK-LABEL: test_objc_storeStrong
; CHECK-NEXT: entry
-; CHECK-NEXT: call void @objc_storeStrong(i8** %arg0, i8* %arg1)
+; CHECK-NEXT: call void @objc_storeStrong(ptr %arg0, ptr %arg1)
; CHECK-NEXT: ret void
entry:
- call void @llvm.objc.storeStrong(i8** %arg0, i8* %arg1)
+ call void @llvm.objc.storeStrong(ptr %arg0, ptr %arg1)
ret void
}
-define i8* @test_objc_storeWeak(i8** %arg0, i8* %arg1) {
+define ptr @test_objc_storeWeak(ptr %arg0, ptr %arg1) {
; CHECK-LABEL: test_objc_storeWeak
; CHECK-NEXT: entry
-; CHECK-NEXT: %0 = call i8* @objc_storeWeak(i8** %arg0, i8* %arg1)
-; CHECK-NEXT: ret i8* %0
+; CHECK-NEXT: %0 = call ptr @objc_storeWeak(ptr %arg0, ptr %arg1)
+; CHECK-NEXT: ret ptr %0
entry:
- %0 = call i8* @llvm.objc.storeWeak(i8** %arg0, i8* %arg1)
- ret i8* %0
+ %0 = call ptr @llvm.objc.storeWeak(ptr %arg0, ptr %arg1)
+ ret ptr %0
}
-define i8* @test_objc_unsafeClaimAutoreleasedReturnValue(i8* %arg0) {
+define ptr @test_objc_unsafeClaimAutoreleasedReturnValue(ptr %arg0) {
; CHECK-LABEL: test_objc_unsafeClaimAutoreleasedReturnValue
; CHECK-NEXT: entry
-; CHECK-NEXT: %0 = tail call i8* @objc_unsafeClaimAutoreleasedReturnValue(i8* %arg0)
-; CHECK-NEXT: ret i8* %0
+; CHECK-NEXT: %0 = tail call ptr @objc_unsafeClaimAutoreleasedReturnValue(ptr %arg0)
+; CHECK-NEXT: ret ptr %0
entry:
- %0 = call i8* @llvm.objc.unsafeClaimAutoreleasedReturnValue(i8* %arg0)
- ret i8* %0
+ %0 = call ptr @llvm.objc.unsafeClaimAutoreleasedReturnValue(ptr %arg0)
+ ret ptr %0
}
define void @test_objc_unsafeClaimAutoreleasedReturnValue_bundle() {
; CHECK-LABEL: test_objc_unsafeClaimAutoreleasedReturnValue_bundle(
-; CHECK-NEXT: call i8* @foo() [ "clang.arc.attachedcall"(i8* (i8*)* @objc_unsafeClaimAutoreleasedReturnValue) ]
- call i8* @foo() [ "clang.arc.attachedcall"(i8* (i8*)* @llvm.objc.unsafeClaimAutoreleasedReturnValue) ]
+; CHECK-NEXT: call ptr @foo() [ "clang.arc.attachedcall"(ptr @objc_unsafeClaimAutoreleasedReturnValue) ]
+ call ptr @foo() [ "clang.arc.attachedcall"(ptr @llvm.objc.unsafeClaimAutoreleasedReturnValue) ]
ret void
}
-define i8* @test_objc_retainedObject(i8* %arg0) {
+define ptr @test_objc_retainedObject(ptr %arg0) {
; CHECK-LABEL: test_objc_retainedObject
; CHECK-NEXT: entry
-; CHECK-NEXT: %0 = call i8* @objc_retainedObject(i8* %arg0)
-; CHECK-NEXT: ret i8* %0
+; CHECK-NEXT: %0 = call ptr @objc_retainedObject(ptr %arg0)
+; CHECK-NEXT: ret ptr %0
entry:
- %0 = call i8* @llvm.objc.retainedObject(i8* %arg0)
- ret i8* %0
+ %0 = call ptr @llvm.objc.retainedObject(ptr %arg0)
+ ret ptr %0
}
-define i8* @test_objc_unretainedObject(i8* %arg0) {
+define ptr @test_objc_unretainedObject(ptr %arg0) {
; CHECK-LABEL: test_objc_unretainedObject
; CHECK-NEXT: entry
-; CHECK-NEXT: %0 = call i8* @objc_unretainedObject(i8* %arg0)
-; CHECK-NEXT: ret i8* %0
+; CHECK-NEXT: %0 = call ptr @objc_unretainedObject(ptr %arg0)
+; CHECK-NEXT: ret ptr %0
entry:
- %0 = call i8* @llvm.objc.unretainedObject(i8* %arg0)
- ret i8* %0
+ %0 = call ptr @llvm.objc.unretainedObject(ptr %arg0)
+ ret ptr %0
}
-define i8* @test_objc_unretainedPointer(i8* %arg0) {
+define ptr @test_objc_unretainedPointer(ptr %arg0) {
; CHECK-LABEL: test_objc_unretainedPointer
; CHECK-NEXT: entry
-; CHECK-NEXT: %0 = call i8* @objc_unretainedPointer(i8* %arg0)
-; CHECK-NEXT: ret i8* %0
+; CHECK-NEXT: %0 = call ptr @objc_unretainedPointer(ptr %arg0)
+; CHECK-NEXT: ret ptr %0
entry:
- %0 = call i8* @llvm.objc.unretainedPointer(i8* %arg0)
- ret i8* %0
+ %0 = call ptr @llvm.objc.unretainedPointer(ptr %arg0)
+ ret ptr %0
}
-define i8* @test_objc_retain_autorelease(i8* %arg0) {
+define ptr @test_objc_retain_autorelease(ptr %arg0) {
; CHECK-LABEL: test_objc_retain_autorelease
; CHECK-NEXT: entry
-; CHECK-NEXT: %0 = call i8* @objc_retain_autorelease(i8* %arg0)
-; CHECK-NEXT: ret i8* %0
+; CHECK-NEXT: %0 = call ptr @objc_retain_autorelease(ptr %arg0)
+; CHECK-NEXT: ret ptr %0
entry:
- %0 = call i8* @llvm.objc.retain.autorelease(i8* %arg0)
- ret i8* %0
+ %0 = call ptr @llvm.objc.retain.autorelease(ptr %arg0)
+ ret ptr %0
}
-define i32 @test_objc_sync_enter(i8* %arg0) {
+define i32 @test_objc_sync_enter(ptr %arg0) {
; CHECK-LABEL: test_objc_sync_enter
; CHECK-NEXT: entry
-; CHECK-NEXT: %0 = call i32 @objc_sync_enter(i8* %arg0)
+; CHECK-NEXT: %0 = call i32 @objc_sync_enter(ptr %arg0)
; CHECK-NEXT: ret i32 %0
entry:
- %0 = call i32 @llvm.objc.sync.enter(i8* %arg0)
+ %0 = call i32 @llvm.objc.sync.enter(ptr %arg0)
ret i32 %0
}
-define i32 @test_objc_sync_exit(i8* %arg0) {
+define i32 @test_objc_sync_exit(ptr %arg0) {
; CHECK-LABEL: test_objc_sync_exit
; CHECK-NEXT: entry
-; CHECK-NEXT: %0 = call i32 @objc_sync_exit(i8* %arg0)
+; CHECK-NEXT: %0 = call i32 @objc_sync_exit(ptr %arg0)
; CHECK-NEXT: ret i32 %0
entry:
- %0 = call i32 @llvm.objc.sync.exit(i8* %arg0)
+ %0 = call i32 @llvm.objc.sync.exit(ptr %arg0)
ret i32 %0
}
-declare i8* @llvm.objc.autorelease(i8*)
-declare void @llvm.objc.autoreleasePoolPop(i8*)
-declare i8* @llvm.objc.autoreleasePoolPush()
-declare i8* @llvm.objc.autoreleaseReturnValue(i8*)
-declare void @llvm.objc.copyWeak(i8**, i8**)
-declare void @llvm.objc.destroyWeak(i8**)
-declare extern_weak i8* @llvm.objc.initWeak(i8**, i8*)
-declare i8* @llvm.objc.loadWeak(i8**)
-declare i8* @llvm.objc.loadWeakRetained(i8**)
-declare void @llvm.objc.moveWeak(i8**, i8**)
-declare void @llvm.objc.release(i8*)
-declare i8* @llvm.objc.retain(i8*)
-declare i8* @llvm.objc.retainAutorelease(i8*)
-declare i8* @llvm.objc.retainAutoreleaseReturnValue(i8*)
-declare i8* @llvm.objc.retainAutoreleasedReturnValue(i8*)
-declare i8* @llvm.objc.retainBlock(i8*)
-declare void @llvm.objc.storeStrong(i8**, i8*)
-declare i8* @llvm.objc.storeWeak(i8**, i8*)
-declare i8* @llvm.objc.unsafeClaimAutoreleasedReturnValue(i8*)
-declare i8* @llvm.objc.retainedObject(i8*)
-declare i8* @llvm.objc.unretainedObject(i8*)
-declare i8* @llvm.objc.unretainedPointer(i8*)
-declare i8* @llvm.objc.retain.autorelease(i8*)
-declare i32 @llvm.objc.sync.enter(i8*)
-declare i32 @llvm.objc.sync.exit(i8*)
+declare ptr @llvm.objc.autorelease(ptr)
+declare void @llvm.objc.autoreleasePoolPop(ptr)
+declare ptr @llvm.objc.autoreleasePoolPush()
+declare ptr @llvm.objc.autoreleaseReturnValue(ptr)
+declare void @llvm.objc.copyWeak(ptr, ptr)
+declare void @llvm.objc.destroyWeak(ptr)
+declare extern_weak ptr @llvm.objc.initWeak(ptr, ptr)
+declare ptr @llvm.objc.loadWeak(ptr)
+declare ptr @llvm.objc.loadWeakRetained(ptr)
+declare void @llvm.objc.moveWeak(ptr, ptr)
+declare void @llvm.objc.release(ptr)
+declare ptr @llvm.objc.retain(ptr)
+declare ptr @llvm.objc.retainAutorelease(ptr)
+declare ptr @llvm.objc.retainAutoreleaseReturnValue(ptr)
+declare ptr @llvm.objc.retainAutoreleasedReturnValue(ptr)
+declare ptr @llvm.objc.retainBlock(ptr)
+declare void @llvm.objc.storeStrong(ptr, ptr)
+declare ptr @llvm.objc.storeWeak(ptr, ptr)
+declare ptr @llvm.objc.unsafeClaimAutoreleasedReturnValue(ptr)
+declare ptr @llvm.objc.retainedObject(ptr)
+declare ptr @llvm.objc.unretainedObject(ptr)
+declare ptr @llvm.objc.unretainedPointer(ptr)
+declare ptr @llvm.objc.retain.autorelease(ptr)
+declare i32 @llvm.objc.sync.enter(ptr)
+declare i32 @llvm.objc.sync.exit(ptr)
attributes #0 = { nounwind }
-; CHECK: declare i8* @objc_autorelease(i8*)
-; CHECK: declare void @objc_autoreleasePoolPop(i8*)
-; CHECK: declare i8* @objc_autoreleasePoolPush()
-; CHECK: declare i8* @objc_autoreleaseReturnValue(i8*)
-; CHECK: declare void @objc_copyWeak(i8**, i8**)
-; CHECK: declare void @objc_destroyWeak(i8**)
-; CHECK: declare extern_weak i8* @objc_initWeak(i8**, i8*)
-; CHECK: declare i8* @objc_loadWeak(i8**)
-; CHECK: declare i8* @objc_loadWeakRetained(i8**)
-; CHECK: declare void @objc_moveWeak(i8**, i8**)
-; CHECK: declare void @objc_release(i8*) [[NLB:#[0-9]+]]
-; CHECK: declare i8* @objc_retain(i8*) [[NLB]]
-; CHECK: declare i8* @objc_retainAutorelease(i8*)
-; CHECK: declare i8* @objc_retainAutoreleaseReturnValue(i8*)
-; CHECK: declare i8* @objc_retainAutoreleasedReturnValue(i8*)
-; CHECK: declare i8* @objc_retainBlock(i8*)
-; CHECK: declare void @objc_storeStrong(i8**, i8*)
-; CHECK: declare i8* @objc_storeWeak(i8**, i8*)
-; CHECK: declare i8* @objc_unsafeClaimAutoreleasedReturnValue(i8*)
-; CHECK: declare i8* @objc_retainedObject(i8*)
-; CHECK: declare i8* @objc_unretainedObject(i8*)
-; CHECK: declare i8* @objc_unretainedPointer(i8*)
-; CHECK: declare i8* @objc_retain_autorelease(i8*)
-; CHECK: declare i32 @objc_sync_enter(i8*)
-; CHECK: declare i32 @objc_sync_exit(i8*)
+; CHECK: declare ptr @objc_autorelease(ptr)
+; CHECK: declare void @objc_autoreleasePoolPop(ptr)
+; CHECK: declare ptr @objc_autoreleasePoolPush()
+; CHECK: declare ptr @objc_autoreleaseReturnValue(ptr)
+; CHECK: declare void @objc_copyWeak(ptr, ptr)
+; CHECK: declare void @objc_destroyWeak(ptr)
+; CHECK: declare extern_weak ptr @objc_initWeak(ptr, ptr)
+; CHECK: declare ptr @objc_loadWeak(ptr)
+; CHECK: declare ptr @objc_loadWeakRetained(ptr)
+; CHECK: declare void @objc_moveWeak(ptr, ptr)
+; CHECK: declare void @objc_release(ptr) [[NLB:#[0-9]+]]
+; CHECK: declare ptr @objc_retain(ptr) [[NLB]]
+; CHECK: declare ptr @objc_retainAutorelease(ptr)
+; CHECK: declare ptr @objc_retainAutoreleaseReturnValue(ptr)
+; CHECK: declare ptr @objc_retainAutoreleasedReturnValue(ptr)
+; CHECK: declare ptr @objc_retainBlock(ptr)
+; CHECK: declare void @objc_storeStrong(ptr, ptr)
+; CHECK: declare ptr @objc_storeWeak(ptr, ptr)
+; CHECK: declare ptr @objc_unsafeClaimAutoreleasedReturnValue(ptr)
+; CHECK: declare ptr @objc_retainedObject(ptr)
+; CHECK: declare ptr @objc_unretainedObject(ptr)
+; CHECK: declare ptr @objc_unretainedPointer(ptr)
+; CHECK: declare ptr @objc_retain_autorelease(ptr)
+; CHECK: declare i32 @objc_sync_enter(ptr)
+; CHECK: declare i32 @objc_sync_exit(ptr)
; CHECK: attributes #0 = { nounwind }
; CHECK: attributes [[NLB]] = { nonlazybind }