This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: [PR middle-end/20739] lvalue cond-expr gimplification may crash on cv-qual diffs
On Apr 4, 2005, Jeffrey A Law <law@redhat.com> wrote:
> On Mon, 2005-04-04 at 08:43 -0300, Alexandre Oliva wrote:
>> If the operands of a cond-expr used as an lvalue differ in cv
>> qualification, the front-end adds nop_exprs to add cv qualifiers that
>> the gimplifier drops when simplifying &(T const)*v. The `&' was added
>> by gimplify_cond_expr.
>> The problem is that gimplify_addr_expr gimplifies its operand in such
>> a way that the nop_expr is dropped, and nothing puts it back in, so
>> when we test that, in the indirect_ref case in gimplify_addr_expr, the
>> types are compatible, the test fails because of the missing
>> cv-qualifier in the pointed-to type. This patch fixes this.
>> Ok to install if bootstrap and regtest on amd64-linux-gnu pass?
> I don't know about others, but I'd really prefer to see patches _after_
> they have passed bootstrap and regression testing. Please repost when
> testing has completed.
Bootstrap is almost complete (linking 64-bit libjava now, then will
start testing and results will be ready after I go to bed); testing of
C and C++ in a separate, non-bootstrapped build tree completed
successfully. Is this amount of testing good enough for you to review
the patch?
Also, read my justification to posting patches before full testing is
complete in the reply I just sent to Roger Sayle, in the PR c++/19199
thread, and please join that discussion if you feel my reasons are not
good enough.
--
Alexandre Oliva http://www.ic.unicamp.br/~oliva/
Red Hat Compiler Engineer aoliva@{redhat.com, gcc.gnu.org}
Free Software Evangelist oliva@{lsd.ic.unicamp.br, gnu.org}