Bram Adams
2007-May-20 21:21 UTC
[LLVMdev] API changes (was Antw.: 2.0 Pre-release tarballs online)
Hi, Op 19-mei-07, om 00:39 heeft Chris Lattner het volgende geschreven:> Anton is right. You should be able to use -fno-builtins to disable > this.Thanks, that did the trick. Some final remarks (my app works again :-)): * llvm.va_start and similar intrinsics now have an i8* arg instead of an sbyte** * For some reason the Arguments of a Function are now circularly linked, i.e. getPrev()/Next() does not yield 0 when the first Argument is reached, but jumps back to the last one. I experienced this with a loop I was using to find out the index of an Argument. It relied on the fact that getPrev() would eventually give 0, which worked in previous LLVM versions. On a related note: while using llvmc I have some test cases where the following error now pops up on Linux X86 (not on OSX): <premain>: CommandLine Error: Argument 'debug' defined more than once! llvmc: CommandLine Error: Argument 'debug' defined more than once! These are the arguments I provide to llvmc (I need the -disable-opt as some of the standard passes absolutely need to occur before my passes, and the rest must come afterwards): llvmc --config-dir ${ASPICERE2_SRC}/config/ -Tlnk="-L${LLVM_FRONT}/ lib" -Tlnk="-L${ASPICERE2_INSTALL}/lib" -Tlnk="-L${SWI_LIB}" -Tlnk="- load=${ASPICERE2_INSTALL}/lib/weaver" -Tlnk="-load=$ {ASPICERE2_INSTALL}/lib/native" -Tlnk="-disable-opt" -Tlnk="- constmerge" -Tlnk="-globalsmodref-aa" -Tlnk="-reify" -Tlnk="-match" - Tlnk="-weave" -Tlnk="-globalsmodref-aa" -Tlnk="-internalize" -Tlnk="- ipsccp" -Tlnk="-globalopt" -Tlnk="-constmerge" -Tlnk="-deadargelim" - Tlnk="-instcombine" -Tlnk="-inline" -Tlnk="-prune-eh" -Tlnk="- globalopt" -Tlnk="-globaldce" -Tlnk="-argpromotion" -Tlnk="- instcombine" -Tlnk="-scalarrepl" -Tlnk="-globalsmodref-aa" -Tlnk="- licm" -Tlnk="-load-vn" -Tlnk="-gcse" -Tlnk="-dse" -Tlnk="- instcombine" -Tlnk="-simplifycfg" -Tlnk="-globaldce" $FILTERED_ARGS $ASPECT_STRING_TO_C Variable $FILTERED_ARGS contains some .c files and also the -o switch with the name of the resulting binary, while $ASPECT_STRING_TO_C contains another number of .c files. The weird thing (besides that I only experience this error on Linux) is that although all my test cases use llvmc, only two fail with this error without a clear reason. Any ideas on this? Kind regards, Bram Adams GH-SEL, INTEC, Ghent University (Belgium)
Reid Spencer
2007-May-23 05:47 UTC
[LLVMdev] API changes (was Antw.: 2.0 Pre-release tarballs online)
On Tue, 22 May 2007 23:52:46 -0700 (PDT) Chris Lattner <sabre at nondot.org> wrote:>On Sun, 20 May 2007, Bram Adams wrote:>> On a related note: while using llvmc I have some test cases where the >> following error now pops up on Linux X86 (not on OSX): >> >> <premain>: CommandLine Error: Argument 'debug' defined more than once! >> llvmc: CommandLine Error: Argument 'debug' defined more than once! > >No idea. :) > >llvmc is a work in progress which has stagnated somewhat. I strongly >recommend using llvm-gcc directly.Bram: About the only way I know of to get that error is if you linked LLVM into a loadable module and loaded it with llvmc. Did you do that? If so, don't link any LLVM stuff into your module! See the Makefile in the "Hello" transform for an example of how to do this. If you need to use something in LLVM that is not linked into llvmc (so it can't be dynamically resolved at load time), then either a) find another way to do it (without using LLVM) or b) copy the code and link it statically into your loadable module making sure that you remove any static constructors/destructors for pass registration, statistics or command line options. Reid.> >-Chris > >-- >http://nondot.org/sabre/ >http://llvm.org/ >_______________________________________________ >LLVM Developers mailing list >LLVMdev at cs.uiuc.edu http://llvm.cs.uiuc.edu >http://lists.cs.uiuc.edu/mailman/listinfo/llvmdev
Chris Lattner
2007-May-23 06:52 UTC
[LLVMdev] API changes (was Antw.: 2.0 Pre-release tarballs online)
On Sun, 20 May 2007, Bram Adams wrote:> Op 19-mei-07, om 00:39 heeft Chris Lattner het volgende geschreven: >> Anton is right. You should be able to use -fno-builtins to disable >> this. > > Thanks, that did the trick. > > Some final remarks (my app works again :-)): > * llvm.va_start and similar intrinsics now have an i8* arg instead > of an sbyte**ok> * For some reason the Arguments of a Function are now circularly > linked, i.e. getPrev()/Next() does not yield 0 when the first > Argument is reached, but jumps back to the last one. I experienced > this with a loop I was using to find out the index of an Argument. It > relied on the fact that getPrev() would eventually give 0, which > worked in previous LLVM versions.Ah, these should be private. Thanks for pointing this out, I'll fix ;-). You should use iterators.> On a related note: while using llvmc I have some test cases where the > following error now pops up on Linux X86 (not on OSX): > > <premain>: CommandLine Error: Argument 'debug' defined more than once! > llvmc: CommandLine Error: Argument 'debug' defined more than once!No idea. :) llvmc is a work in progress which has stagnated somewhat. I strongly recommend using llvm-gcc directly. -Chris -- http://nondot.org/sabre/ http://llvm.org/
Seemingly Similar Threads
- [LLVMdev] API changes (was Antw.: 2.0 Pre-release tarballs online)
- [LLVMdev] API changes (was Antw.: 2.0 Pre-release tarballs online)
- [LLVMdev] API changes (was Antw.: 2.0 Pre-release tarballs online)
- [LLVMdev] API changes (was Antw.: 2.0 Pre-release tarballs online)
- [LLVMdev] Antw.: 2.0 Pre-release tarballs online