[compiler-rt] r336706 - [gcov] Fix fallout from r336693
Ulrich Weigand via llvm-commits
llvm-commits at lists.llvm.org
Tue Jul 10 10:08:05 PDT 2018
Author: uweigand
Date: Tue Jul 10 10:08:05 2018
New Revision: 336706
URL: http://llvm.org/viewvc/llvm-project?rev=336706&view=rev
Log:
[gcov] Fix fallout from r336693
Fix building GCDAProfiling.c with pre-C99 compilers.
This caused a build bot failure.
Modified:
compiler-rt/trunk/lib/profile/GCDAProfiling.c
Modified: compiler-rt/trunk/lib/profile/GCDAProfiling.c
URL: http://llvm.org/viewvc/llvm-project/compiler-rt/trunk/lib/profile/GCDAProfiling.c?rev=336706&r1=336705&r2=336706&view=diff
==============================================================================
--- compiler-rt/trunk/lib/profile/GCDAProfiling.c (original)
+++ compiler-rt/trunk/lib/profile/GCDAProfiling.c Tue Jul 10 10:08:05 2018
@@ -210,11 +210,12 @@ static uint32_t read_32bit_value() {
static uint32_t read_le_32bit_value() {
uint32_t val = 0;
+ int i;
if (new_file)
return (uint32_t)-1;
- for (int i = 0; i < 4; i++)
+ for (i = 0; i < 4; i++)
val |= write_buffer[cur_pos++] << (8*i);
return val;
}
More information about the llvm-commits
mailing list