ProfileData: Introduce InstrProfWriter using the naive text format

This isn't a format we'll want to write out in practice, but moving it
to the writer library simplifies llvm-profdata and isolates it from
further changes to the format.

This also allows us to update the tests to not rely on the text output
format.

llvm-svn: 204489
diff --git a/llvm/lib/ProfileData/CMakeLists.txt b/llvm/lib/ProfileData/CMakeLists.txt
index cef3a53..5204afc 100644
--- a/llvm/lib/ProfileData/CMakeLists.txt
+++ b/llvm/lib/ProfileData/CMakeLists.txt
@@ -1,6 +1,7 @@
 add_llvm_library(LLVMProfileData
   InstrProf.cpp
   InstrProfReader.cpp
+  InstrProfWriter.cpp
 
   LINK_LIBS
   LLVMSupport