[PATCH] Generate SEH unwinding info on Win64
Saleem Abdulrasool
compnerd at compnerd.org
Tue Jun 10 18:48:14 PDT 2014
================
Comment at: lib/MC/MCObjectFileInfo.cpp:635
@@ -634,6 +634,3 @@
// adjusted or this should be a data section.
- LSDASection =
- Ctx->getCOFFSection(".gcc_except_table",
- COFF::IMAGE_SCN_CNT_INITIALIZED_DATA |
- COFF::IMAGE_SCN_MEM_READ,
- SectionKind::getReadOnly());
+ if (T.isOSWindows() && T.getArch() == Triple::x86_64) {
+ // On Windows 64 with SEH, the LSDA is emitted into the .xdata section
----------------
AFAIK, the COFF backend only supports Windows ATM. Why not make this an assert?
assert(T.isOSWindows() && "Windows is the only supported COFF target");
if (T.getArch() != Triple::x86_64) {
LSDASection = ...
}
================
Comment at: lib/Target/X86/MCTargetDesc/X86MCAsmInfo.cpp:168
@@ -164,1 +167,3 @@
+ if (Triple.isOSWindows() && Triple.getArch() == Triple::x86_64)
+ ExceptionsType = ExceptionHandling::Win64;
----------------
Convert to an assert and simplify?
http://reviews.llvm.org/D4081
More information about the llvm-commits
mailing list