Hello again,
I managed to get the thing working and I have two last issues to solve.
1. My machine does not have any kind of floating point instructions. When
I write in the C source code
float f = 0.5f;
The compiler crashes with "Segmentation fault". Running a gdb on it, the
output becomes
Program received signal SIGSEGV, Segmentation fault.
0x00007ffff75e343a in vfprintf () from /lib/libc.so.6
I do not have a multiply instruction either but when I write "int c = a *
b;" the compiler properly inserts a LIBCALL to __mulsi3. Any idea what to
do with the float?
2. When I try "char c = 'c';", the compiler fails an assert:
test0.c:17: internal compiler error: in emit_move_multi_word, at expr.c:3273
This is strange since a char is smaller than an int, it should not be
calling emit_move_MULTI_word. I have
#define UNITS_PER_WORD 4
#define MIN_UNITS_PER_WORD 1
/* Promote those modes that are smaller than an int, to int mode. */
#define PROMOTE_MODE(MODE, UNSIGNEDP, TYPE) \
((GET_MODE_CLASS (MODE) == MODE_INT \
&& GET_MODE_SIZE (MODE) < UNITS_PER_WORD) \
? (MODE) = SImode : 0)
in my header file. Again, I do not know how to proceed.
Thank you again for your time,
R.