Registering '-march=' option for LLC

Thank you very much for replying to me for the previous long quesions.
Actually, I have another question for LLC.
While making my code for LLVM backend, I’d indeed like to convert HLL to the text assembly code for my new architecture.
I registered my target through

RegisterTarget X(“xcc”, “XCC”);

in XccTargetMachine.cpp.
However, as you know, this is not enough for me to use “$ llc -march=xcc hello.bc -o hello.xcc”
What should I do more in order to use LLC for emitting the assembly code.

FYI, there is another LLVM code in the root directory I have no permission to modify.

And I have my own LLVM code in my /home directory.

I don’t want any conflict with that one in the root while using LLC.

Thank you very much.

Seung Jae Lee


Thank you very much for replying to me for the previous long quesions.
Actually, I have another question for LLC.
While making my code for LLVM backend, I'd indeed like to convert HLL to the text
assembly code for my new architecture.
I registered my target through

RegisterTarget<XccTargetMachine> X("xcc", "XCC");

Make sure that the library is being linked into your tool. This requires adding code to llvm/autoconf/configure.ac (search for TARGETS_TO_BUILD, add yours). Then regenerate configure, then rerun configure, then rebuild llc.

And I have my own LLVM code in my /home directory.
I don't want any conflict with that one in the root while using LLC.

I'm not sure where this came from.

-Chris

FYI, there is another LLVM code in the root directory I have no
permission to modify.
And I have my own LLVM code in my /home directory.
I don't want any conflict with that one in the root while using LLC.

Make sure the LLVM in your home directory is FIRST in your path. That should make sure you are using your llc versus the one installed on the system.

-Tanya