Permalink
Switch branches/tags
Nothing to show
Find file
Fetching contributors…
Cannot retrieve contributors at this time
68 lines (67 sloc) 1.8 KB
(FUNCTION gcd [(int u) (int v)]
(BB 0
(OPER 16 Push [] [(m EBP)])
(OPER 17 Mov [(m EBP)] [(m ESP)])
(OPER 18 Load [(r 1)] [(m ESP)(i 8)])
(OPER 19 Load [(r 2)] [(m ESP)(i 12)])
)
(BB 6
(OPER 22 Cmp [(m Flags)] [(r 2)(i 0)])
(OPER 23 BEQ [] [(bb 4)(m Flags)])
)
(BB 3
(OPER 6 Mov [(m EAX)] [(r 1)])
)
(BB 2
(OPER 20 Mov [(m ESP)] [(m EBP)])
(OPER 21 Pop [(m EBP)] [])
(OPER 3 Return [] [(m EAX)])
)
(BB 4
(OPER 24 Mov [(m EDX)] [(i 0)])
(OPER 25 Mov [(m EAX)] [(r 1)])
(OPER 8 Div [(m EAX)(m EDX)] [(m EAX)(r 2)(m EDX)])
(OPER 26 Mov [(r 4)] [(m EAX)])
(OPER 27 Mov [(m EAX)] [(r 4)])
(OPER 9 Mul [(m EAX)(m EDX)] [(m EAX)(r 2)])
(OPER 28 Mov [(r 5)] [(m EAX)])
(OPER 29 Mov [(r 6)] [(r 1)])
(OPER 10 Sub_I [(r 6)] [(r 6)(r 5)])
(OPER 7 Push [] [(r 6)])
(OPER 11 Push [] [(r 2)])
(OPER 12 JSR [] [(s gcd)])
(OPER 30 Add_I [(m ESP)] [(m ESP)(i 8)])
(OPER 13 Load [(r 7)] [(m EAX)])
(OPER 14 Mov [(m EAX)] [(r 7)])
)
(BB 5
)
)
(FUNCTION main []
(BB 0
(OPER 17 Push [] [(m EBP)])
(OPER 18 Mov [(m EBP)] [(m ESP)])
)
(BB 1
(OPER 4 JSR [] [(s input)])
(OPER 5 Load [(r 3)] [(m EAX)])
(OPER 6 Mov [(r 1)] [(r 3)])
(OPER 7 JSR [] [(s input)])
(OPER 8 Load [(r 4)] [(m EAX)])
(OPER 9 Mov [(r 2)] [(r 4)])
(OPER 11 Push [] [(r 2)])
(OPER 12 Push [] [(r 1)])
(OPER 13 JSR [] [(s gcd)])
(OPER 21 Add_I [(m ESP)] [(m ESP)(i 8)])
(OPER 14 Load [(r 5)] [(m EAX)])
(OPER 10 Push [] [(r 5)])
(OPER 15 JSR [] [(s output)])
(OPER 22 Add_I [(m ESP)] [(m ESP)(i 4)])
(OPER 16 Load [(r 6)] [(m EAX)])
)
(BB 2
(OPER 19 Mov [(m ESP)] [(m EBP)])
(OPER 20 Pop [(m EBP)] [])
(OPER 3 Return [] [(m EAX)])
)
)