This is the mail archive of the gcc-bugs@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Re: Problem with your 1999-11-23 change


>>>>> "Bernd" == Bernd Schmidt <bernds@balti.cygnus.co.uk> writes:

    Bernd> We're running into problems because we want to optimize a
    Bernd> reg that was made while processing an inner loop.  I've run
    Bernd> into this kind of problem once too often now, and I propose
    Bernd> the patch below to fix it.

The patch looks fine to me.  Please do run the C++ tests, but then
insert it.

    Bernd> Note that I'm not entirely sure that the range of insns
    Bernd> we're scanning is large enough; I've looked at the code in
    Bernd> loop.c/unroll.c and found nothing that inserts insns after
    Bernd> NEXT_INSN (end), but it's possible that I've overlooked
    Bernd> something.

Well, it sounds like this patch will monotonically increase the
robustness of the compiler, so I'll approve it.  If we find more spots
later, we'll do them to.

    Bernd> If this patch goes in, we may be able to remove some cruft
    Bernd> in the loop optimizer that tests against
    Bernd> max_reg_before_loop to avoid similar problems.  I'll look
    Bernd> into this if the patch gets approved.

I do remember some ugly code that said something like "allocate 10
extra registers for slop" which is pretty hokey.

    Bernd> Where did the testcase come from?  Can we install it in the
    Bernd> testsuite (it could go into the C testsuite, it's plain C
    Bernd> and failing with cc1).

This was posted to the list, in a bigger form, and distilled by me.
The poster was "James A. Bednar" <jbednar@cs.utexas.edu> on
12/10/1999.  Let's put it this way: had I fixed this bug, I would
certainly have put in the C++ test-suite.  I would go ahead and put it
in the C testsuite, unless James complains.

--
Mark Mitchell                   mark@codesourcery.com
CodeSourcery, LLC               http://www.codesourcery.com


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]