2018-11-29 Uros Bizjak <[email protected]>
* config/i386/i386.c (inline_memory_move_cost):
Check "in" for 2 in MMX_CLASS_P case.
* config/i386/mmx.md (*mov<mode>_internal): Correct
TARGET_INTER_UNIT_MOVES_FROM_VEC and TARGET_INTER_UNIT_MOVES_TO_VEC
alternatives in preferred_for_speed attribute calculation.
Bootstrapped and regression tested on x86_64-linux-gnu {,-m32}.
Committed to mainline SVN.
Uros.
Index: config/i386/i386.c
===================================================================
--- config/i386/i386.c (revision 266593)
+++ config/i386/i386.c (working copy)
@@ -39528,7 +39528,7 @@ inline_memory_move_cost (machine_mode mode, enum r
default:
return 100;
}
- if (in)
+ if (in == 2)
return MAX (ix86_cost->mmx_load [index], ix86_cost->mmx_store [index]);
return in ? ix86_cost->mmx_load [index] : ix86_cost->mmx_store [index];
}
Index: config/i386/mmx.md
===================================================================
--- config/i386/mmx.md (revision 266593)
+++ config/i386/mmx.md (working copy)
@@ -208,9 +208,9 @@
]
(const_string "DI")))
(set (attr "preferred_for_speed")
- (cond [(eq_attr "alternative" "10,15")
+ (cond [(eq_attr "alternative" "9,15")
(symbol_ref "TARGET_INTER_UNIT_MOVES_FROM_VEC")
- (eq_attr "alternative" "11,16")
+ (eq_attr "alternative" "10,16")
(symbol_ref "TARGET_INTER_UNIT_MOVES_TO_VEC")
]
(symbol_ref "true")))])