Re: [PATCH][i386] Correct imul (r64) latency for modern Intel CPUs

2017-12-17 Thread Markus Trippelsdorf
On 2017.12.17 at 12:26 +0100, Jan Hubicka wrote: > > Since Nehalem the 64bit multiplication latency is three cycles, not > > four. So update the costs to reflect reality. > > I looked into the imul latencies and was a bit confused, decided to look > into it later and forgot. > > Agner Fog's table

Re: [PATCH][i386] Correct imul (r64) latency for modern Intel CPUs

2017-12-17 Thread Jan Hubicka
> Since Nehalem the 64bit multiplication latency is three cycles, not > four. So update the costs to reflect reality. I looked into the imul latencies and was a bit confused, decided to look into it later and forgot. Agner Fog's table http://www.agner.org/optimize/instruction_tables.pdf lists for

[PATCH][i386] Correct imul (r64) latency for modern Intel CPUs

2017-12-17 Thread Markus Trippelsdorf
Since Nehalem the 64bit multiplication latency is three cycles, not four. So update the costs to reflect reality. Tested on X86_64. OK for trunk? Thanks. * x86-tune-costs.h (skylake_cost, core_cost): Decrease r64 multiply latencies. * gcc.target/i386/wmul-3.c: New test.