From 27e7ffc7d40e693e6c2eed6b0ffc409e28199dee Mon Sep 17 00:00:00 2001 From: Eric Christopher Date: Thu, 20 May 2010 00:49:07 +0000 Subject: Partial code for emitting thread local bss data. llvm-svn: 104197 --- llvm/lib/CodeGen/AsmPrinter/AsmPrinter.cpp | 7 +++++++ 1 file changed, 7 insertions(+) (limited to 'llvm/lib/CodeGen') diff --git a/llvm/lib/CodeGen/AsmPrinter/AsmPrinter.cpp b/llvm/lib/CodeGen/AsmPrinter/AsmPrinter.cpp index bd7d0e5324a..50a50750e8b 100644 --- a/llvm/lib/CodeGen/AsmPrinter/AsmPrinter.cpp +++ b/llvm/lib/CodeGen/AsmPrinter/AsmPrinter.cpp @@ -310,6 +310,13 @@ void AsmPrinter::EmitGlobalVariable(const GlobalVariable *GV) { OutStreamer.EmitZerofill(TheSection, GVSym, Size, 1 << AlignLog); return; } + + // Handle the tbss directive on darwin which is a thread local bss directive + // like zerofill. + if (GVKind.isThreadBSS() && MAI->hasMachoTBSSDirective()) { + OutStreamer.EmitTBSSSymbol(TheSection, GVSym, Size, 1 << AlignLog); + return; + } OutStreamer.SwitchSection(TheSection); -- cgit v1.2.3