SAD Version 5 (alpha)

All hardware related, disassembly / programming and code discussions belong here.
BOOSTEDEVERYTHING
Posts: 220
Joined: 2023 Sep 06, 13:11
Location: Charlotte NC , USA
Vehicle Information: 1999 Ford Ranger with 2000 Explorer v8 swap, FLN0
2003 Ford F150 Harley Davidson, Built 5.4L SOHC with 3.4L Whipple and Built 4R100

Re: SAD Version 5 (alpha)

Unread post by BOOSTEDEVERYTHING »

Wow. Another version already!?!?! I will download and give it a try. Thanks. No problem , as far as checking the dir file, I was just curious what I was getting wrong and what I am getting correctly. Thank you.

Edit: I tried the new version with EQE3 and it still fails with the MAF function in the dir file. Also, missing long areas of code in RZASA with or without the dir file. But it does complete the run with RZASA both ways. With my EQE3 bin and dir file, the lst file stops in the middle of Func_121cc. If I comment out the MAF transfer function it completes the run.
Please, again, take what I am saying with a grain of salt. I am very new at this and do not want to cause any unnecessary trouble shooting.
tvrfan
Posts: 84
Joined: 2023 Oct 22, 22:13
Location: New Zealand
Vehicle Information: Several Kit cars, Ford (Europe), EEC-IV, TVR Vixen, Tasmin (a.k.a Wedge),
Engine - Cologne 2.8 V6 (Europe) catch code 'AA'.

EEC_Disassembler https://github.com/tvrfan/EEC-IV-disassembler

Re: SAD Version 5 (alpha)

Unread post by tvrfan »

Guys,

5.0.4 released. I've already spotted a problem with comments causing bit/field names to get messed up. It fixes one crash, but sounds like there's others lurking in there too.

General Note - I always start testing with AA (it's probably the simplest bin in existence) and then to A9L (test subroutine arguments) and then XDT2 (a 2 bank bin) as a progression of more features which have to work, and 'get basics right first' approach. So the bigger 4 banks get to wait a bit....

I will have a look at RZASA and see if I can spot why lots of code is missed - and see if v4 does it too.

Again - I did have a 'gap' scanner to try to pick up lost code, I have not put it back yet....maybe in next release after crashes fixed. I will also put in a "press any key to continue" for windows (temporary) to see if you get any useful info for crashes (I reckon I know how to do that...).
Jamie from oz
Posts: 28
Joined: 2022 Jul 08, 04:54
Location: South Australia
Vehicle Information: 1995 ford falcon ute 5.0 windsor efi

Re: SAD Version 5 (alpha)

Unread post by Jamie from oz »

Have tried with sad 504 also and stopped similar place and when i commented out fun ce22 and ce3e it run fine.

also worked out how to zip a file hahaha.
sadV505_6dbd.zip
(22.37 KiB) Downloaded 45 times
(sorry TVRFAN that was not meant to be labeled sadV505 just seen that)
wwhite
Posts: 313
Joined: 2021 Feb 16, 15:53
Location: Victoria, BC, Canada
Vehicle Information: 1994 Flarside, XLT, 351w E4OD
SD48b, Quarter Horse, Burn2

Re: SAD Version 5 (alpha)

Unread post by wwhite »

I get exact same seg fault as before using 5.0.4

Code: Select all

Reading symbols from SAD_5.0.4.exe...
(gdb) run
Starting program: C:\Users\wwhite\Programming\SAD\SAD_5.0.4.exe
[New Thread 14704.0x3b80]
KID2

Thread 1 received signal SIGSEGV, Segmentation fault.
0x0040c25a in add_spf_register (p=0xce1c90, dest=58, sce=0, popaddr=622135)
    at C:/CLProjects/SAD/WSAD/Core.cpp:6205
warning: Source file is more recent than executable.
6205
(gdb) bt
#0  0x0040c25a in add_spf_register (p=0xce1c90, dest=58, sce=0,
    popaddr=622135) at C:/CLProjects/SAD/WSAD/Core.cpp:6205
#1  0x0040c7fe in ldx (s=0xc2898c, c=0x438720 <einst>)
    at C:/CLProjects/SAD/WSAD/Core.cpp:6522
#2  0x0040f036 in do_code (s=0xc2898c, c=0x438720 <einst>)
    at C:/CLProjects/SAD/WSAD/Core.cpp:8107
