Home
last modified time | relevance | path

Searched refs:Seg (Results 1 – 25 of 36) sorted by relevance

12

/llvm-project-15.0.7/llvm/lib/ExecutionEngine/JITLink/
H A DJITLinkMemoryManager.cpp57 Seg.ContentSize = alignToBlock(Seg.ContentSize, *B); in BasicLayout()
59 Seg.Alignment = std::max(Seg.Alignment, Align(B->getAlignment())); in BasicLayout()
66 Seg.Alignment = std::max(Seg.Alignment, Align(B->getAlignment())); in BasicLayout()
68 Seg.ZeroFillSize = SegEndOffset - Seg.ContentSize; in BasicLayout()
105 assert(!(Seg.ContentBlocks.empty() && Seg.ZeroFillBlocks.empty()) && in apply()
110 Seg.Addr = alignToBlock(Seg.Addr, *B); in apply()
111 Seg.NextWorkingMemOffset = alignToBlock(Seg.NextWorkingMemOffset, *B); in apply()
122 {Seg.WorkingMem + Seg.NextWorkingMemOffset, B->getSize()}); in apply()
128 Seg.Addr = alignToBlock(Seg.Addr, *B); in apply()
285 alignTo(Seg.ContentSize + Seg.ZeroFillSize, MemMgr.PageSize); in applyProtections()
[all …]
/llvm-project-15.0.7/llvm/lib/ExecutionEngine/Orc/TargetProcess/
H A DSimpleExecutorMemoryManager.cpp51 for (auto &Seg : FR.Segments) in finalize() local
52 Base = std::min(Base, Seg.Addr); in finalize()
110 for (auto &Seg : FR.Segments) { in finalize() local
113 if (LLVM_UNLIKELY(Seg.Size < Seg.Content.size())) in finalize()
117 Seg.Addr.getValue(), Seg.Content.size(), Seg.Size), in finalize()
119 ExecutorAddr SegEnd = Seg.Addr + ExecutorAddrDiff(Seg.Size); in finalize()
128 char *Mem = Seg.Addr.toPtr<char *>(); in finalize()
129 if (!Seg.Content.empty()) in finalize()
130 memcpy(Mem, Seg.Content.data(), Seg.Content.size()); in finalize()
131 memset(Mem + Seg.Content.size(), 0, Seg.Size - Seg.Content.size()); in finalize()
[all …]
/llvm-project-15.0.7/llvm/unittests/ExecutionEngine/Orc/
H A DEPCGenericJITLinkMemoryManagerTest.cpp42 for (auto &Seg : FR.Segments) { in finalize() local
43 char *Mem = Seg.Addr.toPtr<char *>(); in finalize()
44 memcpy(Mem, Seg.Content.data(), Seg.Content.size()); in finalize()
45 memset(Mem + Seg.Content.size(), 0, Seg.Size - Seg.Content.size()); in finalize()
46 assert(Seg.Size <= std::numeric_limits<size_t>::max()); in finalize()
48 {Mem, static_cast<size_t>(Seg.Size)}, in finalize()
49 tpctypes::fromWireProtectionFlags(Seg.Prot))) in finalize()
51 if (Seg.Prot & tpctypes::WPF_Exec) in finalize()
52 sys::Memory::InvalidateInstructionCache(Mem, Seg.Size); in finalize()
/llvm-project-15.0.7/llvm/lib/ExecutionEngine/Orc/
H A DMapperJITLinkMemoryManager.cpp94 auto &Seg = KV.second; in allocate() local
96 auto TotalSize = Seg.ContentSize + Seg.ZeroFillSize; in allocate()
98 Seg.Addr = NextSegAddr; in allocate()
99 Seg.WorkingMem = Mapper->prepare(NextSegAddr, TotalSize); in allocate()
104 SI.Offset = Seg.Addr - Result->Start; in allocate()
105 SI.ContentSize = Seg.ContentSize; in allocate()
106 SI.ZeroFillSize = Seg.ZeroFillSize; in allocate()
108 SI.WorkingMem = Seg.WorkingMem; in allocate()
H A DEPCGenericRTDyldMemoryManager.cpp71 auto &Seg = Unmapped.back().CodeAllocs; in allocateCodeSection() local
72 Seg.emplace_back(Size, Alignment); in allocateCodeSection()
74 alignAddr(Seg.back().Contents.get(), Align(Alignment))); in allocateCodeSection()
88 auto &Seg = in allocateDataSection() local
91 Seg.emplace_back(Size, Alignment); in allocateDataSection()
93 alignAddr(Seg.back().Contents.get(), Align(Alignment))); in allocateDataSection()
242 auto &Seg = FR.Segments.back(); in finalizeMemory() local
243 Seg.Prot = SegProts[I]; in finalizeMemory()
244 Seg.Addr = RemoteAddrs[I]->Start; in finalizeMemory()
246 Seg.Size = alignTo(Seg.Size, SecAlloc.Align); in finalizeMemory()
[all …]
H A DEPCGenericJITLinkMemoryManager.cpp152 auto &Seg = KV.second; in completeAllocation() local
154 Seg.Addr = NextSegAddr; in completeAllocation()
155 KV.second.WorkingMem = BL.getGraph().allocateBuffer(Seg.ContentSize).data(); in completeAllocation()
157 alignTo(Seg.ContentSize + Seg.ZeroFillSize, EPC.getPageSize())); in completeAllocation()
160 SegInfo.ContentSize = Seg.ContentSize; in completeAllocation()
161 SegInfo.ZeroFillSize = Seg.ZeroFillSize; in completeAllocation()
162 SegInfo.Addr = ExecutorAddr(Seg.Addr); in completeAllocation()
163 SegInfo.WorkingMem = Seg.WorkingMem; in completeAllocation()
/llvm-project-15.0.7/llvm/tools/obj2yaml/
H A Dwasm2yaml.cpp333 WasmYAML::ElemSegment Seg; in dump() local
334 Seg.Flags = Segment.Flags; in dump()
335 Seg.TableNumber = Segment.TableNumber; in dump()
336 Seg.ElemKind = Segment.ElemKind; in dump()
338 if (Seg.Offset.Extended) { in dump()
341 Seg.Offset.Inst = Segment.Offset.Inst; in dump()
344 ElemSec->Segments.push_back(Seg); in dump()
369 WasmYAML::DataSegment Seg; in dump() local
371 Seg.InitFlags = Segment.Data.InitFlags; in dump()
374 if (Seg.Offset.Extended) { in dump()
[all …]
/llvm-project-15.0.7/llvm/tools/llvm-size/
H A Dllvm-size.cpp225 << Seg.fileoff << ")"; in printDarwinSectionSizes()
227 total += Seg.vmsize; in printDarwinSectionSizes()
243 if (Seg.nsects != 0) in printDarwinSectionSizes()
254 total += Seg.vmsize; in printDarwinSectionSizes()
271 if (Seg.nsects != 0) in printDarwinSectionSizes()
306 total_text += Seg.vmsize; in printDarwinSegmentSizes()
308 total_data += Seg.vmsize; in printDarwinSegmentSizes()
310 total_objc += Seg.vmsize; in printDarwinSegmentSizes()
332 total_text += Seg.vmsize; in printDarwinSegmentSizes()
334 total_data += Seg.vmsize; in printDarwinSegmentSizes()
[all …]
/llvm-project-15.0.7/llvm/tools/llvm-readobj/
H A DWasmDumper.cpp177 const wasm::WasmDataSegment &Seg = Segment.Data; in printSectionHeaders() local
179 if (!Seg.Name.empty()) in printSectionHeaders()
180 W.printString("Name", Seg.Name); in printSectionHeaders()
181 W.printNumber("Size", static_cast<uint64_t>(Seg.Content.size())); in printSectionHeaders()
182 if (Seg.Offset.Extended) in printSectionHeaders()
184 else if (Seg.Offset.Inst.Opcode == wasm::WASM_OPCODE_I32_CONST) in printSectionHeaders()
185 W.printNumber("Offset", Seg.Offset.Inst.Value.Int32); in printSectionHeaders()
186 else if (Seg.Offset.Inst.Opcode == wasm::WASM_OPCODE_I64_CONST) in printSectionHeaders()
187 W.printNumber("Offset", Seg.Offset.Inst.Value.Int64); in printSectionHeaders()
188 else if (Seg.Offset.Inst.Opcode == wasm::WASM_OPCODE_GLOBAL_GET) { in printSectionHeaders()
[all …]
/llvm-project-15.0.7/llvm/lib/ObjCopy/MachO/
H A DMachOObject.cpp158 constructSegment(SegmentType &Seg, llvm::MachO::LoadCommandType CmdType, in constructSegment() argument
160 assert(SegName.size() <= sizeof(Seg.segname) && "too long segment name"); in constructSegment()
161 memset(&Seg, 0, sizeof(SegmentType)); in constructSegment()
162 Seg.cmd = CmdType; in constructSegment()
163 strncpy(Seg.segname, SegName.data(), SegName.size()); in constructSegment()
164 Seg.maxprot |= in constructSegment()
166 Seg.initprot |= in constructSegment()
168 Seg.vmaddr = SegVMAddr; in constructSegment()
169 Seg.vmsize = SegVMSize; in constructSegment()
/llvm-project-15.0.7/llvm/lib/ObjCopy/ELF/
H A DELFObject.cpp41 Phdr.p_type = Seg.Type; in writePhdr()
329 if (Seg && Seg->Type != ELF::PT_LOAD) in sectionPhysicalAddr()
330 Seg = nullptr; in sectionPhysicalAddr()
331 return Seg ? Seg->PAddr + Sec->OriginalOffset - Seg->OriginalOffset in sectionPhysicalAddr()
1178 Seg.VAddr + Seg.MemSize >= Sec.Addr + SecSize; in sectionWithinSegment()
1182 Seg.Offset + Seg.FileSize >= Sec.OriginalOffset + SecSize; in sectionWithinSegment()
2000 writePhdr(Seg); in writePhdrs()
2247 Seg->Offset = in layoutSegments()
2250 Seg->Offset = in layoutSegments()
2253 Offset = std::max(Offset, Seg->Offset + Seg->FileSize); in layoutSegments()
[all …]
/llvm-project-15.0.7/llvm/tools/dsymutil/
H A DMachOUtils.cpp125 Seg64.cmd = Seg.cmd; in adaptFrom32bits()
126 Seg64.cmdsize = Seg.cmdsize; in adaptFrom32bits()
127 memcpy(Seg64.segname, Seg.segname, sizeof(Seg.segname)); in adaptFrom32bits()
128 Seg64.vmaddr = Seg.vmaddr; in adaptFrom32bits()
129 Seg64.vmsize = Seg.vmsize; in adaptFrom32bits()
130 Seg64.fileoff = Seg.fileoff; in adaptFrom32bits()
131 Seg64.filesize = Seg.filesize; in adaptFrom32bits()
132 Seg64.maxprot = Seg.maxprot; in adaptFrom32bits()
133 Seg64.initprot = Seg.initprot; in adaptFrom32bits()
134 Seg64.nsects = Seg.nsects; in adaptFrom32bits()
[all …]
/llvm-project-15.0.7/llvm/lib/Target/Hexagon/
H A DHexagonVectorCombine.cpp201 Segment Seg; // Value segment. member
281 OS << " @" << B.Pos << " [" << B.Seg.Start << ',' << B.Seg.Size << "] " in operator <<()
282 << *B.Seg.Val << '\n'; in operator <<()
353 Section.Blocks.emplace_back(B.Seg.Val, B.Seg.Start + Off, R - L, L); in section()
368 Values[i] = Blocks[i].Seg.Val; in values()
807 ASpan[j].Seg.Val = HVC.vralignb(Builder, ASpan[j].Seg.Val, in realignGroup()
818 HVC.insertb(Builder, Accum, Pay, S.Seg.Start, S.Seg.Size, S.Pos); in realignGroup()
859 S.Seg.Start, S.Seg.Size, S.Pos); in realignGroup()
861 S.Seg.Start, S.Seg.Size, S.Pos); in realignGroup()
870 ASpanV[j - 1].Seg.Val = HVC.vlalignb(Builder, ASpanV[j - 1].Seg.Val, in realignGroup()
[all …]
H A DHexagonExpandCondsets.cpp417 for (auto &Seg : Range) { in updateDeadsInRange() local
418 if (!Seg.start.isRegister()) in updateDeadsInRange()
420 MachineInstr *DefI = LIS->getInstructionFromIndex(Seg.start); in updateDeadsInRange()
423 PredDefs.push_back(Seg.start); in updateDeadsInRange()
471 for (auto &Seg : Range) { in updateDeadsInRange() local
472 if (!Seg.start.isRegister()) in updateDeadsInRange()
474 MachineInstr *DefI = LIS->getInstructionFromIndex(Seg.start); in updateDeadsInRange()
477 if (P.second && Seg.end.isDead()) { in updateDeadsInRange()
488 for (auto &Seg : Range) { in updateDeadsInRange() local
489 if (!Seg.start.isRegister() || !Range.liveAt(Seg.start.getPrevSlot())) in updateDeadsInRange()
[all …]
/llvm-project-15.0.7/llvm/lib/CodeGen/
H A DLiveInterval.cpp1171 LR->addSegmentToSet(Seg); in add()
1185 LastStart = Seg.start; in add()
1195 ReadI = WriteI = LR->find(Seg.start); in add()
1207 if (ReadI->end >= Seg.end) in add()
1210 Seg.start = ReadI->start; in add()
1216 Seg.end = std::max(Seg.end, ReadI->end); in add()
1222 Seg.start = Spills.back().start; in add()
1223 Seg.end = std::max(Spills.back().end, Seg.end); in add()
1235 *WriteI++ = Seg; in add()
1241 LR->segments.push_back(Seg); in add()
[all …]
H A DLiveRegMatrix.cpp214 LiveRange::Segment Seg(Start, End, &valno); in checkInterference() local
216 LR.addSegment(Seg); in checkInterference()
H A DLiveRangeCalc.cpp161 LiveRange::Segment &Seg = *std::prev(UB); in isDefOnEntry() local
162 if (Seg.end > Begin) { in isDefOnEntry()
167 if (LR.isUndefIn(Undefs, Seg.end, End)) in isDefOnEntry()
H A DVirtRegMap.cpp365 for (const auto &Seg : LI) { in addMBBLiveIns() local
366 I = Indexes->advanceMBBIndex(I, Seg.start); in addMBBLiveIns()
367 for (; I != Indexes->MBBIndexEnd() && I->first < Seg.end; ++I) { in addMBBLiveIns()
/llvm-project-15.0.7/llvm/include/llvm/ProfileData/
H A DRawMemProfReader.h76 llvm::SmallVectorImpl<SegmentEntry> &Seg,
79 : Symbolizer(std::move(Sym)), SegmentInfo(Seg.begin(), Seg.end()), in Symbolizer()
/llvm-project-15.0.7/llvm/include/llvm/CodeGen/
H A DLiveInterval.h630 auto Seg = segments.begin(), EndSeg = segments.end(); in findIndexesLiveAt() local
632 while (Idx != EndIdx && Seg != EndSeg) { in findIndexesLiveAt()
635 if (Seg->end <= *Idx) { in findIndexesLiveAt()
636 Seg = in findIndexesLiveAt()
637 std::upper_bound(++Seg, EndSeg, *Idx, [=](auto V, const auto &S) { in findIndexesLiveAt()
640 if (Seg == EndSeg) in findIndexesLiveAt()
643 auto NotLessStart = std::lower_bound(Idx, EndIdx, Seg->start); in findIndexesLiveAt()
646 auto NotLessEnd = std::lower_bound(NotLessStart, EndIdx, Seg->end); in findIndexesLiveAt()
652 ++Seg; in findIndexesLiveAt()
/llvm-project-15.0.7/llvm/unittests/ProfileData/
H A DMemProfTest.cpp160 auto Seg = makeSegments(); in TEST() local
162 RawMemProfReader Reader(std::move(Symbolizer), Seg, Prof, CSM, in TEST()
337 auto Seg = makeSegments(); in TEST() local
339 RawMemProfReader Reader(std::move(Symbolizer), Seg, Prof, CSM); in TEST()
/llvm-project-15.0.7/llvm/tools/llvm-jitlink/
H A Dllvm-jitlink.cpp513 auto &Seg = KV.second; in allocate() local
518 alignTo(Seg.ContentSize + Seg.ZeroFillSize, Parent.PageSize); in allocate()
519 sys::MemoryBlock MB(Seg.WorkingMem, SegSize); in allocate()
588 auto &Seg = KV.second; in allocate() local
599 Seg.WorkingMem = SegAddr.toPtr<char *>(); in allocate()
600 Seg.Addr = SegAddr + SlabDelta; in allocate()
602 SegAddr += alignTo(Seg.ContentSize + Seg.ZeroFillSize, PageSize); in allocate()
605 if (Seg.ZeroFillSize != 0) in allocate()
606 memset(Seg.WorkingMem + Seg.ContentSize, 0, Seg.ZeroFillSize); in allocate()
/llvm-project-15.0.7/llvm/tools/llvm-nm/
H A Dllvm-nm.cpp1218 MachO::segment_command Seg = MachO.getSegmentLoadCommand(Command); in dumpSymbolsFromDLInfoMachO() local
1219 if (Seg.fileoff == 0 && Seg.filesize != 0) { in dumpSymbolsFromDLInfoMachO()
1220 BaseSegmentAddress = Seg.vmaddr; in dumpSymbolsFromDLInfoMachO()
1224 MachO::segment_command_64 Seg = MachO.getSegment64LoadCommand(Command); in dumpSymbolsFromDLInfoMachO() local
1225 if (Seg.fileoff == 0 && Seg.filesize != 0) { in dumpSymbolsFromDLInfoMachO()
1226 BaseSegmentAddress = Seg.vmaddr; in dumpSymbolsFromDLInfoMachO()
/llvm-project-15.0.7/llvm/include/llvm/Support/
H A DJSON.h641 Path(Root &R) : Parent(nullptr), Seg(&R) {} in Path()
671 Segment Seg; variable
673 Path(const Path *Parent, Segment S) : Parent(Parent), Seg(S) {} in Path()
/llvm-project-15.0.7/llvm/tools/llvm-objdump/
H A DMachODump.cpp673 for (unsigned J = 0; J < Seg.nsects; ++J) { in PrintIndirectSymbols()
701 for (unsigned J = 0; J < Seg.nsects; ++J) { in PrintIndirectSymbols()
1009 for (unsigned J = 0; J < Seg.nsects; ++J) { in PrintRelocations()
1029 for (unsigned J = 0; J < Seg.nsects; ++J) { in PrintRelocations()
3030 for (unsigned J = 0; J < Seg.nsects; ++J) { in GuessCstringPointer()
3051 for (unsigned J = 0; J < Seg.nsects; ++J) { in GuessCstringPointer()
3086 for (unsigned J = 0; J < Seg.nsects; ++J) { in GuessIndirectSymbol()
10298 if (Seg.fileoff == 0 && Seg.filesize != 0) { in printMachOExportsTrie()
10299 BaseSegmentAddress = Seg.vmaddr; in printMachOExportsTrie()
10304 if (Seg.fileoff == 0 && Seg.filesize != 0) { in printMachOExportsTrie()
[all …]

12