abstract load commands to that WriterMachO can write 64-bit and 32-bit mach-o files

git-svn-id: https://llvm.org/svn/llvm-project/lld/trunk@158133 91177308-0d34-0410-b5e6-96231b3b80d8
fix warnings found after cranking up warnings

git-svn-id: https://llvm.org/svn/llvm-project/lld/trunk@158134 91177308-0d34-0410-b5e6-96231b3b80d8
put the public function createReaderPECOFF() in the lld namespace and everything else in is own namespace

git-svn-id: https://llvm.org/svn/llvm-project/lld/trunk@158135 91177308-0d34-0410-b5e6-96231b3b80d8
Move implementation of WriterOptionsMachO to its own file. Reduced redundant
ivars in WriterOptionsMachO instead have its methods compute ivar interactions.
Refactor mach-o Reference Kinds and introduce abstract class KindHandler.
Split up StubAtoms.hpp by architecture.  Add support for 32-bit x86 stubs.






git-svn-id: https://llvm.org/svn/llvm-project/lld/trunk@158336 91177308-0d34-0410-b5e6-96231b3b80d8
Wrote initial doc on how to create a Reader

git-svn-id: https://llvm.org/svn/llvm-project/lld/trunk@158374 91177308-0d34-0410-b5e6-96231b3b80d8
flesh out mach-o Reference Kinds

git-svn-id: https://llvm.org/svn/llvm-project/lld/trunk@158375 91177308-0d34-0410-b5e6-96231b3b80d8
Use ADT/StringSwitch

git-svn-id: https://llvm.org/svn/llvm-project/lld/trunk@158541 91177308-0d34-0410-b5e6-96231b3b80d8
use llvm_unreachable() instead of assert(0) for invalid enum values in switch statements

git-svn-id: https://llvm.org/svn/llvm-project/lld/trunk@158542 91177308-0d34-0410-b5e6-96231b3b80d8
remove return statements after llvm_unreachable() as the compiler no longer warns abot missing return values

git-svn-id: https://llvm.org/svn/llvm-project/lld/trunk@158544 91177308-0d34-0410-b5e6-96231b3b80d8
Add 'invalid' as a Reference Kind so that unknown/invalid kind strings can return that fact to the caller for use in constructing an error message, rather that triggering an assertion.

git-svn-id: https://llvm.org/svn/llvm-project/lld/trunk@158547 91177308-0d34-0410-b5e6-96231b3b80d8
Wordsmithing from patch from Sean Silva

git-svn-id: https://llvm.org/svn/llvm-project/lld/trunk@158584 91177308-0d34-0410-b5e6-96231b3b80d8
Fix MSVC compat. MSVC doesn't have bzero.

Although the code is not valid to begin with. It is trying to do a raw memory
copy of a non standard-layout type. nameoffset is not guaranteed to directly
follow cmdsize.

This should be properly fixed.

git-svn-id: https://llvm.org/svn/llvm-project/lld/trunk@158612 91177308-0d34-0410-b5e6-96231b3b80d8
Fix Sphinx warning.  Patch by Sean Silva

git-svn-id: https://llvm.org/svn/llvm-project/lld/trunk@158678 91177308-0d34-0410-b5e6-96231b3b80d8
Unused var warning.

git-svn-id: https://llvm.org/svn/llvm-project/lld/trunk@158944 91177308-0d34-0410-b5e6-96231b3b80d8
Fix link order. Patch by Sidney Manning.

git-svn-id: https://llvm.org/svn/llvm-project/lld/trunk@158945 91177308-0d34-0410-b5e6-96231b3b80d8
Fix CMake build to use target_link_libraries. Patch by Sidney Manning!

git-svn-id: https://llvm.org/svn/llvm-project/lld/trunk@159165 91177308-0d34-0410-b5e6-96231b3b80d8
Add missing LLVMSupport

git-svn-id: https://llvm.org/svn/llvm-project/lld/trunk@159702 91177308-0d34-0410-b5e6-96231b3b80d8
Minor edits to match style guidelines. No functionality change

git-svn-id: https://llvm.org/svn/llvm-project/lld/trunk@160370 91177308-0d34-0410-b5e6-96231b3b80d8
Added description of Atom types from Nick's email

git-svn-id: https://llvm.org/svn/llvm-project/lld/trunk@160468 91177308-0d34-0410-b5e6-96231b3b80d8
Trivial reformatting

git-svn-id: https://llvm.org/svn/llvm-project/lld/trunk@160730 91177308-0d34-0410-b5e6-96231b3b80d8