This is an archive of the discontinued LLVM Phabricator instance.

[XRay] Only avoid outlining pseudo-instructions, not whole blocks
AcceptedPublic

Authored by dhoekwater on Jul 26 2023, 11:13 AM.

Details

Reviewers
paquette
MaskRay
Summary

While some pseudo-instructions, such as fentry and PATCHABLE
instructions, must not be outlined, safe instruction sequences
within the same basic block can be outlined. Move the logic that
prevents pseudo-instruction outlining from the basic block level
to the instruction level. Doing so allows more instructions to be
safely outlined.

Diff Detail

Event Timeline

dhoekwater created this revision.Jul 26 2023, 11:13 AM
Herald added a project: Restricted Project. · View Herald TranscriptJul 26 2023, 11:13 AM
dhoekwater requested review of this revision.Jul 26 2023, 11:13 AM
Herald added a project: Restricted Project. · View Herald TranscriptJul 26 2023, 11:13 AM

Handle PATCHABLE_*EVENT_CALL instructions explicitly

Sorry that I'll be away for quite a few days and will be slow to review.

Sorry that I'll be away for quite a few days and will be slow to review.

No worries, enjoy your break!

MaskRay accepted this revision.Aug 30 2023, 10:59 PM

LGTM.

llvm/test/CodeGen/RISCV/machine-outliner-patchable.ll
80

CHECK-LABEL:.

It can improve FileCheck diagnostics when things go off. And IIUC, it allows reporting multiple errors after each -LABEL:

87

No newline at end of file

This revision is now accepted and ready to land.Aug 30 2023, 10:59 PM