[OpenGOAL] make multiplication/divsion like GOAL and support in decompiler (#483)

* support in compiler

* multiplication in the decompiler

* update divisions
This commit is contained in:
water111
2021-05-14 18:43:12 -04:00
committed by GitHub
parent b3eb05e37f
commit d9f9d36f37
31 changed files with 441 additions and 326 deletions
@@ -2374,7 +2374,7 @@ TEST_F(FormRegressionTest, ExprStringToInt) {
" )\n"
" (set!\n"
" v0-0\n"
" (the-as int (+ (+ (-> a0-3 0) -55) (the-as uint (shl v0-0 4))))\n"
" (the-as int (+ (+ (-> a0-3 0) -55) (the-as uint (* v0-0 16))))\n"
" )\n"
" )\n"
" (else\n"
@@ -2385,11 +2385,11 @@ TEST_F(FormRegressionTest, ExprStringToInt) {
" )\n"
" (set!\n"
" v0-0\n"
" (the-as int (+ (+ (-> a0-3 0) -87) (the-as uint (shl v0-0 4))))\n"
" (the-as int (+ (+ (-> a0-3 0) -87) (the-as uint (* v0-0 16))))\n"
" )\n"
" (set!\n"
" v0-0\n"
" (the-as int (+ (+ (-> a0-3 0) -48) (the-as uint (shl v0-0 4))))\n"
" (the-as int (+ (+ (-> a0-3 0) -48) (the-as uint (* v0-0 16))))\n"
" )\n"
" )\n"
" )\n"
@@ -2407,7 +2407,7 @@ TEST_F(FormRegressionTest, ExprStringToInt) {
" )\n"
" (set!\n"
" v0-0\n"
" (the-as int (+ (+ (-> a0-4 0) -48) (the-as uint (shl v0-0 1))))\n"
" (the-as int (+ (+ (-> a0-4 0) -48) (the-as uint (* v0-0 2))))\n"
" )\n"
" (set! a0-4 (&-> a0-4 1))\n"
" )\n"