aboutsummaryrefslogtreecommitdiff
path: root/llvm/lib/MC/MCObjectStreamer.cpp
diff options
context:
space:
mode:
authorPetr Hosek <phosek@chromium.org>2016-05-27 19:58:05 +0000
committerPetr Hosek <phosek@chromium.org>2016-05-27 19:58:05 +0000
commit97859ccd5194a51f0eed7f1499b4ea320001da4d (patch)
tree4bfe6a9f6926b6ca4262d7a9d101b2e418082240 /llvm/lib/MC/MCObjectStreamer.cpp
parentd99892bdb0d2152ce15c475ca9fcfdecfbea15ed (diff)
downloadllvm-97859ccd5194a51f0eed7f1499b4ea320001da4d.zip
llvm-97859ccd5194a51f0eed7f1499b4ea320001da4d.tar.gz
llvm-97859ccd5194a51f0eed7f1499b4ea320001da4d.tar.bz2
Revert "[MC] Support symbolic expressions in assembly directives"
This reverts commit r271028, it causes the directive_fill.s to fail. llvm-svn: 271038
Diffstat (limited to 'llvm/lib/MC/MCObjectStreamer.cpp')
-rw-r--r--llvm/lib/MC/MCObjectStreamer.cpp38
1 files changed, 0 insertions, 38 deletions
diff --git a/llvm/lib/MC/MCObjectStreamer.cpp b/llvm/lib/MC/MCObjectStreamer.cpp
index bf7d0f2..b90f0a8 100644
--- a/llvm/lib/MC/MCObjectStreamer.cpp
+++ b/llvm/lib/MC/MCObjectStreamer.cpp
@@ -20,7 +20,6 @@
#include "llvm/MC/MCSection.h"
#include "llvm/MC/MCSymbol.h"
#include "llvm/Support/ErrorHandling.h"
-#include "llvm/Support/SourceMgr.h"
#include "llvm/Support/TargetRegistry.h"
using namespace llvm;
@@ -497,43 +496,6 @@ void MCObjectStreamer::EmitFill(uint64_t NumBytes, uint8_t FillValue) {
insert(new MCFillFragment(FillValue, NumBytes));
}
-void MCObjectStreamer::emitFill(const MCExpr &NumBytes, uint64_t FillValue,
- SMLoc Loc) {
- MCDataFragment *DF = getOrCreateDataFragment();
- flushPendingLabels(DF, DF->getContents().size());
-
- int64_t IntNumBytes;
- if (!NumBytes.evaluateAsAbsolute(IntNumBytes, getAssembler())) {
- getContext().reportError(Loc, "expected absolute expression");
- return;
- }
-
- if (IntNumBytes <= 0) {
- getContext().reportError(Loc, "invalid number of bytes");
- return;
- }
-
- EmitFill(IntNumBytes, FillValue);
-}
-
-void MCObjectStreamer::emitFill(const MCExpr &NumValues, int64_t Size,
- int64_t Expr, SMLoc Loc) {
- int64_t IntNumValues;
- if (!NumValues.evaluateAsAbsolute(IntNumValues, getAssembler())) {
- getContext().reportError(Loc, "expected absolute expression");
- return;
- }
-
- if (IntNumValues < 0) {
- getContext().getSourceManager()->PrintMessage(
- Loc, SourceMgr::DK_Warning,
- "'.fill' directive with negative repeat count has no effect");
- return;
- }
-
- MCStreamer::emitFill(IntNumValues, Size, Expr);
-}
-
void MCObjectStreamer::FinishImpl() {
// If we are generating dwarf for assembly source files dump out the sections.
if (getContext().getGenDwarfForAssembly())