This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: [PATCH] c++98/mt_allcoator.cc: Fix assumption sizeof(void *) == sizeof(size_t)
- From: Joel Sherrill <joel dot sherrill at oarcorp dot com>
- To: Paolo Carlini <paolo dot carlini at oracle dot com>, Jonathan Wakely <jwakely at redhat dot com>
- Cc: "gcc-patches at gcc dot gnu dot org" <gcc-patches at gcc dot gnu dot org>, libstdc++ <libstdc++ at gcc dot gnu dot org>
- Date: Mon, 10 Nov 2014 13:43:02 -0600
- Subject: Re: [PATCH] c++98/mt_allcoator.cc: Fix assumption sizeof(void *) == sizeof(size_t)
- Authentication-results: sourceware.org; auth=none
- References: <1415633767-18196-1-git-send-email-joel dot sherrill at oarcorp dot com> <5460FD76 dot 7080806 at oarcorp dot com> <20141110183443 dot GD5191 at redhat dot com> <54610BF6 dot 40704 at oracle dot com>
On 11/10/2014 1:03 PM, Paolo Carlini wrote:
> Hi,
>
> On 11/10/2014 07:34 PM, Jonathan Wakely wrote:
>> On 10/11/14 12:01 -0600, Joel Sherrill wrote:
>>> cc'ing since both lists should be included.
>>>
>>> The m32c has 24-bit pointers and 16-bit size_t. This changes
>>> pushing a pointer through a size_t to pushing it through a
>>> uintptr_t.
>> I'm OK with this change if Paolo is.
> No problem with the experiment (frankly, I'm not at all sure that the
> targets not providing <stdint.h> are *that* much uncommon than the
> target which we are fixing with the patch), but please add a comment
> about <stdint.h> in the code, then if bootstrap actually breaks the
> issue is clear...
Just to be clear add a comment above the include of stdint.h that it is
assumed
that a target provides this header file and defines uintptr_t.
> Paolo.
--
Joel Sherrill, Ph.D. Director of Research & Development
joel.sherrill@OARcorp.com On-Line Applications Research
Ask me about RTEMS: a free RTOS Huntsville AL 35805
Support Available (256) 722-9985