aboutsummaryrefslogtreecommitdiff
path: root/llvm/lib/MC/MCObjectStreamer.cpp
diff options
context:
space:
mode:
authorRafael Espindola <rafael.espindola@gmail.com>2016-01-19 16:57:08 +0000
committerRafael Espindola <rafael.espindola@gmail.com>2016-01-19 16:57:08 +0000
commit1a7e8b4bc1cde3fea2de164c26bb499bfce3ad39 (patch)
tree28d555934883814def28ee484a60856fb9efe8b3 /llvm/lib/MC/MCObjectStreamer.cpp
parent9e8c6c1731edab16636ad4e8fc7aacb2c028f34d (diff)
downloadllvm-1a7e8b4bc1cde3fea2de164c26bb499bfce3ad39.zip
llvm-1a7e8b4bc1cde3fea2de164c26bb499bfce3ad39.tar.gz
llvm-1a7e8b4bc1cde3fea2de164c26bb499bfce3ad39.tar.bz2
Simplify MCFillFragment.
The value size was always 1 or 0, so we don't need to store it. In a no asserts build this takes the testcase of pr26208 from 11 to 10 seconds. llvm-svn: 258141
Diffstat (limited to 'llvm/lib/MC/MCObjectStreamer.cpp')
-rw-r--r--llvm/lib/MC/MCObjectStreamer.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/llvm/lib/MC/MCObjectStreamer.cpp b/llvm/lib/MC/MCObjectStreamer.cpp
index 972610ac..8ee2478 100644
--- a/llvm/lib/MC/MCObjectStreamer.cpp
+++ b/llvm/lib/MC/MCObjectStreamer.cpp
@@ -436,9 +436,9 @@ bool MCObjectStreamer::EmitRelocDirective(const MCExpr &Offset, StringRef Name,
void MCObjectStreamer::EmitFill(uint64_t NumBytes, uint8_t FillValue) {
const MCSection *Sec = getCurrentSection().first;
+ (void)Sec;
assert(Sec && "need a section");
- unsigned ItemSize = Sec->isVirtualSection() ? 0 : 1;
- insert(new MCFillFragment(FillValue, ItemSize, NumBytes));
+ insert(new MCFillFragment(FillValue, NumBytes));
}
void MCObjectStreamer::FinishImpl() {