1 //===-- XCoreTargetObjectFile.cpp - XCore object files --------------------===//
3 // The LLVM Compiler Infrastructure
5 // This file is distributed under the University of Illinois Open Source
6 // License. See LICENSE.TXT for details.
8 //===----------------------------------------------------------------------===//
10 #include "XCoreTargetObjectFile.h"
14 XCoreTargetObjectFile::XCoreTargetObjectFile(bool isXS1A) {
15 TextSection = getOrCreateSection("\t.text", true, SectionKind::Text);
16 DataSection = getOrCreateSection("\t.dp.data", false, SectionKind::DataRel);
17 BSSSection_ = getOrCreateSection("\t.dp.bss", false, SectionKind::BSS);
19 // TLS globals are lowered in the backend to arrays indexed by the current
20 // thread id. After lowering they require no special handling by the linker
21 // and can be placed in the standard data / bss sections.
22 TLSDataSection = DataSection;
23 TLSBSSSection = BSSSection_;
26 // FIXME: Why is this writable ("datarel")???
27 ReadOnlySection = getOrCreateSection("\t.dp.rodata", false,
28 SectionKind::DataRel);
30 ReadOnlySection = getOrCreateSection("\t.cp.rodata", false,
31 SectionKind::ReadOnly);