From patchwork Sun Nov 25 20:40:00 2012 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Subject: [i386] : Fix handling of TARGET_SSE_TYPELESS_STORES in unaligned move RTXes Date: Sun, 25 Nov 2012 10:40:00 -0000 From: Uros Bizjak X-Patchwork-Id: 201568 Message-Id: To: gcc-patches@gcc.gnu.org Hello! When unaligned moves were split to unaligned store/loads, mode calculation didn't get updated. Attached patch fixes this oversight. 2012-11-25 Uros Bizjak * config/i386/sse.md (_loadu): Do not depend on TARGET_SSE_TYPELESS_STORES. (_loaddqu): Ditto. (_storeu): Fix handling of TARGET_SSE_TYPELESS_STORES. (_storedqu): Ditto. Tested on x86_64-pc-linux-gnu {,-m32} and committed to mainline SVN. Uros. Index: config/i386/sse.md =================================================================== --- config/i386/sse.md (revision 193792) +++ config/i386/sse.md (working copy) @@ -610,9 +610,6 @@ (set (attr "mode") (cond [(match_test "TARGET_SSE_PACKED_SINGLE_INSN_OPTIMAL") (const_string "") - (and (eq_attr "alternative" "1") - (match_test "TARGET_SSE_TYPELESS_STORES")) - (const_string "") (match_test "TARGET_AVX") (const_string "") (match_test "optimize_function_for_size_p (cfun)") @@ -640,9 +637,7 @@ (set_attr "movu" "1") (set_attr "prefix" "maybe_vex") (set (attr "mode") - (cond [(match_test "TARGET_SSE_PACKED_SINGLE_INSN_OPTIMAL") - (const_string "") - (and (eq_attr "alternative" "1") + (cond [(ior (match_test "TARGET_SSE_PACKED_SINGLE_INSN_OPTIMAL") (match_test "TARGET_SSE_TYPELESS_STORES")) (const_string "") (match_test "TARGET_AVX") @@ -678,9 +673,6 @@ (set (attr "mode") (cond [(match_test "TARGET_SSE_PACKED_SINGLE_INSN_OPTIMAL") (const_string "") - (and (eq_attr "alternative" "1") - (match_test "TARGET_SSE_TYPELESS_STORES")) - (const_string "") (match_test "TARGET_AVX") (const_string "") (match_test "optimize_function_for_size_p (cfun)") @@ -712,9 +704,7 @@ (const_string "1"))) (set_attr "prefix" "maybe_vex") (set (attr "mode") - (cond [(match_test "TARGET_SSE_PACKED_SINGLE_INSN_OPTIMAL") - (const_string "") - (and (eq_attr "alternative" "1") + (cond [(ior (match_test "TARGET_SSE_PACKED_SINGLE_INSN_OPTIMAL") (match_test "TARGET_SSE_TYPELESS_STORES")) (const_string "") (match_test "TARGET_AVX")