On Thursday 24 February 2005 21:16, James E Wilson wrote: > On Thu, 2005-02-24 at 03:15, Steven Bosscher wrote: > > On Feb 24, 2005 11:13 AM, Tarun Kawatra <[EMAIL PROTECTED]> wrote: > > Does GCSE look into stuff in PARALLELs at all? From gcse.c: > > Shrug. The code in hash_scan_set seems to be doing something > reasonable. > > The problem I saw wasn't with finding expressions to gcse, it was with > inserting them later. The insertion would create a cc reg clobber, so > we don't bother adding it to the hash table. I didn't look any further, > but it seemed reasonable that if it isn't in the hash table, then it > isn't going to be optimized. > > It seems that switching the x86 backend from using cc0 to using a cc > hard register has effectively crippled the RTL gcse pass for it.
Not that it matters so much. GCSE does more harm than good for lots of code (including SPEC - the mean for int and fp goes *up* if you disable GCSE for x86*). The problem indeed appears to be inserting the expressions. I am quite sure there was a patch to allow GCSE to do more with PARALLELs, but I can't find it anywhere. I did stuble into this mail: http://gcc.gnu.org/ml/gcc/2003-07/msg02064.html: " - My code for GCSE on parallels that is actually in cfg branch only and first halve of the changes went into mainline (basic code motion infrastructure) " In one of the replies, rth said: "I'm not sure these are worthwhile long term. I expect the rtl GCSE optimizer to collapse to almost nothing with the tree-ssa merge." Which probably explains why these bits where never merged from the cfg-branch for GCC 3.4. Ah, archeology, so much fun. Gr. Steven