diff options
Diffstat (limited to 'lld/MachO/OutputSection.cpp')
-rw-r--r-- | lld/MachO/OutputSection.cpp | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/lld/MachO/OutputSection.cpp b/lld/MachO/OutputSection.cpp new file mode 100644 index 000000000000..c006828267cf --- /dev/null +++ b/lld/MachO/OutputSection.cpp @@ -0,0 +1,18 @@ +//===- OutputSection.cpp --------------------------------------------------===// +// +// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions. +// See https://llvm.org/LICENSE.txt for license information. +// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception +// +//===----------------------------------------------------------------------===// + +#include "OutputSection.h" +#include "OutputSegment.h" + +using namespace llvm; +using namespace lld; +using namespace lld::macho; + +uint64_t OutputSection::getSegmentOffset() const { + return addr - parent->firstSection()->addr; +} |