1
0
mirror of https://github.com/RPCS3/llvm-mirror.git synced 2024-11-22 18:54:02 +01:00

Add support for StackMap section for ELF/Linux systems

This patch adds code to emits the StackMap section on ELF systems. This section is required to support llvm.experimental.stackmap and llvm.experimental.patchpoint intrinsics.

Reviewers: ributzka, echristo

Differential Revision: http://reviews.llvm.org/D4574

llvm-svn: 214538
This commit is contained in:
Philip Reames 2014-08-01 18:47:09 +00:00
parent 5fad1ddebc
commit 6f2c62b7c7
2 changed files with 8 additions and 0 deletions

View File

@ -583,6 +583,12 @@ void MCObjectFileInfo::InitELFMCObjectFileInfo(Triple T) {
DwarfAddrSection =
Ctx->getELFSection(".debug_addr", ELF::SHT_PROGBITS, 0,
SectionKind::getMetadata());
StackMapSection =
Ctx->getELFSection(".llvm_stackmaps", ELF::SHT_PROGBITS,
ELF::SHF_ALLOC,
SectionKind::getMetadata());
}

View File

@ -736,6 +736,8 @@ void X86AsmPrinter::EmitEndOfAsmFile(Module &M) {
}
Stubs.clear();
}
SM.serializeToStackMapSection();
}
}