1
0
mirror of https://github.com/RPCS3/llvm-mirror.git synced 2024-11-24 11:42:57 +01:00
llvm-mirror/test/Transforms/ObjCARC/weak-contract.ll
Eric Christopher a62270de2c Revert "Temporarily Revert "Add basic loop fusion pass.""
The reversion apparently deleted the test/Transforms directory.

Will be re-reverting again.

llvm-svn: 358552
2019-04-17 04:52:47 +00:00

15 lines
373 B
LLVM

; RUN: opt -objc-arc-contract -S < %s | FileCheck %s
declare i8* @llvm.objc.initWeak(i8**, i8*)
; Convert objc_initWeak(p, null) to *p = null.
; CHECK: define i8* @test0(i8** %p) {
; CHECK-NEXT: store i8* null, i8** %p
; CHECK-NEXT: ret i8* null
; CHECK-NEXT: }
define i8* @test0(i8** %p) {
%t = call i8* @llvm.objc.initWeak(i8** %p, i8* null)
ret i8* %t
}