llvm.org GIT mirror llvm / 3b5d8b3
Merging r196168: ------------------------------------------------------------------------ r196168 | rafael.espindola | 2013-12-02 18:04:51 -0500 (Mon, 02 Dec 2013) | 2 lines Convert two char* that are only ever used as booleans to bool. ------------------------------------------------------------------------ git-svn-id: https://llvm.org/svn/llvm-project/llvm/branches/release_34@205764 91177308-0d34-0410-b5e6-96231b3b80d8 Tom Stellard 6 years ago
6 changed file(s) with 14 addition(s) and 17 deletion(s). Raw diff Collapse all Expand all
265265 /// global as being a weak undefined symbol.
266266 const char *WeakRefDirective; // Defaults to NULL.
267267
268 /// WeakDefDirective - This directive, if non-null, is used to declare a
269 /// global as being a weak defined symbol.
270 const char *WeakDefDirective; // Defaults to NULL.
271
272 /// LinkOnceDirective - This directive, if non-null is used to declare a
273 /// global as being a weak defined symbol. This is used on cygwin/mingw.
274 const char *LinkOnceDirective; // Defaults to NULL.
268 /// True if we have a directive to declare a global as being a weak
269 /// defined symbol.
270 bool HasWeakDefDirective; // Defaults to false.
271
272 /// True if we have a .linkonce directive. This is used on cygwin/mingw.
273 bool HasLinkOnceDirective; // Defaults to false.
275274
276275 /// HiddenVisibilityAttr - This attribute, if not MCSA_Invalid, is used to
277276 /// declare a symbol as having hidden visibility.
496495 bool hasIdentDirective() const { return HasIdentDirective; }
497496 bool hasNoDeadStrip() const { return HasNoDeadStrip; }
498497 const char *getWeakRefDirective() const { return WeakRefDirective; }
499 const char *getWeakDefDirective() const { return WeakDefDirective; }
500 const char *getLinkOnceDirective() const { return LinkOnceDirective; }
498 bool hasWeakDefDirective() const { return HasWeakDefDirective; }
499 bool hasLinkOnceDirective() const { return HasLinkOnceDirective; }
501500
502501 MCSymbolAttr getHiddenVisibilityAttr() const { return HiddenVisibilityAttr;}
503502 MCSymbolAttr getHiddenDeclarationVisibilityAttr() const {
221221 case GlobalValue::WeakAnyLinkage:
222222 case GlobalValue::WeakODRLinkage:
223223 case GlobalValue::LinkerPrivateWeakLinkage:
224 if (MAI->getWeakDefDirective() != 0) {
224 if (MAI->hasWeakDefDirective()) {
225225 // .globl _foo
226226 OutStreamer.EmitSymbolAttribute(GVSym, MCSA_Global);
227227
242242 OutStreamer.EmitSymbolAttribute(GVSym, MCSA_WeakDefinition);
243243 else
244244 OutStreamer.EmitSymbolAttribute(GVSym, MCSA_WeakDefAutoPrivate);
245 } else if (MAI->getLinkOnceDirective() != 0) {
245 } else if (MAI->hasLinkOnceDirective()) {
246246 // .globl _foo
247247 OutStreamer.EmitSymbolAttribute(GVSym, MCSA_Global);
248248 //NOTE: linkonce is handled by the section the symbol was assigned to.
7575 HasIdentDirective = false;
7676 HasNoDeadStrip = false;
7777 WeakRefDirective = 0;
78 WeakDefDirective = 0;
79 LinkOnceDirective = 0;
78 HasWeakDefDirective = false;
79 HasLinkOnceDirective = false;
8080 HiddenVisibilityAttr = MCSA_Hidden;
8181 HiddenDeclarationVisibilityAttr = MCSA_Hidden;
8282 ProtectedVisibilityAttr = MCSA_Protected;
2626 HasSingleParameterDotFile = false;
2727 PrivateGlobalPrefix = "L"; // Prefix for private global symbols
2828 WeakRefDirective = "\t.weak\t";
29 LinkOnceDirective = "\t.linkonce discard\n";
29 HasLinkOnceDirective = true;
3030
3131 // Doesn't support visibility:
3232 HiddenVisibilityAttr = HiddenDeclarationVisibilityAttr = MCSA_Invalid;
3535 InlineAsmEnd = " InlineAsm End";
3636
3737 // Directives:
38 WeakDefDirective = "\t.weak_definition ";
38 HasWeakDefDirective = true;
3939 WeakRefDirective = "\t.weak_reference ";
4040 ZeroDirective = "\t.space\t"; // ".space N" emits N zeros.
4141 HasMachoZeroFillDirective = true; // Uses .zerofill
1212 using namespace llvm;
1313 AMDGPUMCAsmInfo::AMDGPUMCAsmInfo(StringRef &TT) : MCAsmInfo() {
1414 HasSingleParameterDotFile = false;
15 WeakDefDirective = 0;
1615 //===------------------------------------------------------------------===//
1716 HasSubsectionsViaSymbols = true;
1817 HasMachoZeroFillDirective = false;
5756 HasDotTypeDotSizeDirective = false;
5857 HasNoDeadStrip = true;
5958 WeakRefDirective = ".weakref\t";
60 LinkOnceDirective = 0;
6159 //===--- Dwarf Emission Directives -----------------------------------===//
6260 HasLEB128 = true;
6361 SupportsDebugInformation = true;