Forgot that this file needs to be C89 not C99 thanks to MSVC. No functionality
authorNick Lewycky <nicholas@mxc.ca>
Wed, 27 Feb 2013 08:28:35 +0000 (08:28 +0000)
committerNick Lewycky <nicholas@mxc.ca>
Wed, 27 Feb 2013 08:28:35 +0000 (08:28 +0000)
change!

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

runtime/libprofile/GCDAProfiling.c

index d9f3b32638990bc35352a0ca40a8c87b3769591a..8a805805ce7625c46f9baa924b44aa401275a2ad 100644 (file)
@@ -161,15 +161,15 @@ void llvm_gcda_increment_indirect_counter(uint32_t *predecessor,
 }
 
 void llvm_gcda_emit_function(uint32_t ident, const char *function_name) {
+  uint32_t len = 3;
 #ifdef DEBUG_GCDAPROFILING
   printf("llvmgcda: function id=%x name=%s\n", ident,
          function_name ? function_name : "NULL");
 #endif
   if (!output_file) return;
 
-  /* function tag */  
+  /* function tag */
   fwrite("\0\0\0\1", 4, 1, output_file);
-  uint32_t len = 3;
   if (function_name)
     len += 1 + length_of_string(function_name);
   write_int32(len);