Skip to content

Failed test because of the Rizin stack vars change #19

@XVilka

Description

@XVilka
[XX] /home/runner/work/rz-retdec/rz-retdec/test/db/extras/retdec stackvars bp
/usr/bin/rizin -escr.utf8=0 -escr.color=0 -escr.interactive=0 -eflirt.sigdb.load.system=false -eflirt.sigdb.load.home=false -N -Qc 'aa
s sym.leaffunc
afvr rdi a int *
afvr rsi b int *
afvr rdx c int *
afvr rcx d int *
s sym.varfunc
afvs -0x20 lightbulb int
afvs -0x1c sun int
afvs -0x18 last int
afvs -0x14 chance int
pdz
' rizin-testbins/elf/vars-complex-x86_64-bp
make: *** [Makefile:6: run] Error 1
-- stdout
--- expected
+++ actual
@@ -20,34 +20,34 @@
 void varfunc(int64_t arg1) {
     int64_t v1 = __readfsqword(40); // 0x1167
     int32_t v2 = arg1; // 0x1176
-    int32_t chance; // bp-20, 0x[115](https://github.com/rizinorg/rz-retdec/actions/runs/3931563648/jobs/6722986476#step:7:116)c
-    int32_t last; // bp-24, 0x115c
-    int32_t lightbulb; // bp-32, 0x115c
-    int32_t sun; // bp-28, 0x115c
+    int32_t chance2; // bp-20, 0x115c
+    int32_t chance; // bp-28, 0x115c
+    int32_t last2; // bp-24, 0x115c
+    int32_t last; // bp-32, 0x115c
     if (v2 != 1) {
         if (v2 != 2) {
             // 0x11be
-            lightbulb = 42;
-            sun = 42;
             last = 42;
             chance = 42;
+            last2 = 42;
+            chance2 = 42;
         } else {
             // 0x11a0
-            lightbulb = 9;
-            sun = 8;
-            last = 7;
-            chance = 6;
+            last = 9;
+            chance = 8;
+            last2 = 7;
+            chance2 = 6;
         }
     } else {
         // 0x[117](https://github.com/rizinorg/rz-retdec/actions/runs/3931563648/jobs/6722986476#step:7:118)c
-        lightbulb = 1;
-        sun = 2;
-        last = 3;
-        chance = 4;
+        last = 1;
+        chance = 2;
+        last2 = 3;
+        chance2 = 4;
     }
     // 0x11da
-    leaffunc(&lightbulb, &sun, &last, &chance);
-    sun = chance;
+    leaffunc(&last, &chance, &last2, &chance2);
+    chance = chance2;
     if (v1 != __readfsqword(40)) {
         // 0x[120](https://github.com/rizinorg/rz-retdec/actions/runs/3931563648/jobs/6722986476#step:7:121)a
         __stack_chk_fail();

-- stderr
[ ] Analyze all flags starting with sym. and entry0 (aa)
[
[x] Analyze all flags starting with sym. and entry0 (aa)

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions