Pseudocode: don't write full label name when jump on it

This commit is contained in:
Svetlana Isakova
2014-09-03 16:00:41 +04:00
parent 3a9b7bbade
commit 976d5ab030
89 changed files with 482 additions and 480 deletions
@@ -23,7 +23,7 @@ L0:
v(i) INIT: in: {numbers=ID} out: {i=D, numbers=ID}
L2 [loop entry point]:
L6 [condition entry point]:
jmp?(L3 [loop exit point]) INIT: in: {i=D, numbers=ID} out: {i=D, numbers=ID}
jmp?(L3) INIT: in: {i=D, numbers=ID} out: {i=D, numbers=ID}
magic[LOOP_RANGE_ITERATION](numbers|<v1>) -> <v2>
w(i|<v2>) INIT: in: {i=D, numbers=ID} out: {i=ID, numbers=ID}
mark(for (i in numbers) { val b: Boolean if (1 < 2) { b = false } else { b = true } use(b) continue }) INIT: in: {i=ID, numbers=ID} out: {i=ID, numbers=ID} USE: in: {} out: {}
@@ -35,11 +35,11 @@ L4 [body entry point]:
r(2) -> <v4>
mark(1 < 2)
call(1 < 2, compareTo|<v3>, <v4>) -> <v5>
jf(L7 [else branch]|<v5>)
jf(L7|<v5>)
5 mark({ b = false })
r(false) -> <v6> USE: in: {b=WRITTEN_AFTER_READ} out: {b=WRITTEN_AFTER_READ}
w(b|<v6>) INIT: in: {b=D, i=ID, numbers=ID} out: {b=ID, i=ID, numbers=ID} USE: in: {b=READ} out: {b=WRITTEN_AFTER_READ}
4 jmp(L8 ['if' expression result]) INIT: in: {b=ID, i=ID, numbers=ID} out: {b=ID, i=ID, numbers=ID} USE: in: {b=READ} out: {b=READ}
4 jmp(L8) INIT: in: {b=ID, i=ID, numbers=ID} out: {b=ID, i=ID, numbers=ID} USE: in: {b=READ} out: {b=READ}
L7 [else branch]:
5 mark({ b = true }) INIT: in: {b=D, i=ID, numbers=ID} out: {b=D, i=ID, numbers=ID}
r(true) -> <v8> USE: in: {b=WRITTEN_AFTER_READ} out: {b=WRITTEN_AFTER_READ}
@@ -49,8 +49,8 @@ L8 ['if' expression result]:
r(b) -> <v11> USE: in: {} out: {b=READ}
mark(use(b))
call(use(b), use|<v11>) -> <v12>
jmp(L6 [condition entry point]) USE: in: {} out: {}
- 3 jmp(L2 [loop entry point])
jmp(L6) USE: in: {} out: {}
- 3 jmp(L2)
L3 [loop exit point]:
L5 [body exit point]:
read (Unit) INIT: in: {i=D, numbers=ID} out: {i=D, numbers=ID}
@@ -77,4 +77,4 @@ error:
<ERROR> INIT: in: {} out: {}
sink:
<SINK> INIT: in: {a=ID} out: {a=ID} USE: in: {} out: {}
=====================
=====================