mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2025-06-11 21:38:19 +00:00
Disable the fix for pr20793 because of a gnu ld bug.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@217211 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
@ -31,6 +31,7 @@
|
||||
#include "llvm/MC/MCSectionMachO.h"
|
||||
#include "llvm/MC/MCStreamer.h"
|
||||
#include "llvm/MC/MCSymbol.h"
|
||||
#include "llvm/Support/CommandLine.h"
|
||||
#include "llvm/Support/Dwarf.h"
|
||||
#include "llvm/Support/ELF.h"
|
||||
#include "llvm/Support/ErrorHandling.h"
|
||||
@ -41,6 +42,13 @@
|
||||
using namespace llvm;
|
||||
using namespace dwarf;
|
||||
|
||||
// Disabled by default because it hits bug 17350 in GNU ld (gold is fine)
|
||||
static cl::opt<bool>
|
||||
EnableStructorCOMDAT("enable-structor-comdat", cl::Hidden,
|
||||
cl::desc("Use comdats to keep only one copy of a "
|
||||
"constructor/destructor invocation"),
|
||||
cl::init(false));
|
||||
|
||||
//===----------------------------------------------------------------------===//
|
||||
// ELF
|
||||
//===----------------------------------------------------------------------===//
|
||||
@ -363,6 +371,9 @@ static const MCSectionELF *getStaticStructorSection(MCContext &Ctx,
|
||||
bool IsCtor,
|
||||
unsigned Priority,
|
||||
const MCSymbol *KeySym) {
|
||||
if (!EnableStructorCOMDAT)
|
||||
KeySym = nullptr;
|
||||
|
||||
std::string Name;
|
||||
unsigned Type;
|
||||
unsigned Flags = ELF::SHF_ALLOC | ELF::SHF_WRITE;
|
||||
|
Reference in New Issue
Block a user