]> granicus.if.org Git - llvm/commit
[tblgen] Add a timer covering the time spent reading the Instruction defs
authorDaniel Sanders <daniel_l_sanders@apple.com>
Mon, 11 Feb 2019 23:02:02 +0000 (23:02 +0000)
committerDaniel Sanders <daniel_l_sanders@apple.com>
Mon, 11 Feb 2019 23:02:02 +0000 (23:02 +0000)
commit01b9856485b5c7ed833d3c3000ccf2b894c71c98
treebcca809c74d80302c5651e5833103256aaa47f02
parent45f5ca3e2d402f72fe29084929eaad4652a6362d
[tblgen] Add a timer covering the time spent reading the Instruction defs

This patch adds a -time-regions option to tablegen that can enable timers
(currently only one) that assess the performance of tablegen itself. This
can be useful for identifying scaling problems with tablegen backends.

This particular timer has allowed me to ignore time that is not attributed
the GISel combiner pass. It's useful by itself but it is particularly
useful in combination with https://reviews.llvm.org/D52954 which causes
this period of time to be annotated within Xcode Instruments which in turn
allows profile samples and recorded allocations attributed to reading
instructions to be filtered out.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@353763 91177308-0d34-0410-b5e6-96231b3b80d8
include/llvm/TableGen/TableGenBackend.h
utils/TableGen/CodeGenTarget.cpp
utils/TableGen/TableGen.cpp