[clang] [compiler-rt] [XRay] Add support for instrumentation of DSOs on x86_64 (PR #90959)

Sebastian Kreutzer via cfe-commits cfe-commits at lists.llvm.org
Mon Jul 8 03:28:05 PDT 2024


================
@@ -471,42 +518,123 @@ uint16_t __xray_register_event_type(
 }
 
 XRayPatchingStatus __xray_patch() XRAY_NEVER_INSTRUMENT {
-  return controlPatching(true);
+  XRayPatchingStatus CombinedStatus{SUCCESS};
----------------
sebastiankreutzer wrote:

I would argue yes, since in this case doing nothing would be the expected behavior. 
However, in practice this case should never occur because the executable itself is always "loaded".

We could add an assertion to make this assumption explicit. What do you think?



https://github.com/llvm/llvm-project/pull/90959


More information about the cfe-commits mailing list