summaryrefslogtreecommitdiff
path: root/lib/MC
diff options
context:
space:
mode:
authorChris Lattner <sabre@nondot.org>2010-01-19 18:58:52 +0000
committerChris Lattner <sabre@nondot.org>2010-01-19 18:58:52 +0000
commit8a6d7ac88f8b0f37c8c1f134efb39a0725394719 (patch)
tree90d33c44b631c791a5a766c8845aded1633c7554 /lib/MC
parent6113b3d32396168f8f390343d426baa9f64e9009 (diff)
downloadllvm-8a6d7ac88f8b0f37c8c1f134efb39a0725394719.tar.gz
llvm-8a6d7ac88f8b0f37c8c1f134efb39a0725394719.tar.bz2
llvm-8a6d7ac88f8b0f37c8c1f134efb39a0725394719.tar.xz
mcstreamerize AsmPrinter::EmitZeros, at least when emitting to the
default address space. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@93890 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/MC')
-rw-r--r--lib/MC/MCAsmStreamer.cpp2
1 files changed, 2 insertions, 0 deletions
diff --git a/lib/MC/MCAsmStreamer.cpp b/lib/MC/MCAsmStreamer.cpp
index 317e74d5b3..1fd048ef66 100644
--- a/lib/MC/MCAsmStreamer.cpp
+++ b/lib/MC/MCAsmStreamer.cpp
@@ -203,6 +203,8 @@ void MCAsmStreamer::EmitValue(const MCExpr *Value, unsigned Size) {
/// EmitFill - Emit NumBytes bytes worth of the value specified by
/// FillValue. This implements directives such as '.space'.
void MCAsmStreamer::EmitFill(uint64_t NumBytes, uint8_t FillValue) {
+ if (NumBytes == 0) return;
+
if (const char *ZeroDirective = MAI.getZeroDirective()) {
OS << ZeroDirective << NumBytes;
if (FillValue != 0)