This is the mail archive of the
mailing list for the GCC project.
Re: [Bug middle-end/37448] patch to compute alloc-pool stats correctly
"Richard Guenther" <firstname.lastname@example.org> writes:
> On Tue, Oct 7, 2008 at 6:52 PM, Ian Lance Taylor <email@example.com> wrote:
>> Kenneth Zadeck <firstname.lastname@example.org> writes:
>>>> I wonder if some of the types in alloc_pool_descriptor should be
>>>> size_t rather than int, though it's hard to imagine it making a
>>>> difference in real life.
>>> I noticed this too, it actually does make a difference in the printing
>>> of the values on the testcase since they overflow. However, I did not
>>> know how to modify the formats in the printfs to print the size_ts.
>> The simple way is to use "unsigned long" and "%lu".
> Which probably doesn't work for win64 ... of course there
> isn't a portable one for size_t or long long.
I thought of that, but it does work for win64 in the sense of
operating correctly and being an improvement on what is there now.
If we really want to use size_t on win64, we should just use unsigned
HOST_WIDEST_FAST_INT, create the corresponding print macros, and
update config.host to get win64 to set