This is an archive of the discontinued LLVM Phabricator instance.

[XRay][compiler-rt] Remove reliance on C++ ABI from BufferQueue
ClosedPublic

Authored by dberris on Jun 3 2018, 11:04 PM.

Details

Summary

This is part of the work to address http://llvm.org/PR32274.

We remove the calls to array-placement-new and array-delete. This allows
us to rely on the internal memory management provided by
sanitizer_common/sanitizer_internal_allocator.h.

Diff Detail

Repository
rL LLVM

Event Timeline

dberris created this revision.Jun 3 2018, 11:04 PM
kpw accepted this revision.Jun 4 2018, 6:39 PM
kpw added inline comments.
compiler-rt/lib/xray/xray_buffer_queue.cc
33 ↗(On Diff #149672)

Can you template the array init and still be ABI compliant? Other than initialization, these are identical other than the type and that could be traited.

If you can't or feel that would be less readable, feel free to resolve this comment.

This revision is now accepted and ready to land.Jun 4 2018, 6:39 PM
dberris updated this revision to Diff 149899.Jun 4 2018, 8:40 PM
dberris marked an inline comment as done.
  • fixup: use a template for array init
compiler-rt/lib/xray/xray_buffer_queue.cc
33 ↗(On Diff #149672)

Thanks! Much more readable with a template indeed.

This revision was automatically updated to reflect the committed changes.