This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
Re: muldi3, divdi3 and remdi3 patterns
- To: law@cygnus.com
- Subject: Re: muldi3, divdi3 and remdi3 patterns
- From: Mark Klein <mklein@dis.com>
- Date: Mon, 09 Aug 1999 07:52:12 -0700
- Cc: gcc@gcc.gnu.org
- References: <Your message of Sat, 07 Aug 1999 13:56:43 PDT. <4.1.19990807132315.00ccc670@garfield.dis.com>
At 11:04 PM 8/8/99 -0600, Jeffrey A Law wrote:
> > In adding muldi3, divdi3 and remdi3 instruction patterns, I find
> > that the compiler is choosing to do remsi3 as a widened X-Y*(X/Y)
> > instead of simply using the remsi3 pattern. It starts down this
> > path in expand_divmod when expand_mult_highpart recognizes it can
> > use the muldi3 pattern.
>Yes. This is the division by using widening multiplications. This is
>precisely what I would expect the compiler to do.
So even though $$remoI is faster than the combination of $$mulo2I and
the shifting, on PA we'll get the less efficient implementation? I
don't quite understand how the current costs have been allocated .. is
there a way to influence this such that I'll use the modulo millicode
instead of the multiply/divide?
Regards,
M.
--
Mark Klein DIS International, Ltd.
http://www.dis.com 415-892-8400
PGP Public Key Available