summaryrefslogtreecommitdiffstats
path: root/lld/lib/Platforms/Darwin/DarwinPlatform.h
diff options
context:
space:
mode:
authorNick Kledzik <kledzik@apple.com>2012-05-31 22:34:00 +0000
committerNick Kledzik <kledzik@apple.com>2012-05-31 22:34:00 +0000
commitabb6981f68a0cf631b6d7d36e67127bb1af50713 (patch)
tree63d6fd7aeef209f7528fecf1a151df50f61f7fa9 /lld/lib/Platforms/Darwin/DarwinPlatform.h
parent5168a72b2628288c5ba3143745554e2eadbb67b0 (diff)
downloadbcm5719-llvm-abb6981f68a0cf631b6d7d36e67127bb1af50713.tar.gz
bcm5719-llvm-abb6981f68a0cf631b6d7d36e67127bb1af50713.zip
Major refactoring: Remove Platform concept. In its place there are
now Reader and Writer subclasses for each file format. Each Reader and Writer subclass defines an "options" class which controls how that Reader or Writer operates. llvm-svn: 157774
Diffstat (limited to 'lld/lib/Platforms/Darwin/DarwinPlatform.h')
-rw-r--r--lld/lib/Platforms/Darwin/DarwinPlatform.h61
1 files changed, 0 insertions, 61 deletions
diff --git a/lld/lib/Platforms/Darwin/DarwinPlatform.h b/lld/lib/Platforms/Darwin/DarwinPlatform.h
deleted file mode 100644
index c05fb9c2bbb..00000000000
--- a/lld/lib/Platforms/Darwin/DarwinPlatform.h
+++ /dev/null
@@ -1,61 +0,0 @@
-//===- Platform/DarwinPlatform.h - Darwin Platform Implementation ---------===//
-//
-// The LLVM Linker
-//
-// This file is distributed under the University of Illinois Open Source
-// License. See LICENSE.TXT for details.
-//
-//===----------------------------------------------------------------------===//
-
-#ifndef LLD_PLATFORM_DARWIN_PLATFORM_H_
-#define LLD_PLATFORM_DARWIN_PLATFORM_H_
-
-#include "lld/Core/Platform.h"
-#include "llvm/ADT/ArrayRef.h"
-#include "llvm/ADT/DenseMap.h"
-
-namespace lld {
-namespace darwin {
-
-class DarwinPlatform : public Platform {
-public:
- DarwinPlatform();
-
-/// @name Platform methods
-/// @{
- virtual void addFiles(InputFiles&);
- virtual Reference::Kind kindFromString(llvm::StringRef);
- virtual llvm::StringRef kindToString(Reference::Kind);
- virtual bool noTextRelocs();
- virtual bool isCallSite(Reference::Kind);
- virtual bool isGOTAccess(Reference::Kind, bool& canBypassGOT);
- virtual void updateReferenceToGOT(const Reference*, bool targetIsNowGOT);
- virtual const DefinedAtom* getStub(const Atom&, File&);
- virtual void addStubAtoms(File &file);
- virtual const DefinedAtom* makeGOTEntry(const Atom&, File&);
- virtual void applyFixup(Reference::Kind, uint64_t addend, uint8_t*,
- uint64_t fixupAddress, uint64_t targetAddress);
- virtual void writeExecutable(const lld::File &, raw_ostream &out);
-/// @}
-/// @name Darwin specific methods
-/// @{
- uint64_t pageZeroSize();
- void initializeMachHeader(const lld::File& file, class mach_header& mh);
- const Atom *mainAtom();
-/// @}
-
-private:
- llvm::DenseMap<const Atom*, const DefinedAtom*> _targetToStub;
- std::vector<const DefinedAtom*> _lazyPointers;
- std::vector<const DefinedAtom*> _stubHelperAtoms;
- const SharedLibraryAtom *_stubBinderAtom;
- const DefinedAtom* _helperCommonAtom;
- const DefinedAtom* _helperCacheAtom;
- const DefinedAtom* _helperBinderAtom;
- class CRuntimeFile *_cRuntimeFile;
-};
-
-} // namespace darwin
-} // namespace lld
-
-#endif // LLD_PLATFORM_DARWIN_PLATFORM_H_
OpenPOWER on IntegriCloud