Update ir examples

This commit is contained in:
Chunmyong Park
2020-06-14 12:58:28 +00:00
parent 1526873f41
commit 833f26b013
134 changed files with 298 additions and 10 deletions

View File

@@ -6,6 +6,8 @@ init:
block b0:
%b0:p0:i32:len
%b0:p1:i32*:a
j b2(0:i32, 0:i32)
block b2:
@@ -37,6 +39,7 @@ init:
block b0:
%b0:p0:f64:a
%b0:i0:f64 = typecast 0:i32 to f64
%b0:i1:u1 = cmp lt %b0:p0:f64 %b0:i0:f64
br %b0:i1:u1, b1(), b2()
@@ -60,6 +63,8 @@ init:
block b0:
%b0:p0:f64:a
%b0:p1:f64:b
%b0:i0:u1 = cmp gt %b0:p0:f64 %b0:p1:f64
br %b0:i0:u1, b1(), b2()
@@ -81,6 +86,10 @@ init:
block b0:
%b0:p0:f64:a
%b0:p1:f64:b
%b0:p2:f64:rel_tol
%b0:p3:f64:abs_tol
%b0:i0:f64 = sub %b0:p0:f64 %b0:p1:f64
%b0:i1:f64 = call @custom_abs:[ret:f64 params:(f64)]*(%b0:i0:f64)
%b0:i2:f64 = call @custom_abs:[ret:f64 params:(f64)]*(%b0:p0:f64)