Le 09/03/2017 à 07:24,
[email protected] a écrit :
Thx for taking the time to reply.
The file I refer to is indeed mips.md. The only change I made is to change the int declaration in the interface record from
Int, 4, 4, 0 to 2, 2, 0
I van compile rcc and build the target specific file ok. But when I then use the resulting compiler (e.g. 'Rcc -target=mips test.c'. It starts to compile 'test.c' but errors out at the first statement it encounters with:
Compiler error in._label --bad terminal 2357
I looked through the lcc source to see where that error is thrown and it seems to be the part that selects the opcode. 2357 is not declared in the machine description file (eg no %term xxxxx=2357), so I am wondering how it decides it wants that
specific opcode.
Thx,
Erwin
In the lcc version I started, opcodes are multiples of 16, and ADD, SUB,
etc are "spezcialized" by adding the specific type of the
addition/subtraction whatever.
So we have ADD_I (ADDI) add integer, ADD_D (ADDD) to add doubles, etc.
You should look in the opcodes near 2357 to see which one is failing.
The error means that you have failed to implement a rule for that operator.
In this case look at what could be that 2357 and see which operation you
failed to implement. Since you just modified the sizes in the interface
record you will see that now there is no way to convert a pointer into
an int (for instance) or some other operation becomes undefined.
Changing the size of int is a MAJOR undertaking since so much depends on
that type.
--- SoupGate-Win32 v1.05
* Origin: fsxNet Usenet Gateway (21:1/5)