I was wondering if someone could explain to me how the data layout string computed by Clang relates to the layout that LLVM’s own target implementation can compute. For example, Clang has code to compute the layout used for x86 in clang/lib/Basic/Targets/X86.h
; LLVM can produce more or less the same layout strings with code in llvm/lib/Target/X86/X86TargetMachine.cpp
. However, as far as I can tell, Clang uses only the former.
Is there a reason why Clang computes its own layout strings? Do they differ from LLVM’s in some configuration? Any insights would be much appreciated