summaryrefslogtreecommitdiffstats
path: root/llvm/lib/Target/AVR/MCTargetDesc/AVRAsmBackend.cpp
diff options
context:
space:
mode:
authorPeter Collingbourne <peter@pcc.me.uk>2018-05-21 17:57:19 +0000
committerPeter Collingbourne <peter@pcc.me.uk>2018-05-21 17:57:19 +0000
commit571a3301aeaaddcb1d784d8f27957170fe0cfd15 (patch)
tree68b8fadb711472ead3443a2b0352d21eadb7d405 /llvm/lib/Target/AVR/MCTargetDesc/AVRAsmBackend.cpp
parenta91ce17b5f2bbaa909aaa61a4610316de06f18cb (diff)
downloadbcm5719-llvm-571a3301aeaaddcb1d784d8f27957170fe0cfd15.tar.gz
bcm5719-llvm-571a3301aeaaddcb1d784d8f27957170fe0cfd15.zip
MC: Change MCAsmBackend::writeNopData() to take a raw_ostream instead of an MCObjectWriter. NFCI.
To make this work I needed to add an endianness field to MCAsmBackend so that writeNopData() implementations know which endianness to use. Part of PR37466. Differential Revision: https://reviews.llvm.org/D47035 llvm-svn: 332857
Diffstat (limited to 'llvm/lib/Target/AVR/MCTargetDesc/AVRAsmBackend.cpp')
-rw-r--r--llvm/lib/Target/AVR/MCTargetDesc/AVRAsmBackend.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/llvm/lib/Target/AVR/MCTargetDesc/AVRAsmBackend.cpp b/llvm/lib/Target/AVR/MCTargetDesc/AVRAsmBackend.cpp
index 2f5e9f02e53..28c3e0af2ea 100644
--- a/llvm/lib/Target/AVR/MCTargetDesc/AVRAsmBackend.cpp
+++ b/llvm/lib/Target/AVR/MCTargetDesc/AVRAsmBackend.cpp
@@ -453,13 +453,13 @@ MCFixupKindInfo const &AVRAsmBackend::getFixupKindInfo(MCFixupKind Kind) const {
return Infos[Kind - FirstTargetFixupKind];
}
-bool AVRAsmBackend::writeNopData(uint64_t Count, MCObjectWriter *OW) const {
+bool AVRAsmBackend::writeNopData(raw_ostream &OS, uint64_t Count) const {
// If the count is not 2-byte aligned, we must be writing data into the text
// section (otherwise we have unaligned instructions, and thus have far
// bigger problems), so just write zeros instead.
assert((Count % 2) == 0 && "NOP instructions must be 2 bytes");
- OW->WriteZeros(Count);
+ OS.write_zeros(Count);
return true;
}
OpenPOWER on IntegriCloud