[LLVMdev] llc -load
Misha Brukman
brukman at uiuc.edu
Thu Jan 27 20:02:52 PST 2005
On Fri, Jan 28, 2005 at 10:53:35AM +0800, s88 wrote:
> 1. mark all of the code in the bool
> SparcV8TargetMachine::addPassesToEmitAssembly(PassManager
> &PM,std::ostream &Out)
> and make it return false.( Of course I mark the // Output assembly language.
> PM.add(createSparcV8CodePrinterPass(Out, *this));)
> 2. generate the LLVMSparcV8.so in the /usr/local/lib
> 3. run llc -load=/usr/local/lib/LLVMSparcV8.so -march=sparcv8 test.bc -o test.s
>
> Guess what? I got the assembly code of the test.bc....
> why....why....why?????
> What's wrong with my steps????
I'm sorry, I think I understand now. You commented out all the code in
addPassesToEmitAssembly() and it still outputs assembly code?
Did you change the tools/llc/Makefile to NOT link in SparcV8? Because
if it already linked it in, LLC already had a fully-functioning V8
backend linked into it, so you're probably running the staticly-linked
one (although LLC should probably complain that someone else already
signed up on the "sparcv8" switch...)
--
Misha Brukman :: http://misha.brukman.net :: http://llvm.cs.uiuc.edu
More information about the llvm-dev
mailing list