[LLVMdev] Convert C++ to C. What is 0x0p+0 ?

Mohd-Hanafiah Abdullah napi at axiomsol.com
Sat Nov 4 20:25:39 PST 2006


Hi:

I'm interested in using llvm to convert C++ code to C code.
I used the following command to do this:

% llvm-g++ -c foo.cpp -o - | llc -march=c -o foo.cbe.c

In the resulting file foo.cbe.c there are many occurences of '0x0p+0'.
What is it used for?  Here's a code snippet from the file foo.cbe.c

  if ((ltmp_126_2 > 0x0p+0)) {
    goto ltmp_363_19;
  } else {
    goto ltmp_364_19;
  }

llvm-gcc is able to compile foo.cbe.c, but I need to use another C
compiler which gives a syntax error message for not recognizing
the expression '0x0p+0'.

Thank you for your assistance.

Napi





More information about the llvm-dev mailing list