The irgen program crashes on C code that defines the read function as a variable function, not a void function.
i.e., if the benchmark code defines the read prototype as: uint64_t read() instead of: uint64_t read(void), the irgen program crashes on CF->getName() because the read() call compiles to IR as a cast instead of a direct call.
I ran the below in a shell to fix the problem. If you're on Linux with a GNU sed, you might have to replace sed -i '' to sed -i to run it.
The
irgen
program crashes on C code that defines theread
function as a variable function, not a void function.i.e., if the benchmark code defines the
read
prototype as:uint64_t read()
instead of:uint64_t read(void)
, theirgen
program crashes onCF->getName()
because theread()
call compiles to IR as a cast instead of a direct call.I ran the below in a shell to fix the problem. If you're on Linux with a GNU sed, you might have to replace
sed -i ''
tosed -i
to run it.