diff options
author | Chris Lattner <sabre@nondot.org> | 2009-08-18 16:56:17 +0000 |
---|---|---|
committer | Chris Lattner <sabre@nondot.org> | 2009-08-18 16:56:17 +0000 |
commit | 03ded465d28a977601138d44bea694fe9a2b6294 (patch) | |
tree | d45232097eedf2b89d387011ba82a8f58d2fe6be /llvm/lib/Target/TargetLoweringObjectFile.cpp | |
parent | 8b0e164aa63b38459286c19ae46f5dd459ca4538 (diff) | |
download | bcm5719-llvm-03ded465d28a977601138d44bea694fe9a2b6294.tar.gz bcm5719-llvm-03ded465d28a977601138d44bea694fe9a2b6294.zip |
fix COFF targets (mingw/cygwin) to provide ehframe and LSDA sections
llvm-svn: 79346
Diffstat (limited to 'llvm/lib/Target/TargetLoweringObjectFile.cpp')
-rw-r--r-- | llvm/lib/Target/TargetLoweringObjectFile.cpp | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/llvm/lib/Target/TargetLoweringObjectFile.cpp b/llvm/lib/Target/TargetLoweringObjectFile.cpp index 67fbc1f6ca0..84b1b93ab01 100644 --- a/llvm/lib/Target/TargetLoweringObjectFile.cpp +++ b/llvm/lib/Target/TargetLoweringObjectFile.cpp @@ -963,6 +963,14 @@ void TargetLoweringObjectFileCOFF::Initialize(MCContext &Ctx, StaticDtorSection = getCOFFSection(".dtors", false, SectionKind::getDataRel()); + // FIXME: We're emitting LSDA info into a readonly section on COFF, even + // though it contains relocatable pointers. In PIC mode, this is probably a + // big runtime hit for C++ apps. Either the contents of the LSDA need to be + // adjusted or this should be a data section. + LSDASection = + getCOFFSection(".gcc_except_table", false, SectionKind::getReadOnly()); + EHFrameSection = + getCOFFSection(".eh_frame", false, SectionKind::getDataRel()); // Debug info. // FIXME: Don't use 'directive' mode here. |