In the following sequence:
$llc -march=c -o diag01_c.c diag01.ll
$vpolcc.ss -S -k diag01_c.c <<== FAILS
$vpolcc.ss -o diag01 diag01_c.s
I am using llc (from llvm) to convert an .ll file into a .c file. I am then running the .c file through vpolcc.ss (from zephyr) to further process it for mips architecture. The vpolcc.ss script fails at lcc (not to be confused with llc), with the following error:
75000ull' is a preprocessing number but an invalid integer constant diag01_c.c:305: 0x1.9f4bc6p’ is a preprocessing number but an invalid integer constant
diag01_c.c:306: `0x1.85d54c985f06fp’ is a preprocessing number but an invalid integer constant
Here’s a snippet of the relevant section of diag01_c.c:
*(&llvm_cbe_l) = 75000ull;
*(&llvm_cbe_f) = 0x1.9f4bc6p+3;
*(&llvm_cbe_d) = -0x1.85d54c985f06fp+6;
Here’s how vpolcc.ss is calling lcc:
($CFE is : ~/mips/lcc-run/lcc )
($cfeflag: I~/sim/sslittle-na-sstrix-include )
execute “$CFE $cfeflag -g -Wf-target=$TARGET -S -o $base.lef $base.i”
My questions are (the second one is relevant to llvm):
Can anyone tell me what I can do to get lcc to accept long-long values, as well as C9X hex floating point constants and such?
If necessary, I’m willing to modify llc (CBackend.cpp) to generate values that lcc can digest. However, I’m not sure how else I can represent the values shown above.
Can someone give me an idea of where to start?
Boise State University
Compiler Research Team