template <class LoadInfo>
struct SegmentMerger
Defined at line 268 of file ../../src/lib/elfldltl/include/lib/elfldltl/internal/load-segment-types.h
Public Methods
template <class First, class Second>
bool Adjacent (const First & first, const Second & second)
Defined at line 277 of file ../../src/lib/elfldltl/include/lib/elfldltl/internal/load-segment-types.h
template <class First>
bool Adjacent (const First & first, const ZeroFillSegment & second)
ZeroFillSegment uses vaddr() for offset() so it might not match the
vaddr() of the preceding real data segment the generic version checks.
Defined at line 287 of file ../../src/lib/elfldltl/include/lib/elfldltl/internal/load-segment-types.h
template <class Merged, class First, class Second, typename... Args>
void Emplace (Segment & storage, const First & first, const Second & second, Args &&... args)
For each pair of segment types S1 and S2, there is a call:
bool Merge(V
&
storage, const S1
&
first, const S2
&
second);
where V is std::variant
<S1
,S2,...> (not necessarily in that order). The
first and second arguments might or might not be references (aliases) into
storage. If the first and second segments are adjacent and compatible,
this merges them by storing a new merged range into storage and then
returns true.
Defined at line 299 of file ../../src/lib/elfldltl/include/lib/elfldltl/internal/load-segment-types.h
template <class First, typename... Args>
bool MergeSame (Segment & storage, const First & first, const First & second, Args &&... args)
Helper used when details other than vaddr, offset, and memsz match.
Defined at line 308 of file ../../src/lib/elfldltl/include/lib/elfldltl/internal/load-segment-types.h
template <class... T, class First, class Second>
bool Merge (std::variant<T...> & storage, const First & first, const Second & second)
This is the fallback overload for mismatched segment types.
Defined at line 319 of file ../../src/lib/elfldltl/include/lib/elfldltl/internal/load-segment-types.h
template <class... T, class First, class Second>
bool Merge (std::variant<T...> & storage, const First & first, const Second & second)
This is the fallback overload for mismatched segment types.
Defined at line 319 of file ../../src/lib/elfldltl/include/lib/elfldltl/internal/load-segment-types.h
bool Merge (Segment & storage, const ConstantSegment & first, const ConstantSegment & second)
Identical adjacent segments merge.
Defined at line 325 of file ../../src/lib/elfldltl/include/lib/elfldltl/internal/load-segment-types.h
bool Merge (Segment & storage, const DataSegment & first, const DataSegment & second)
Identical adjacent segments merge.
Defined at line 331 of file ../../src/lib/elfldltl/include/lib/elfldltl/internal/load-segment-types.h
bool Merge (Segment & storage, const DataSegment & first, const DataWithZeroFillSegment & second)
A data segment can be merged into an adjacent data + bss segment.
Defined at line 338 of file ../../src/lib/elfldltl/include/lib/elfldltl/internal/load-segment-types.h
bool Merge (Segment & storage, const DataSegment & first, const ZeroFillSegment & second)
A data segment can be merged with an adjacent plain zero-fill segment.
Defined at line 349 of file ../../src/lib/elfldltl/include/lib/elfldltl/internal/load-segment-types.h
template <class... T, class First>
bool Merge (std::variant<T...> & storage, const First & first, const std::variant<T...> & second)
All those add up to maybe merging any two adjacent segments.
Defined at line 361 of file ../../src/lib/elfldltl/include/lib/elfldltl/internal/load-segment-types.h
template <class... T, class First>
bool Merge (std::variant<T...> & storage, const First & first, const std::variant<T...> & second)
All those add up to maybe merging any two adjacent segments.
Defined at line 361 of file ../../src/lib/elfldltl/include/lib/elfldltl/internal/load-segment-types.h
template <class... T, class Second>
bool Merge (std::variant<T...> & storage, const std::variant<T...> & first, const Second & second)
Defined at line 368 of file ../../src/lib/elfldltl/include/lib/elfldltl/internal/load-segment-types.h
template <class... T, class Second>
bool Merge (std::variant<T...> & storage, const std::variant<T...> & first, const Second & second)
Defined at line 368 of file ../../src/lib/elfldltl/include/lib/elfldltl/internal/load-segment-types.h
template <class... T>
bool Merge (std::variant<T...> & first, std::variant<T...> & second)
Defined at line 375 of file ../../src/lib/elfldltl/include/lib/elfldltl/internal/load-segment-types.h
template <class... T>
bool Merge (std::variant<T...> & first, std::variant<T...> & second)
Defined at line 375 of file ../../src/lib/elfldltl/include/lib/elfldltl/internal/load-segment-types.h
template <class... T, class Second>
bool Merge (std::variant<T...> & first, const Second & second)
Defined at line 387 of file ../../src/lib/elfldltl/include/lib/elfldltl/internal/load-segment-types.h
template <class... T, class Second>
bool Merge (std::variant<T...> & first, const Second & second)
Defined at line 387 of file ../../src/lib/elfldltl/include/lib/elfldltl/internal/load-segment-types.h