[LLVMbugs] [Bug 2237] request: add '-emit-llvm' switch to 'gnatmake'
bugzilla-daemon at cs.uiuc.edu
bugzilla-daemon at cs.uiuc.edu
Mon Apr 21 09:55:11 PDT 2008
http://llvm.org/bugs/show_bug.cgi?id=2237
Duncan Sands <baldrick at free.fr> changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|ASSIGNED |RESOLVED
Resolution| |FIXED
--- Comment #1 from Duncan Sands <baldrick at free.fr> 2008-04-21 11:55:08 ---
Fixed here:
http://lists.cs.uiuc.edu/pipermail/llvm-commits/Week-of-Mon-20080421/061370.html
Things are not perfect though: -emit-llvm is not recorded in the ali file.
The reason for this is that gnatmake passes an invisible -gnatez argument
to the compiler to indicate the end of the arguments that should be placed
in the ali file. So gcc gets invoked something like this:
gcc -emit-llvm -gnatez -c file.adb
However gcc rewrites -emit-llvm into -emit-llvm-bc if used with -c.
Actually what it apparently does is turn the -c into -emit-llvm-bc.
This gives
gcc -gnatez -emit-llvm-bc file.adb
Since -emit-llvm-bc is now after the -gnatez, it is no longer placed
in the ali file.
This means (for example) that gnatlink will not use -emit-llvm when
compiling the binder generated main; and that gnatmake -s will always
think there is a switch mismatch and recompile every time.
These issues should probably get their own bugreport.
--
Configure bugmail: http://llvm.org/bugs/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are on the CC list for the bug.
More information about the llvm-bugs
mailing list