On 08/21/2012 10:35 AM, George Baah wrote:> That is what I don't understand. This symbol is defined in Dominators.h, > which I include > in my file. I don't understand why I am getting this error. Here is my > opt command, > > "opt -load LLVMMyDomPass.dylib -mdp < test.bc > test.d.bc"It may also be that the relevant code is dead code eliminated, as it is not used within LLVM. I would try to compile LLVM with --enable-shared (autoconf) or BUILD_SHARED_LIBS (cmake). If this works, the dead code elimination is probably the problem. Tobi
When I compile llvm in release mode, the problem goes away! I don't understand? George On Tue, Aug 21, 2012 at 5:01 AM, Tobias Grosser <tobias at grosser.es> wrote:> On 08/21/2012 10:35 AM, George Baah wrote: > >> That is what I don't understand. This symbol is defined in Dominators.h, >> which I include >> in my file. I don't understand why I am getting this error. Here is my >> opt command, >> >> "opt -load LLVMMyDomPass.dylib -mdp < test.bc > test.d.bc" >> > > It may also be that the relevant code is dead code eliminated, as it is > not used within LLVM. I would try to compile LLVM with --enable-shared > (autoconf) or BUILD_SHARED_LIBS (cmake). If this works, the dead code > elimination is probably the problem. > > Tobi >-------------- next part -------------- An HTML attachment was scrubbed... URL: <http://lists.llvm.org/pipermail/llvm-dev/attachments/20120821/67d3cc31/attachment.html>
On 08/21/2012 01:44 PM, George Baah wrote:> When I compile llvm in release mode, the problem goes away! I don't > understand?Interesting. I have no idea what is going on, but it would be interesting to investigate that. Tobi
Hi George,> When I compile llvm in release mode, the problem goes away! I don't understand?probably the function defined in the header is inlined into every function that calls it when optimization is turned on, but not when optimization is turned off. Ciao, Duncan.