diff options
author | Keith Wyss <wyssman@gmail.com> | 2018-04-17 21:28:53 +0000 |
---|---|---|
committer | Keith Wyss <wyssman@gmail.com> | 2018-04-17 21:28:53 +0000 |
commit | adb092e0aefc7da8fe68d5b49f0e61ae68d8f595 (patch) | |
tree | d1e87c5bb1aa6e289cd13dabf5fc18abd010ad1e /compiler-rt/lib/xray/xray_fdr_logging_impl.h | |
parent | 2b8158f441da74d8432c7629b005a7107a44186b (diff) | |
download | bcm5719-llvm-adb092e0aefc7da8fe68d5b49f0e61ae68d8f595.tar.gz bcm5719-llvm-adb092e0aefc7da8fe68d5b49f0e61ae68d8f595.zip |
Implement trampoline and handler for typed xray event tracing.
Summary:
Compiler-rt support first before defining the __xray_typedevent() lowering in
llvm. I'm looking for some early feedback before I touch much more code.
Reviewers: dberris
Subscribers: delcypher, llvm-commits, #sanitizers
Differential Revision: https://reviews.llvm.org/D43668
llvm-svn: 330218
Diffstat (limited to 'compiler-rt/lib/xray/xray_fdr_logging_impl.h')
-rw-r--r-- | compiler-rt/lib/xray/xray_fdr_logging_impl.h | 20 |
1 files changed, 20 insertions, 0 deletions
diff --git a/compiler-rt/lib/xray/xray_fdr_logging_impl.h b/compiler-rt/lib/xray/xray_fdr_logging_impl.h index ed0b5ca9022..3de310e9ca6 100644 --- a/compiler-rt/lib/xray/xray_fdr_logging_impl.h +++ b/compiler-rt/lib/xray/xray_fdr_logging_impl.h @@ -364,6 +364,16 @@ writeFunctionRecord(int FuncId, uint32_t TSCDelta, (void)Once; return; } + case XRayEntryType::TYPED_EVENT: { + static bool Once = [&] { + Report("Internal error: patched an XRay typed event call as a function; " + "func id = %d\n", + FuncId); + return true; + }(); + (void)Once; + return; + } } std::memcpy(TLD.RecordPtr, &FuncRecord, sizeof(FunctionRecord)); @@ -689,6 +699,16 @@ inline void processFunctionHook(int32_t FuncId, XRayEntryType Entry, (void)Once; return; } + case XRayEntryType::TYPED_EVENT: { + static bool Once = [&] { + Report("Internal error: patched an XRay typed event call as a function; " + "func id = %d\n", + FuncId); + return true; + }(); + (void)Once; + return; + } } writeFunctionRecord(FuncId, RecordTSCDelta, Entry); |