#3  0x0040a2db in scan_blk (s=0xc2898c, c=0x438720 <einst>)
    at C:/CLProjects/SAD/WSAD/Core.cpp:3689
#4  0x0040e40e in scl (s=0xc28c44, c=0x438720 <einst>)
    at C:/CLProjects/SAD/WSAD/Core.cpp:7580
#5  0x0040f036 in do_code (s=0xc28c44, c=0x438720 <einst>)
    at C:/CLProjects/SAD/WSAD/Core.cpp:8107
#6  0x0040a2db in scan_blk (s=0xc28c44, c=0x438720 <einst>)
    at C:/CLProjects/SAD/WSAD/Core.cpp:3689
#7  0x0040a46b in emulate_blk (addr=623014, caller=0xceab88)
    at C:/CLProjects/SAD/WSAD/Core.cpp:3860
#8  0x0040e13e in do_sub_scan (caller=0xceab88, c=0x438660 <cinst>)
    at C:/CLProjects/SAD/WSAD/Core.cpp:7435
#9  0x0040e354 in scl (s=0xceab88, c=0x438660 <cinst>)
    at C:/CLProjects/SAD/WSAD/Core.cpp:7540
#10 0x0040f036 in do_code (s=0xceab88, c=0x438660 <cinst>)
    at C:/CLProjects/SAD/WSAD/Core.cpp:8107
#11 0x0040a2db in scan_blk (s=0xceab88, c=0x438660 <cinst>)
    at C:/CLProjects/SAD/WSAD/Core.cpp:3689
#12 0x0040f736 in scan_all () at C:/CLProjects/SAD/WSAD/Core.cpp:8520
#13 0x004123cc in disassemble (fstr=0xce1658 "KID2")
    at C:/CLProjects/SAD/WSAD/Core.cpp:10579
#14 0x00422bee in main (argc=1, argv=0xce1678)
    at C:/CLProjects/SAD/WSAD/main.cpp:593
(gdb)

jsa
Posts: 261
Joined: 2021 Feb 16, 15:46
Location: Australia
Vehicle Information: 95 Escort RS Cosworth
2.0 YBP
CARD / QUIK / COSY / ANTI
GHAJ0
SMD-190 / SMD-490 EEC-IV

Binary Editor
ForDiag

Re: SAD Version 5 (alpha)

Unread post by jsa »

So 504 is not identifying some of the lookup subs.
Some of the functions crash.

What subs are being used for the functions that crash?
Report your experience, maybe there's a pattern.
tvrfan
Posts: 84
Joined: 2023 Oct 22, 22:13
Location: New Zealand
Vehicle Information: Several Kit cars, Ford (Europe), EEC-IV, TVR Vixen, Tasmin (a.k.a Wedge),
Engine - Cologne 2.8 V6 (Europe) catch code 'AA'.

EEC_Disassembler https://github.com/tvrfan/EEC-IV-disassembler

Re: SAD Version 5 (alpha)

Unread post by tvrfan »

wwhite wrote: 2024 Jan 09, 20:48 I get exact same seg fault as before using 5.0.4

Code: Select all

Reading symbols from SAD_5.0.4.exe...
(gdb) run
Starting program: C:\Users\wwhite\Programming\SAD\SAD_5.0.4.exe
[New Thread 14704.0x3b80]
KID2

Thread 1 received signal SIGSEGV, Segmentation fault.
0x0040c25a in add_spf_register (p=0xce1c90, dest=58, sce=0, popaddr=622135)
    at C:/CLProjects/SAD/WSAD/Core.cpp:6205
warning: Source file is more recent than executable.
6205
(gdb) bt
#0  0x0040c25a in add_spf_register (p=0xce1c90, dest=58, sce=0,
    popaddr=622135) at C:/CLProjects/SAD/WSAD/Core.cpp:6205
<snip>
(gdb)

Fabulous and many thanks - that's recognisable to me as to where the crash is, and it's... A SCREW UP by me.

I put a temp check in (as in the release docs), and then... I managed to remove it again before rebuilding SAD on Windows.... <swear words>

Sorry about that . OK, I'll fix that and do a 5.0.5 quickly right now.

