summaryrefslogtreecommitdiffstats
path: root/lld/wasm/OutputSegment.h
diff options
context:
space:
mode:
authorRui Ueyama <ruiu@google.com>2018-02-28 00:20:29 +0000
committerRui Ueyama <ruiu@google.com>2018-02-28 00:20:29 +0000
commit28f3b20db5949328f950a25f96434a57bcfdac19 (patch)
treea57af8a94710b11bb3d08254e835873bf44b1b01 /lld/wasm/OutputSegment.h
parent7d696880fbb35e0cfd7bd7cd842dff447b00336d (diff)
downloadbcm5719-llvm-28f3b20db5949328f950a25f96434a57bcfdac19.tar.gz
bcm5719-llvm-28f3b20db5949328f950a25f96434a57bcfdac19.zip
[WebAssembly] Remove trivial accessors.
{set,get}OutputSegment don't hide anything, so remove them. Differential Revision: https://reviews.llvm.org/D43724 llvm-svn: 326276
Diffstat (limited to 'lld/wasm/OutputSegment.h')
-rw-r--r--lld/wasm/OutputSegment.h13
1 files changed, 7 insertions, 6 deletions
diff --git a/lld/wasm/OutputSegment.h b/lld/wasm/OutputSegment.h
index d3918a5ea1b..79730134290 100644
--- a/lld/wasm/OutputSegment.h
+++ b/lld/wasm/OutputSegment.h
@@ -23,12 +23,13 @@ class OutputSegment {
public:
OutputSegment(StringRef N, uint32_t Index) : Name(N), Index(Index) {}
- void addInputSegment(InputSegment *Segment) {
- Alignment = std::max(Alignment, Segment->getAlignment());
- InputSegments.push_back(Segment);
- Size = llvm::alignTo(Size, Segment->getAlignment());
- Segment->setOutputSegment(this, Size);
- Size += Segment->getSize();
+ void addInputSegment(InputSegment *InSeg) {
+ Alignment = std::max(Alignment, InSeg->getAlignment());
+ InputSegments.push_back(InSeg);
+ Size = llvm::alignTo(Size, InSeg->getAlignment());
+ InSeg->OutputSeg = this;
+ InSeg->OutputSegmentOffset = Size;
+ Size += InSeg->getSize();
}
uint32_t getSectionOffset() const { return SectionOffset; }
OpenPOWER on IntegriCloud