mirror of
https://github.com/revng/revng
synced 2026-06-21 14:07:57 +00:00
SegmentInfo::generateName: move to BinaryFile.cpp
This commit is contained in:
@@ -346,16 +346,6 @@ CodeGenerator::CodeGenerator(BinaryFile &Binary,
|
||||
NeededLibsStream << Library << "\n";
|
||||
}
|
||||
|
||||
std::string SegmentInfo::generateName() {
|
||||
// Create name from start and size
|
||||
std::stringstream NameStream;
|
||||
NameStream << "o_" << (IsReadable ? "r" : "") << (IsWriteable ? "w" : "")
|
||||
<< (IsExecutable ? "x" : "") << "_0x" << std::hex
|
||||
<< StartVirtualAddress.address();
|
||||
|
||||
return NameStream.str();
|
||||
}
|
||||
|
||||
static BasicBlock *replaceFunction(Function *ToReplace) {
|
||||
// Save metadata
|
||||
SmallVector<std::pair<unsigned, MDNode *>, 4> SavedMetadata;
|
||||
|
||||
Reference in New Issue
Block a user