aboutsummaryrefslogtreecommitdiff
path: root/llvm/lib/Target/PowerPC/Disassembler/PPCDisassembler.cpp
diff options
context:
space:
mode:
authorAdrian Prantl <aprantl@apple.com>2021-06-11 15:18:25 -0700
committerAdrian Prantl <aprantl@apple.com>2021-06-14 14:19:41 -0700
commit03841edde7eee21d1d450041ab9a113a7e1be869 (patch)
tree323599401d9807e7d5db1d0d2782ec93efeb47f1 /llvm/lib/Target/PowerPC/Disassembler/PPCDisassembler.cpp
parent98504959a6f114866cbf523e44d2f45e755626d5 (diff)
downloadllvm-03841edde7eee21d1d450041ab9a113a7e1be869.zip
llvm-03841edde7eee21d1d450041ab9a113a7e1be869.tar.gz
llvm-03841edde7eee21d1d450041ab9a113a7e1be869.tar.bz2
Allow signposts to take advantage of deferred string substitution
One nice feature of the os_signpost API is that format string substitutions happen in the consumer, not the logging application. LLVM's current Signpost class doesn't take advantage of this though and instead always uses a static "Begin/End %s" format string. This patch uses variadic macros to allow the API to be used as intended. Unfortunately, the primary use-case I had in mind (the LLDB_SCOPED_TIMER() macro) does not get much better from this, because __PRETTY_FUNCTION__ is *not* a macro, but a static string, so signposts created by LLDB_SCOPED_TIMER() still use a static "%s" format string. At least LLDB_SCOPED_TIMERF() works as intended. This reapplies the previsously reverted patch with additional MachO.h macro #undefs. Differential Revision: https://reviews.llvm.org/D103575
Diffstat (limited to 'llvm/lib/Target/PowerPC/Disassembler/PPCDisassembler.cpp')
0 files changed, 0 insertions, 0 deletions