This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
Re: define_delay working only when optimization on!
- From: Spundun Bhatt <spundun at ISI dot EDU>
- To: Hans-Peter Nilsson <hp at bitrange dot com>
- Cc: gcc at gcc dot gnu dot org
- Date: 20 Mar 2003 16:11:39 -0800
- Subject: Re: define_delay working only when optimization on!
- Organization:
- References: <Pine.BSF.4.44.0303182114280.18670-100000@dair.pair.com>
On Tue, 2003-03-18 at 18:35, Hans-Peter Nilsson wrote:
> > It works when I have optimization option like O1 and O2 on. But its not
> > working ehn I dont supply any optimization options.
> > Does anyone know why is this behavior? This would mean that without O
> > options on, the compiler would produce wrong code, not taking care of my
> > slotted branches.
>
> No, you need to emit (the equivalence of) "nop" instructions
> semi-manually in your port when GCC does not fill delay slots.
> This can also happen with -O1 and -O2 (actually "optimized > 0
> && flag_delayed_branch"). See among others the CRIS port and
> the SPARC port. The documentation may need to be improved.
> (Please?)
Yeah I checked them out and the %# trick works like a charm :). Had to
debug it once before I added that '#' to PRINT_OPERAND_PUNCT_VALID_P .
Thanx a lot for your help. I have a similar question, but that in a
separate mail.
Spundun
>
> brgds, H-P