Closed Fabrizio-Caruso closed 1 week ago
I can provide a minimal example (source code, map file and binary attached) that produces a wrong result for a simple operation: 28 - 0 = 27
I may try to further simplify it.
It was build with:
tms9900-gcc -c projects/ti99testb/main.c -o projects/ti99testb/main.o tms9900-ld ../tools/ti99/crt0_ea5.o projects/ti99testb/main.o -std=c99 -O2 -s -I./ -fno-builtin -fno-peephole2 -fno-function-cse -nostdlib --section-start .text=a000 --section-start .data=2080 -M -L/opt/gcc4ti/lib -lti99 -o xchase.ea5.elf > xchase.map ../tools/ti99/elf2ea5.exe xchase.ea5.elf xti99testb1.ea5.bin ../tools/ti99/ea5split.exe xti99testb1.ea5.bin
main.zip
xchase.zip
XTI99TESTB1.zip
The correct bottom value should be 28 (you can build the same code natively with gcc to see the correct result)
Problem caused because subtracting a register from a constant was broken in insn rsubihi - fixed in 1.32
I can provide a minimal example (source code, map file and binary attached) that produces a wrong result for a simple operation: 28 - 0 = 27
I may try to further simplify it.
It was build with:
main.zip
xchase.zip
XTI99TESTB1.zip
The correct bottom value should be 28 (you can build the same code natively with gcc to see the correct result)