[LLVMdev] PTX target for LLVM!

Adarsh HV adarsh.hv99 at gmail.com
Mon Aug 29 04:43:53 PDT 2011


Hi everyone,
I downloaded the latest version of LLVM PTX backend from
http://www.prog.uni-saarland.de/projects/anysl
 and made the required changes to all the files mentioned in the README. But
I get the following error when I compile it.
llvm[3]: Compiling PTXBackend.cpp for Release build
In file included from PTXBackend.h:70:0,
                 from PTXBackend.cpp:36:
PTXPasses.h: In constructor
‘PTXBackendInsertSpecialInstructions::PTXBackendInsertSpecialInstructions(std::map<const
llvm::Value*, const llvm::Value*>&)’:
PTXPasses.h:93:63: error: no matching function for call to
‘llvm::BasicBlockPass::BasicBlockPass(char*)’
/home/neelima/Documents/llvm-2.9/include/llvm/Pass.h:321:12: note:
candidates are: llvm::BasicBlockPass::BasicBlockPass(char&)
/home/neelima/Documents/llvm-2.9/include/llvm/Pass.h:319:36: note:                
llvm::BasicBlockPass::BasicBlockPass(const llvm::BasicBlockPass&)
PTXPasses.h: In constructor
‘PTXPolishBeforeCodegenPass::PTXPolishBeforeCodegenPass()’:
PTXPasses.h:151:24: error: no matching function for call to
‘llvm::BasicBlockPass::BasicBlockPass(char*)’
/home/neelima/Documents/llvm-2.9/include/llvm/Pass.h:321:12: note:
candidates are: llvm::BasicBlockPass::BasicBlockPass(char&)
/home/neelima/Documents/llvm-2.9/include/llvm/Pass.h:319:36: note:                
llvm::BasicBlockPass::BasicBlockPass(const llvm::BasicBlockPass&)
PTXPasses.h: In constructor
‘PTXBackendNameAllUsedStructsAndMergeFunctions::PTXBackendNameAllUsedStructsAndMergeFunctions()’:
PTXPasses.h:197:21: error: no matching function for call to
‘llvm::ModulePass::ModulePass(char*)’
/home/neelima/Documents/llvm-2.9/include/llvm/Pass.h:235:12: note:
candidates are: llvm::ModulePass::ModulePass(char&)
/home/neelima/Documents/llvm-2.9/include/llvm/Pass.h:220:32: note:                
llvm::ModulePass::ModulePass(const llvm::ModulePass&)
In file included from PTXBackend.cpp:36:0:
PTXBackend.h: In constructor
‘PTXWriter::PTXWriter(llvm::formatted_raw_ostream&, std::map<const
llvm::Value*, const llvm::Value*>&)’:
PTXBackend.h:114:30: error: no matching function for call to
‘llvm::FunctionPass::FunctionPass(char*)’
/home/neelima/Documents/llvm-2.9/include/llvm/Pass.h:280:12: note:
candidates are: llvm::FunctionPass::FunctionPass(char&)
/home/neelima/Documents/llvm-2.9/include/llvm/Pass.h:278:34: note:                
llvm::FunctionPass::FunctionPass(const llvm::FunctionPass&)
PTXBackend.h: In member function ‘bool PTXWriter::isAddressExposed(const
llvm::Value*) const’:
PTXBackend.h:386:5: warning: no return statement in function returning
non-void
PTXBackend.h: In static member function ‘static bool
PTXWriter::isInlinableInst(const llvm::Instruction&)’:
PTXBackend.h:395:5: warning: no return statement in function returning
non-void
PTXBackend.h: In member function ‘std::string
PTXWriter::getAddressSpace(const llvm::Value*)’:
PTXBackend.h:556:40: error: ‘const class llvm::Value’ has no member named
‘getUnderlyingObject’
PTXBackend.cpp: In member function ‘virtual bool
PTXWriter::doInitialization(llvm::Module&)’:
PTXBackend.cpp:432:29: error: no matching function for call to
‘llvm::MCContext::MCContext(const llvm::MCAsmInfo&)’
/home/neelima/Documents/llvm-2.9/include/llvm/MC/MCContext.h:105:14: note:
candidates are: llvm::MCContext::MCContext(const llvm::MCAsmInfo&, const
llvm::TargetAsmInfo*)
/home/neelima/Documents/llvm-2.9/include/llvm/MC/MCContext.h:40:5: note:                
llvm::MCContext::MCContext(const llvm::MCContext&)
PTXBackend.cpp: In member function ‘std::string
PTXWriter::getOperandStr(const llvm::Value*)’:
PTXBackend.cpp:379:1: warning: control reaches end of non-void function
/bin/rm: cannot remove
`/home/neelima/Documents/llvm-2.9/lib/Target/PTXBackend/Release/PTXBackend.d.tmp':
No such file or directory
make[3]: ***
[/home/neelima/Documents/llvm-2.9/lib/Target/PTXBackend/Release/PTXBackend.o]
Error 1
make[3]: Leaving directory
`/home/neelima/Documents/llvm-2.9/lib/Target/PTXBackend'
make[2]: *** [PTXBackend/.makeall] Error 2
make[2]: Leaving directory `/home/neelima/Documents/llvm-2.9/lib/Target'
make[1]: *** [Target/.makeall] Error 2
make[1]: Leaving directory `/home/neelima/Documents/llvm-2.9/lib'
make: *** [all] Error 1


Sorry to post such a large piece of the debug info, but i am a beginner and
do not know which part  will help in debugging it.
Thank You:)

Helge Rhodin wrote:
> 
> Hey everybody,
> 
> good news for everyone interested in the PTX backend:
> We decided to release the current source code under the GPL - you can
> find the latest tarball here:
> 
> http://www.prog.uni-saarland.de/projects/anysl
> 
> You will find the README in the attachment, which should hopefully
> answer a lot of questions concerning the implementation and the current
> status.
> 
> If you have further questions, comments, or suggestions, feel free to
> contact us directly or respond on the list.
> 
> We would also like to know if there are any major obstacles to merging
> the code into LLVM trunk (apart from coding standards  ;)  ).
> 
> Best regards,
> Helge Rhodin and Ralf Karrenberg
> 
> 
>  
> _______________________________________________
> LLVM Developers mailing list
> LLVMdev at cs.uiuc.edu         http://llvm.cs.uiuc.edu
> http://lists.cs.uiuc.edu/mailman/listinfo/llvmdev
> 
> 

-- 
View this message in context: http://old.nabble.com/PTX-target-for-LLVM%21-tp28376690p32356202.html
Sent from the LLVM - Dev mailing list archive at Nabble.com.





More information about the llvm-dev mailing list