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]

[AArch64] Restrict the shift value in compare extended shift operation


Hi,

Please find attached the patch that restricts the shift value in
comparison operation between 0-4.

Please review the patch and let me know if its okay?

2013-05-07  Naveen H.S  <Naveen.Hurugalawadi@caviumnetworks.com>

	* config/aarch64/aarch64.md
	(cmp_swp_<optab><ALLX:mode>_shft_<GPI:mode>): Restrict the
	shift value between 0-4.

Thanks,
Naveen
--- gcc/config/aarch64/aarch64.md	2013-05-07 11:31:52.096213714 +0530
+++ gcc/config/aarch64/aarch64.md	2013-05-07 12:53:04.016369788 +0530
@@ -2349,7 +2349,7 @@
 	(compare:CC_SWP (ashift:GPI
 			 (ANY_EXTEND:GPI
 			  (match_operand:ALLX 0 "register_operand" "r"))
-			 (match_operand:QI 1 "aarch64_shift_imm_<mode>" "n"))
+			 (match_operand 1 "aarch64_imm3" "Ui3"))
 	(match_operand:GPI 2 "register_operand" "r")))]
   ""
   "cmp\\t%<GPI:w>2, %<GPI:w>0, <su>xt<ALLX:size> %1"

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