[mach-o] enable mach-o and native yaml to be intermixed

The main goal of this patch is to allow "mach-o encoded as yaml" and "native
encoded as yaml" documents to be intermixed.  They are distinguished via 
yaml tags at the start of the document.  This will enable all mach-o test cases
to be written using yaml instead of checking in object files.

The Registry was extend to allow yaml tag handlers to be registered.  The
mach-o Reader adds a yaml tag handler for the tag "!mach-o". 

Additionally, this patch fixes some buffer ownership issues.  When parsing
mach-o binaries, the mach-o atoms can have pointers back into the memory 
mapped .o file.  But with yaml encoded mach-o, name and content are ephemeral, 
so a copyRefs parameter was added to cause the mach-o atoms to make their
own copy.  



git-svn-id: https://llvm.org/svn/llvm-project/lld/trunk@198986 91177308-0d34-0410-b5e6-96231b3b80d8
[yaml] use BumpPtrAllocator for string copies

git-svn-id: https://llvm.org/svn/llvm-project/lld/trunk@198987 91177308-0d34-0410-b5e6-96231b3b80d8
[PECOFF] Refactor module-defintion file parser.

Refactor the parser so that the parser can return arbitrary type of parse
result other than a vector of ExportDesc. Parsers for non-EXPORTS directives
will be implemented in different patches. No functionality change.

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