This is an archive of the discontinued LLVM Phabricator instance.

[AArch64] [XRay] Account for XRay event instrs in Branch Relaxation
ClosedPublic

Authored by dhoekwater on Jul 25 2023, 3:55 PM.

Details

Summary

PATCHABLE_TYPED_EVENT_CALL and PATCHABLE_EVENT_CALL are pseudo
instructions that expand to XRay sleds, so getInstSizeInBytes
should reflect the size of the sleds, not the pseudo-instructions.

Diff Detail

Event Timeline

dhoekwater created this revision.Jul 25 2023, 3:55 PM
Herald added a project: Restricted Project. · View Herald TranscriptJul 25 2023, 3:55 PM
dhoekwater requested review of this revision.Jul 25 2023, 3:55 PM
Herald added a project: Restricted Project. · View Herald TranscriptJul 25 2023, 3:55 PM

Can you add comments explaining the size in bytes?

"This expands to an XRay sled can be at most N instructions = M bytes"

Or something

llvm/lib/Target/AArch64/AArch64InstrInfo.cpp
131

comment?

143

comment?

Add comments explaining the size of XRay PATCHABLE instructions

dhoekwater marked 2 inline comments as done.Jul 25 2023, 7:36 PM
dhoekwater added inline comments.
llvm/lib/Target/AArch64/AArch64InstrInfo.cpp
131

Done! Thanks for the feedback.

143

Done!

dhoekwater marked 2 inline comments as done.

Better spacing with clang-format

This revision is now accepted and ready to land.Jul 26 2023, 11:40 PM
This revision was landed with ongoing or failed builds.Jul 27 2023, 10:12 AM
This revision was automatically updated to reflect the committed changes.