[LLVMdev] Why 'target datalayout' strings are in .ll modules?

Yuri yuri at rawbw.com
Thu Feb 3 12:16:31 PST 2011


What is the meaning of 'target datalayout' being in .ll in addition to 
'target triple'?
When it can be meaningfully changed having the same 'target triple'?

As I understand llvm derives most of architecture-specific information 
from 'target triple'. For example ABI used by llvm is keyed to 'target 
triple'. But some parts of ABI are in 'target datalayout'. For example, 
on MacOS the fact from ABI that all stacks are always 16-aligned during 
procedure call is defined in 'target datalayout', not by 'target 
datalayout' like most other parts of ABI.

So why 'target datalayout' is exposed in .ll?

Yuri



More information about the llvm-dev mailing list