Skip to content

Commit aac505a

Browse files
author
Amirhossein Pashaeehir
committed
Remove UnwindTable dependency on CIE, and FDE (transitively on llvm/Object)
For creating new UnwindTable, two static methods was implemented inside it, to create an instance of it from a CIE or FDE. This static methods are moved out of the class as a library functions.
1 parent 5c807f2 commit aac505a

File tree

1 file changed

+24
-0
lines changed

1 file changed

+24
-0
lines changed

llvm/include/llvm/DebugInfo/DWARF/DWARFDebugFrame.h

Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -406,6 +406,30 @@ class FDE;
406406
/// machine errors, or a valid UnwindTable otherwise.
407407
LLVM_ABI Expected<UnwindTable> createUnwindTable(const FDE *Fde);
408408

409+
class CIE;
410+
411+
/// Create an UnwindTable from a Common Information Entry (CIE).
412+
///
413+
/// \param Cie The Common Information Entry to extract the table from. The
414+
/// CFIProgram is retrieved from the \a Cie object and used to create the
415+
/// UnwindTable.
416+
///
417+
/// \returns An error if the DWARF Call Frame Information opcodes have state
418+
/// machine errors, or a valid UnwindTable otherwise.
419+
Expected<UnwindTable> createUnwindTable(const CIE *Cie);
420+
421+
class FDE;
422+
423+
/// Create an UnwindTable from a Frame Descriptor Entry (FDE).
424+
///
425+
/// \param Fde The Frame Descriptor Entry to extract the table from. The
426+
/// CFIProgram is retrieved from the \a Fde object and used to create the
427+
/// UnwindTable.
428+
///
429+
/// \returns An error if the DWARF Call Frame Information opcodes have state
430+
/// machine errors, or a valid UnwindTable otherwise.
431+
Expected<UnwindTable> createUnwindTable(const FDE *Fde);
432+
409433
/// An entry in either debug_frame or eh_frame. This entry can be a CIE or an
410434
/// FDE.
411435
class FrameEntry {

0 commit comments

Comments
 (0)