PTH: Have meta data be at the beginning of the PTH file, not the end.

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@64338 91177308-0d34-0410-b5e6-96231b3b80d8
diff --git a/Driver/CacheTokens.cpp b/Driver/CacheTokens.cpp
index d8a1fe1..6b9f96e 100644
--- a/Driver/CacheTokens.cpp
+++ b/Driver/CacheTokens.cpp
@@ -517,8 +517,10 @@
   // Generate the prologue.
   Out << "cfe-pth";
   Emit32(PTHManager::Version);
-  Offset JumpOffset = Out.tell();
-  Emit32(0);
+  
+  // Leave 4 words for the prologue.
+  Offset PrologueOffset = Out.tell();
+  for (unsigned i = 0; i < 4 * sizeof(uint32_t); ++i) Emit8(0);
   
   // Iterate over all the files in SourceManager.  Create a lexer
   // for each file and cache the tokens.
@@ -554,16 +556,12 @@
   // Write out the file table.
   Offset FileTableOff = EmitFileTable();  
   
-  // Finally, write out the offset table at the end.
-  Offset JumpTargetOffset = Out.tell();    
+  // Finally, write the prologue.
+  Out.seek(PrologueOffset);
   Emit32(IdTableOff.first);
   Emit32(IdTableOff.second);
   Emit32(FileTableOff);
   Emit32(SpellingOff);
-  
-  // Now write the offset in the prologue.
-  Out.seek(JumpOffset);
-  Emit32(JumpTargetOffset);
 }
 
 void clang::CacheTokens(Preprocessor& PP, const std::string& OutFile) {