[llvm-commits] [llvm] r74077 - in /llvm/trunk: include/llvm/MC/MCStreamer.h lib/MC/MCAsmStreamer.cpp
Daniel Dunbar
daniel at zuster.org
Wed Jun 24 09:36:58 PDT 2009
Author: ddunbar
Date: Wed Jun 24 11:36:52 2009
New Revision: 74077
URL: http://llvm.org/viewvc/llvm-project?rev=74077&view=rev
Log:
MCStreamer: Add a few more "symbol attributes".
Modified:
llvm/trunk/include/llvm/MC/MCStreamer.h
llvm/trunk/lib/MC/MCAsmStreamer.cpp
Modified: llvm/trunk/include/llvm/MC/MCStreamer.h
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/include/llvm/MC/MCStreamer.h?rev=74077&r1=74076&r2=74077&view=diff
==============================================================================
--- llvm/trunk/include/llvm/MC/MCStreamer.h (original)
+++ llvm/trunk/include/llvm/MC/MCStreamer.h Wed Jun 24 11:36:52 2009
@@ -23,9 +23,21 @@
class MCStreamer {
public:
enum SymbolAttr {
- Global,
- Weak,
- PrivateExtern
+ Global, /// .globl
+ Hidden, /// .hidden (ELF)
+ IndirectSymbol, /// .indirect_symbol (Apple)
+ Internal, /// .internal (ELF)
+ LazyReference, /// .lazy_reference (Apple)
+ NoDeadStrip, /// .no_dead_strip (Apple)
+ PrivateExtern, /// .private_extern (Apple)
+ Protected, /// .protected (ELF)
+ Reference, /// .reference (Apple)
+ Weak, /// .weak
+ WeakDefinition, /// .weak_definition (Apple)
+ WeakReference, /// .weak_reference (Apple)
+
+ SymbolAttrFirst = Global,
+ SymbolAttrLast = WeakReference
};
private:
Modified: llvm/trunk/lib/MC/MCAsmStreamer.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/MC/MCAsmStreamer.cpp?rev=74077&r1=74076&r2=74077&view=diff
==============================================================================
--- llvm/trunk/lib/MC/MCAsmStreamer.cpp (original)
+++ llvm/trunk/lib/MC/MCAsmStreamer.cpp Wed Jun 24 11:36:52 2009
@@ -102,8 +102,17 @@
SymbolAttr Attribute) {
switch (Attribute) {
case Global: OS << ".globl"; break;
- case Weak: OS << ".weak"; break;
+ case Hidden: OS << ".hidden"; break;
+ case IndirectSymbol: OS << ".indirect_symbol"; break;
+ case Internal: OS << ".internal"; break;
+ case LazyReference: OS << ".lazy_reference"; break;
+ case NoDeadStrip: OS << ".no_dead_strip"; break;
case PrivateExtern: OS << ".private_extern"; break;
+ case Protected: OS << ".protected"; break;
+ case Reference: OS << ".reference"; break;
+ case Weak: OS << ".weak"; break;
+ case WeakDefinition: OS << ".weak_definition"; break;
+ case WeakReference: OS << ".weak_reference"; break;
}
OS << ' ' << Symbol->getName() << '\n';
More information about the llvm-commits
mailing list