[lld-link] Support /map option, matching link.exe 's /map output format
Added support for /map and /map:[filepath].
The output was derived from Microsoft's Link.exe output when using that same option.
Note that /MAPINFO support was not added.
The previous implementation of MapFile.cpp/.h was meant for /lldmap, and was renamed to LLDMapFile.cpp/.h
MapFile.cpp/.h is now for /MAP
However, a small fix was added to lldmap, replacing a std::sort with std::stable_sort to enforce reproducibility.
Differential Revision: https://reviews.llvm.org/D70557
diff --git a/lld/COFF/CMakeLists.txt b/lld/COFF/CMakeLists.txt
index 1d310f8..4592ace 100644
--- a/lld/COFF/CMakeLists.txt
+++ b/lld/COFF/CMakeLists.txt
@@ -14,6 +14,7 @@
DriverUtils.cpp
ICF.cpp
InputFiles.cpp
+ LLDMapFile.cpp
LTO.cpp
MapFile.cpp
MarkLive.cpp