[LLVMdev] llvm-mc fixups

Owen Anderson resistor at mac.com
Wed Sep 12 21:20:13 PDT 2012


Showing the value for the fixup requires full object code layout and relaxation, which isn't done is the text-to-text path.

--Owen

On Sep 12, 2012, at 5:54 PM, Greg Fitzgerald <garious at gmail.com> wrote:

> When I use llvm-mc’s ‘-show-encoding’, it only goes as far as printing “fixups”:
> 
>  
> $ echo -e "adr r0, lbl\nnop\nlbl:" | llvm-mc -triple=thumbv7 -show-encoding
> 
>  
> Outputs:
> 
> @ encoding: [A,0xa0]
> 
> @    fixup A – offset: 0, value: lbl, kind: fixup_thumb_adr_pcrel_10
> 
>  
>  
> To find out that it is encoded as 0xa001, I can do:
> 
>  
> $ echo -e "adr r0, lbl\nnop\nlbl:" | llvm-mc -triple=thumbv7 -show-encoding -filetype=obj > tmp.o
> 
> $ llvm-objdump -d tmp.o
> 
>  
> Is there a way to get that encoding directly from llvm-mc?
> 
>  
> Thanks,
> 
> Greg
> 
> _______________________________________________
> LLVM Developers mailing list
> LLVMdev at cs.uiuc.edu         http://llvm.cs.uiuc.edu
> http://lists.cs.uiuc.edu/mailman/listinfo/llvmdev

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-dev/attachments/20120912/447e3e4d/attachment.html>


More information about the llvm-dev mailing list