-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
9 changed files
with
180 additions
and
7 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
|
||
global @x = i32 zero | ||
const @y = i32 0x20202020 | ||
type $z = { i32, float } | ||
global @array = [ i32; 3 ] zero | ||
global @arrarr = [ [float ;3]; 4] zero | ||
type $struct = { i32, [float; 3] } | ||
global @s = [$struct ; 2] zero | ||
|
||
fn @function(i32) -> i32 { | ||
|
||
^entry(i32 %0): | ||
%ptr0 = getelemptr [$struct;2], @s, i32 zero, i32 0x00 | ||
%val0 = load i32, %ptr0 | ||
%cond = icmp.sle i32 %0, i32 1234 | ||
br i1 %cond, ^ret(i32 0x01, float 0x123), ^else(i32 %0) | ||
|
||
^else(i32 %1): | ||
%2 = sub i32 %1, i32 0x01 | ||
%3 = sub i32 %1, i32 0x02 | ||
%4 = call i32 @function(i32 %2) | ||
%5 = call i32 @function(i32 %3) | ||
%6 = add i32 %4, i32 %5 | ||
jump ^ret(i32 %6, float 0x1234) | ||
|
||
^ret(i32 %result, float %123): | ||
ret i32 %result | ||
} |
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters