[PATCH] D39742: Add backend name to Target to enable runtime info to be fed back into TableGen

Daniel Sanders via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Tue Nov 7 10:00:48 PST 2017


dsanders created this revision.
Herald added subscribers: fedor.sergeev, javed.absar, nhaehnle, nemanjai, sdardis, jyknight, arsenm, jholewinski.

Make it possible to feed runtime information back to tablegen to enable
profile-guided tablegen-eration, detection of untested tablegen definitions, etc.

Being a cross-compiler by nature, LLVM will potentially collect data for multiple
architectures (e.g. when running 'ninja check'). We therefore need a way for
TableGen to figure out what data applies to the backend it is generating at the
time. This patch achieves that by including the name of the 'def X : Target ...'
for the backend in the TargetRegistry.


https://reviews.llvm.org/D39742

Files:
  include/llvm/Support/TargetRegistry.h
  lib/Support/TargetRegistry.cpp
  lib/Target/AArch64/TargetInfo/AArch64TargetInfo.cpp
  lib/Target/AMDGPU/TargetInfo/AMDGPUTargetInfo.cpp
  lib/Target/ARM/TargetInfo/ARMTargetInfo.cpp
  lib/Target/BPF/TargetInfo/BPFTargetInfo.cpp
  lib/Target/Hexagon/TargetInfo/HexagonTargetInfo.cpp
  lib/Target/Lanai/TargetInfo/LanaiTargetInfo.cpp
  lib/Target/MSP430/TargetInfo/MSP430TargetInfo.cpp
  lib/Target/Mips/TargetInfo/MipsTargetInfo.cpp
  lib/Target/NVPTX/TargetInfo/NVPTXTargetInfo.cpp
  lib/Target/PowerPC/TargetInfo/PowerPCTargetInfo.cpp
  lib/Target/Sparc/TargetInfo/SparcTargetInfo.cpp
  lib/Target/SystemZ/TargetInfo/SystemZTargetInfo.cpp
  lib/Target/X86/TargetInfo/X86TargetInfo.cpp
  lib/Target/XCore/TargetInfo/XCoreTargetInfo.cpp

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D39742.121925.patch
Type: text/x-patch
Size: 14427 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20171107/ab3647e8/attachment.bin>


More information about the llvm-commits mailing list