[decompiler] bug fixes related to infinite loop CFGs, argument registers (#622)

* temp

* clean up

* more clean
This commit is contained in:
water111
2021-06-23 22:09:02 -04:00
committed by GitHub
parent 997d5b57db
commit 44f8ff6d25
10 changed files with 115 additions and 48 deletions
@@ -207,16 +207,16 @@
(local-vars (sv-16 float) (sv-32 float))
(let* ((f30-0 (-> arg0 root trans y))
(v1-1 (-> arg0 draw))
(a1-4 (-> v1-1 lod-set lod (-> v1-1 cur-lod) geo effect))
(a1-5 (-> v1-1 lod-set lod (-> v1-1 cur-lod) geo effect))
)
(if (or (zero? (logand (-> a1-4 0 effect-bits) 4)) (not (-> v1-1 ripple)))
(if (or (zero? (logand (-> a1-5 0 effect-bits) 4)) (not (-> v1-1 ripple)))
(return f30-0)
)
(let* ((a1-5 (-> a1-4 0 extra-info))
(let* ((a1-6 (-> a1-5 0 extra-info))
(s4-0
(the-as
mei-ripple
(+ (the-as uint a1-5) (the-as uint (* (-> a1-5 ripple-offset) 16)))
(+ (the-as uint a1-6) (the-as uint (* (-> a1-6 ripple-offset) 16)))
)
)
(gp-0 (-> v1-1 ripple))