diff options
| author | Bill Wendling <isanbard@gmail.com> | 2010-02-25 00:24:52 +0000 |
|---|---|---|
| committer | Bill Wendling <isanbard@gmail.com> | 2010-02-25 00:24:52 +0000 |
| commit | 98aa2450708a26fe6f3d107d90bcd6657e85cf83 (patch) | |
| tree | c945f9b70e950aa9259e4d215a0bb87ca5f073cf | |
| parent | d55522f02edd8f8adf2c73d8fcf60aa9ed4d750f (diff) | |
| download | bcm5719-llvm-98aa2450708a26fe6f3d107d90bcd6657e85cf83.tar.gz bcm5719-llvm-98aa2450708a26fe6f3d107d90bcd6657e85cf83.zip | |
MC'ize padding when padding the ULEB128 value.
llvm-svn: 97087
| -rw-r--r-- | llvm/lib/CodeGen/AsmPrinter/DwarfPrinter.cpp | 12 |
1 files changed, 5 insertions, 7 deletions
diff --git a/llvm/lib/CodeGen/AsmPrinter/DwarfPrinter.cpp b/llvm/lib/CodeGen/AsmPrinter/DwarfPrinter.cpp index 25337cb765b..28ff0ebb93f 100644 --- a/llvm/lib/CodeGen/AsmPrinter/DwarfPrinter.cpp +++ b/llvm/lib/CodeGen/AsmPrinter/DwarfPrinter.cpp @@ -183,13 +183,11 @@ void DwarfPrinter::EmitULEB128(unsigned Value, const char *Desc, Asm->OutStreamer.EmitIntValue(Byte, 1, /*addrspace*/0); } while (Value); - if (PadTo) - while (PadTo--) { - unsigned char Byte = (PadTo ? 0x80 : 0x00); - if (Asm->VerboseAsm) - Asm->OutStreamer.AddComment("Padding"); - Asm->OutStreamer.EmitIntValue(Byte, 1, /*addrspace*/0); - } + if (PadTo) { + if (PadTo > 1) + Asm->OutStreamer.EmitFill(PadTo - 1, 0x80/*fillval*/, 0/*addrspace*/); + Asm->OutStreamer.EmitFill(1, 0/*fillval*/, 0/*addrspace*/); + } } |

