aboutsummaryrefslogtreecommitdiff
path: root/llvm/lib/Target/RISCV/Disassembler/RISCVDisassembler.cpp
diff options
context:
space:
mode:
authorFelipe de Azevedo Piovezan <fpiovezan@apple.com>2023-06-15 08:18:51 -0400
committerFelipe de Azevedo Piovezan <fpiovezan@apple.com>2023-06-21 06:44:56 -0400
commit15a1f7f6f7be103820b6a0c4caea1ec58c01d906 (patch)
tree79186a103b6cb8fa7df77faacea5a17acda76649 /llvm/lib/Target/RISCV/Disassembler/RISCVDisassembler.cpp
parentecb07f481be9bf0399c279a3b3f9db01bc4e48bd (diff)
downloadllvm-15a1f7f6f7be103820b6a0c4caea1ec58c01d906.zip
llvm-15a1f7f6f7be103820b6a0c4caea1ec58c01d906.tar.gz
llvm-15a1f7f6f7be103820b6a0c4caea1ec58c01d906.tar.bz2
[AppleTables] Implement iterator over all entries in table
This commit adds functionality to the Apple Accelerator table allowing iteration over all elements in the table. Our iterators look like streaming iterators: when we increment the iterator we check if there is still enough data in the "stream" (in our case, the blob of data of the accelerator table) and extract the next entry. If any failures occur, we immediately set the iterator to be the end iterator. Since the ultimate user of this functionality is LLDB, there are roughly two iteration methods we want support: one that also loads the name of each entry, and one which does not. Loading names is measurably slower (one order the magnitude) than only loading DIEs, so we used some template metaprograming to implement both iteration methods. Depends on D153066 Differential Revision: https://reviews.llvm.org/D153066
Diffstat (limited to 'llvm/lib/Target/RISCV/Disassembler/RISCVDisassembler.cpp')
0 files changed, 0 insertions, 0 deletions