Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Save denismerigoux/1f9659985ef09a7596b1b656dd8c1b65 to your computer and use it in GitHub Desktop.
Save denismerigoux/1f9659985ef09a7596b1b656dd8c1b65 to your computer and use it in GitHub Desktop.
Effect of early sealing
// When sealing ebb1 before creating the v4 instruction
function ""() {
ebb0:
v0 = iconst.i32 1
v1 = iconst.i32 2
v2 = iadd v0, v1
brnz v1, ebb1
v3 = iadd v0, v2
ebb1:
v4 = iadd.i32 v0, v1
}
// When sealing ebb1 after creating the instruction
function ""() {
ebb0:
v0 = iconst.i32 1
v1 = iconst.i32 2
v2 = iadd v0, v1
brnz v1, ebb1
v3 = iadd v0, v2
ebb1(v4: i32, v5: i32):
v4 -> v0
v5 -> v1
v6 = iadd.i32 v4, v5
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment