LLVM 19.0.0git
Classes | Public Member Functions | Public Attributes | List of all members
llvm::objcopy::elf::Segment Class Reference

#include "ObjCopy/ELF/ELFObject.h"

Public Member Functions

 Segment (ArrayRef< uint8_t > Data)
 
 Segment ()=default
 
const SectionBasefirstSection () const
 
void removeSection (const SectionBase *Sec)
 
void addSection (const SectionBase *Sec)
 
ArrayRef< uint8_t > getContents () const
 

Public Attributes

uint32_t Type = 0
 
uint32_t Flags = 0
 
uint64_t Offset = 0
 
uint64_t VAddr = 0
 
uint64_t PAddr = 0
 
uint64_t FileSize = 0
 
uint64_t MemSize = 0
 
uint64_t Align = 0
 
uint32_t Index = 0
 
uint64_t OriginalOffset = 0
 
SegmentParentSegment = nullptr
 
ArrayRef< uint8_t > Contents
 
std::set< const SectionBase *, SectionCompare > Sections
 

Detailed Description

Definition at line 558 of file ELFObject.h.

Constructor & Destructor Documentation

◆ Segment() [1/2]

llvm::objcopy::elf::Segment::Segment ( ArrayRef< uint8_t >  Data)
inlineexplicit

Definition at line 587 of file ELFObject.h.

◆ Segment() [2/2]

llvm::objcopy::elf::Segment::Segment ( )
default

Member Function Documentation

◆ addSection()

void llvm::objcopy::elf::Segment::addSection ( const SectionBase Sec)
inline

Definition at line 597 of file ELFObject.h.

References Sections.

◆ firstSection()

const SectionBase * llvm::objcopy::elf::Segment::firstSection ( ) const
inline

Definition at line 590 of file ELFObject.h.

References Sections.

Referenced by layoutSegmentsForOnlyKeepDebug().

◆ getContents()

ArrayRef< uint8_t > llvm::objcopy::elf::Segment::getContents ( ) const
inline

Definition at line 599 of file ELFObject.h.

References Contents.

◆ removeSection()

void llvm::objcopy::elf::Segment::removeSection ( const SectionBase Sec)
inline

Definition at line 596 of file ELFObject.h.

References Sections.

Referenced by llvm::objcopy::elf::Object::removeSections().

Member Data Documentation

◆ Align

uint64_t llvm::objcopy::elf::Segment::Align = 0

Definition at line 579 of file ELFObject.h.

Referenced by layoutSegments().

◆ Contents

ArrayRef<uint8_t> llvm::objcopy::elf::Segment::Contents

Definition at line 584 of file ELFObject.h.

Referenced by getContents().

◆ FileSize

uint64_t llvm::objcopy::elf::Segment::FileSize = 0

◆ Flags

uint32_t llvm::objcopy::elf::Segment::Flags = 0

Definition at line 573 of file ELFObject.h.

◆ Index

uint32_t llvm::objcopy::elf::Segment::Index = 0

Definition at line 581 of file ELFObject.h.

◆ MemSize

uint64_t llvm::objcopy::elf::Segment::MemSize = 0

Definition at line 578 of file ELFObject.h.

Referenced by sectionWithinSegment().

◆ Offset

uint64_t llvm::objcopy::elf::Segment::Offset = 0

◆ OriginalOffset

uint64_t llvm::objcopy::elf::Segment::OriginalOffset = 0

◆ PAddr

uint64_t llvm::objcopy::elf::Segment::PAddr = 0

Definition at line 576 of file ELFObject.h.

Referenced by sectionPhysicalAddr().

◆ ParentSegment

Segment* llvm::objcopy::elf::Segment::ParentSegment = nullptr

Definition at line 583 of file ELFObject.h.

Referenced by layoutSegments(), and layoutSegmentsForOnlyKeepDebug().

◆ Sections

std::set<const SectionBase *, SectionCompare> llvm::objcopy::elf::Segment::Sections

◆ Type

uint32_t llvm::objcopy::elf::Segment::Type = 0

◆ VAddr

uint64_t llvm::objcopy::elf::Segment::VAddr = 0

Definition at line 575 of file ELFObject.h.

Referenced by layoutSegments(), and sectionWithinSegment().


The documentation for this class was generated from the following file: