This is the mail archive of the gcc-patches@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]
Other format: [Raw text]

Re: [RFC PATCH, i386]: Convert 1.0/sqrtf (x) into rsqrtf even without -mrecip


	Be careful about over-optimizing that particular benchmark or
isolated statement.  If the costs on Core2 make it a general win, great.

	I eventually want to enhance the TARGET_BUILTIN_RECIPROCAL
interface to have a cost parameter that counts the number of other FP
instructions in the basic block or function to know if there is enough
other work that can be inter-scheduled with the NR iterations.  On
PowerPC, at least, the benefit is more about intermingling other
computations instead of occupying the FPU with a long latency instruction.
If there is no other FP work, one might as well not bloat the I-cache and
use the single instruction.

	In the long run, the subtlety of a cost model probably would help
x86 as well.

David


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