Sparc actually *DOES* have a directive for emitting zeros. In fact, it requires
authorChris Lattner <sabre@nondot.org>
Wed, 15 Feb 2006 07:07:14 +0000 (07:07 +0000)
committerChris Lattner <sabre@nondot.org>
Wed, 15 Feb 2006 07:07:14 +0000 (07:07 +0000)
it, because this:

.bss
X:
.byte 0

results in the assembler warning: "initialization in bss segment".  Annoying.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@26204 91177308-0d34-0410-b5e6-96231b3b80d8

lib/Target/Sparc/SparcAsmPrinter.cpp

index 6d5c8506859ff35317f8f6912137bd53be3ba824..5eacb816ae14a02e153197db2901e24a6197a2aa 100644 (file)
@@ -40,7 +40,7 @@ namespace {
       Data16bitsDirective = "\t.half\t";
       Data32bitsDirective = "\t.word\t";
       Data64bitsDirective = 0;  // .xword is only supported by V9.
-      ZeroDirective = 0;  // no .zero or .space!
+      ZeroDirective = "\t.skip\t";
       CommentString = "!";
       ConstantPoolSection = "\t.section \".rodata\",#alloc\n";
     }