[NFC][compiler-rt][hwasan] Re-use ring buffer size calculation
authorLeonard Chan <leonardchan@google.com>
Wed, 23 Jun 2021 23:12:52 +0000 (16:12 -0700)
committerLeonard Chan <leonardchan@google.com>
Tue, 29 Jun 2021 18:57:33 +0000 (11:57 -0700)
commit8e74668e96da5c38c7fabb1881a6510d6a09112d
tree088554f33f5db80204afbecd335456faf3013ef0
parentd4dcb55c7050fd908af2378fa551078d859d994f
[NFC][compiler-rt][hwasan] Re-use ring buffer size calculation

Users can call HwasanThreadList::GetRingBufferSize rather than RingBufferSize
to prevent having to do the calculation in RingBufferSize. This will be useful
for Fuchsia where we plan to initialize the stack ring buffer separately from
the rest of thread initialization.

Differential Revision: https://reviews.llvm.org/D104823
compiler-rt/lib/hwasan/hwasan_thread_list.h