[compiler-rt] r204267 - PGO: Fix obviously wrong typedefs for MS
Aaron Ballman
aaron at aaronballman.com
Fri Mar 21 14:09:18 PDT 2014
On Fri, Mar 21, 2014 at 5:08 PM, Duncan P. N. Exon Smith
<dexonsmith at apple.com> wrote:
>
> On Mar 19, 2014, at 4:32 PM, Aaron Ballman <aaron at aaronballman.com> wrote:
>
>> On Wed, Mar 19, 2014 at 6:41 PM, Duncan P. N. Exon Smith
>> <dexonsmith at apple.com> wrote:
>>> On Mar 19, 2014, at 3:26 PM, Aaron Ballman <aaron at aaronballman.com> wrote:
>>>
>>>> On Wed, Mar 19, 2014 at 6:10 PM, Duncan P. N. Exon Smith
>>>> <dexonsmith at apple.com> wrote:
>>>>> Author: dexonsmith
>>>>> Date: Wed Mar 19 17:10:24 2014
>>>>> New Revision: 204267
>>>>>
>>>>> URL: http://llvm.org/viewvc/llvm-project?rev=204267&view=rev
>>>>> Log:
>>>>> PGO: Fix obviously wrong typedefs for MS
>>>>>
>>>>> Modified:
>>>>> compiler-rt/trunk/lib/profile/GCDAProfiling.c
>>>>> compiler-rt/trunk/lib/profile/PGOProfiling.c
>>>>>
>>>>> Modified: compiler-rt/trunk/lib/profile/GCDAProfiling.c
>>>>> URL: http://llvm.org/viewvc/llvm-project/compiler-rt/trunk/lib/profile/GCDAProfiling.c?rev=204267&r1=204266&r2=204267&view=diff
>>>>> ==============================================================================
>>>>> --- compiler-rt/trunk/lib/profile/GCDAProfiling.c (original)
>>>>> +++ compiler-rt/trunk/lib/profile/GCDAProfiling.c Wed Mar 19 17:10:24 2014
>>>>> @@ -43,7 +43,7 @@
>>>>>
>>>>> #if defined(_MSC_VER)
>>>>> typedef unsigned int uint32_t;
>>>>> -typedef unsigned int uint64_t;
>>>>> +typedef unsigned long long uint64_t;
>>>>> #elif I386_FREEBSD
>>>>> /* System headers define 'size_t' incorrectly on x64 FreeBSD (prior to
>>>>> * FreeBSD 10, r232261) when compiled in 32-bit mode.
>>>>>
>>>>> Modified: compiler-rt/trunk/lib/profile/PGOProfiling.c
>>>>> URL: http://llvm.org/viewvc/llvm-project/compiler-rt/trunk/lib/profile/PGOProfiling.c?rev=204267&r1=204266&r2=204267&view=diff
>>>>> ==============================================================================
>>>>> --- compiler-rt/trunk/lib/profile/PGOProfiling.c (original)
>>>>> +++ compiler-rt/trunk/lib/profile/PGOProfiling.c Wed Mar 19 17:10:24 2014
>>>>> @@ -22,7 +22,7 @@
>>>>>
>>>>> #if defined(_MSC_VER)
>>>>> typedef unsigned int uint32_t;
>>>>> -typedef unsigned int uint64_t;
>>>>> +typedef unsigned long long uint64_t;
>>>>> #elif I386_FREEBSD
>>>>> /* System headers define 'size_t' incorrectly on x64 FreeBSD (prior to
>>>>> * FreeBSD 10, r232261) when compiled in 32-bit mode.
>>>>
>>>> If our minimum version requirement is MSVC 2012, why are we not simply
>>>> using stdint.h for MSVC?
>>>
>>> Does MSVC 2012 have stdint.h? I have no access to (or knowledge about)
>>> MSVC, except what a Google search tells me about long long being 64-bits;
>>> this was a drive-by fix.
>>
>> Yes, MSVC 2010 also had stdint.h
>>
>>> There aren’t even header stubs in compiler-rt for MS, so I’m not sure this
>>> is important.
>>
>> Me neither, I've never really done anything with compiler-rt,
>> personally. But from what I recall, it wasn't particularly MSVC-ready.
>>
>>> Are you sure stdint.h is the right thing now? I’m happy to commit that,
>>> as long as you’re willing to take the blame for me not testing it ;).
>>
>> I am happy to take the blame if things explode (put another way, if
>> there are problems, which I doubt, we can always revert).
>
> r204515. I’ll revert if a buildbot complains.
Thanks!
~Aaron
More information about the llvm-commits
mailing list