"well hey, we all make mistakes" said the Dalek climbing off the dustbin......... (from a British comedian...)
tvrfan
Posts: 84
Joined: 2023 Oct 22, 22:13
Location: New Zealand
Vehicle Information: Several Kit cars, Ford (Europe), EEC-IV, TVR Vixen, Tasmin (a.k.a Wedge),
Engine - Cologne 2.8 V6 (Europe) catch code 'AA'.

EEC_Disassembler https://github.com/tvrfan/EEC-IV-disassembler

Re: SAD Version 5 (alpha)

Unread post by tvrfan »

crash in funcs -

jamie,wwhite - I have a 6DBX but not a 6DBD. I tried jamie's dir with 6bdx on my linux system. Doesn't crash, BUT it doesn't list properly, with no error reported about the command - so something weird is happening... looks like table at cd94 just continues to run over the funcs. (I can see that 6dbx bin has funcs at ce22 and ce3e.) So something to find in there. Maybe a win versus linux difference for the crash (happens sometimes) Will look ASAP.

jsa - lookup funcs were being recognised, but subr names got replaced with standard names when they should not have been - fixed in 5.0.5 I hope, didn't fully test as pushed out 5.0.5 to fix my stupid mistake (above)
tvrfan
Posts: 84
Joined: 2023 Oct 22, 22:13
Location: New Zealand
Vehicle Information: Several Kit cars, Ford (Europe), EEC-IV, TVR Vixen, Tasmin (a.k.a Wedge),
Engine - Cologne 2.8 V6 (Europe) catch code 'AA'.

EEC_Disassembler https://github.com/tvrfan/EEC-IV-disassembler

Re: SAD Version 5 (alpha)

Unread post by tvrfan »

Note that 5.0.5 at the moment is a debug build, it creates a file called "<name>_dbg.txt. I was going to fix it, but my virtualbox just stopped working after a minor linux upgrade (this is never supposed to happen...) so it may take me a while to sort out the mess. It won't remove cleanly as it gets an error, and it won't install/reinstall as it gets an error..... so stuck in the middle somewhere.... web doesn't have a solution (yet).
wwhite
Posts: 313
Joined: 2021 Feb 16, 15:53
Location: Victoria, BC, Canada
Vehicle Information: 1994 Flarside, XLT, 351w E4OD
SD48b, Quarter Horse, Burn2

Re: SAD Version 5 (alpha)

Unread post by wwhite »

5.0.5, better, sort of, doesn't seg fault.
Creates lst and msg files, no dbg.
Once I add dir, program hangs or is stuck in a loop, at: | Analyse Data Structs

Old dir:

Code: Select all

args    76af 76b2 : O 2 UY  : UW N 
args    772c 772f : O 2 UY  : UW N 
word    7732 7733

7729: ef,bf,04            call  7beb             Sub_7beb (
772c: 0f                        #arg 1              f,
772d: 02                        #arg 2              2,
772e: 80,a7                     #arg 3              a780 );
7730: 20,11               sjmp  7743             goto 7743;

7732: 34,77               word   7734
New dir:

Code: Select all

args    76af  76b2     [ UY ][ UY ][ UY ][ UW N ]
args    772c  772f     [ UY ][ UY ][ UY ][ UW N ]
word    7732  7733     

7729: ef,bf,04            call  7beb             Sub_7beb (
772c: 0f                        #arg 1              f,
772d: 02                        #arg 2              2,
772e: 80                        #arg 3              80,
772f: a7,20                     #arg 4              20a7 );
7732: 34,77,04            jnb   B4,R77,7739      if (B4_R77 = 1) {
Sad 5.0.5 is creating too many args, there should be two(2) byte args and one(1) word arg for a total of three(3) args, not four(4) args.
wwhite
Posts: 313
Joined: 2021 Feb 16, 15:53
Location: Victoria, BC, Canada
Vehicle Information: 1994 Flarside, XLT, 351w E4OD
SD48b, Quarter Horse, Burn2

Re: SAD Version 5 (alpha)

Unread post by wwhite »

Here's a good one, actually probably a really bad bug.

Who see's the problem with this one:

Code: Select all

7de5: 14,01                     #arg 1              114,
7de7: d6,f0                     #arg 2              f0d6,
7deb: 28,03                     #arg 3              328,
7ded: 34,03                     #arg 4              334 );  
What happened to address 0x7de9 and 0x7dea ?
Post Reply