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]

[PATCH, Atom] Improve AGU stalls avoidance optimization


Hello,

Here is a patch which adds few more splits for AGU stalls avoidance on
Atom. It also fixes cost model and detects AGU stalls more
efficiently.

Bootstrapped and checked on x86_64-linux.

Thanks,
Ilya
---
gcc/

2011-09-02  Enkovich Ilya  <ilya.enkovich@intel.com>

	* config/i386/i386-protos.h (ix86_lea_outperforms): New.
	(ix86_avoid_lea_for_add): Likewise.
	(ix86_avoid_lea_for_addr): Likewise.
	(ix86_split_lea_for_addr): Likewise.

	* config/i386/i386.c (LEA_MAX_STALL): New.
	(increase_distance): Likewise.
	(insn_defines_reg): Likewise.
	(insn_uses_reg_mem): Likewise.
	(distance_non_agu_define_in_bb): Likewise.
	(distance_agu_use_in_bb): Likewise.
	(ix86_lea_outperforms): Likewise.
	(ix86_ok_to_clobber_flags): Likewise.
	(ix86_avoid_lea_for_add): Likewise.
	(ix86_avoid_lea_for_addr): Likewise.
	(ix86_split_lea_for_addr): Likewise.
	(distance_non_agu_define): Search in pred BBs added.
	(distance_agu_use): Search in succ BBs added.
	(IX86_LEA_PRIORITY): Value changed from 2 to 0.
	(LEA_SEARCH_THRESHOLD): Now depends on LEA_MAX_STALL.
	(ix86_lea_for_add_ok): Use ix86_lea_outperforms to make decision.

	* config/i386/i386.md: Splits added to transform lea into a
	sequence of instructions.

Attachment: lea.diff
Description: Binary data


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