diff --git a/lld/MachO/notes.txt b/lld/MachO/notes.txt new file mode 100644 --- /dev/null +++ b/lld/MachO/notes.txt @@ -0,0 +1,18 @@ +This docs is the running list of significant differences in behaviour between LD64 and LLD-MachO. + +Symbol resolutions + - General resolution rule: + + LD64: the "winning" symbols are chosen based on several criteria. + + LLD: metadata from symbols with the same are merged, and the content of + the first symbol in the symbol table with that name is kept. + + - ObjC symbols from archives (linked with -ObjC flag, which acts similarly to -force_load in both linkers) + + LD64: + * Duplicate ObjC symbols from the same arhives are fine. It will pick the first one. + * Duplicate ObjC symbols from different archives will raise a "duplicate symbol" error. + + LLD: Duplicate symbols, regardless of which archives they are from, will raise errors. + + - Handling of personality symbols + + +// FIXME: There's something to say about section alignment. I forgot...