Implement scaffolding for lvalues. Implement block vardecl lvalues.
This allows us to translate: int func() { register int X; { int Y; return 1+X+Y; } } into: define i32 @func() { entry: %X = alloca i32 ; <i32*> [#uses=1] %Y = alloca i32 ; <i32*> [#uses=1] %allocapt = bitcast i32 undef to i32 ; <i32> [#uses=0] %tmp = load i32* %X ; <i32> [#uses=1] %tmp1 = add i32 1, %tmp ; <i32> [#uses=1] %tmp2 = load i32* %Y ; <i32> [#uses=1] %tmp3 = add i32 %tmp1, %tmp2 ; <i32> [#uses=1] ret i32 %tmp3 ; No predecessors! ret i32 undef } llvm-svn: 39555
Loading
Please register or sign in to comment