aboutsummaryrefslogtreecommitdiff
path: root/gcc/config
diff options
context:
space:
mode:
authorJakub Jelinek <jakub@redhat.com>2019-06-26 10:26:18 +0200
committerJakub Jelinek <jakub@gcc.gnu.org>2019-06-26 10:26:18 +0200
commitd55c1ffd497193b56ee9f7540d5b0eadf6717c42 (patch)
tree33f8ef728b08279bcf026ded097617d64610277f /gcc/config
parentfdfbed383e48f9a6fce6ef1e0e0defea0363ac3f (diff)
downloadgcc-d55c1ffd497193b56ee9f7540d5b0eadf6717c42.zip
gcc-d55c1ffd497193b56ee9f7540d5b0eadf6717c42.tar.gz
gcc-d55c1ffd497193b56ee9f7540d5b0eadf6717c42.tar.bz2
re PR target/90991 (_mm_loadu_ps instrinsic translates to vmovaps in combination with _mm512_insertf32x4)
PR target/90991 * config/i386/sse.md (*<extract_type>_vinsert<shuffletype><extract_suf>_0): Use vmovupd, vmovups, vmovdqu, vmovdqu32 or vmovdqu64 instead of the aligned insns if operands[2] is misaligned_operand. * gcc.target/i386/avx512dq-pr90991-1.c: New test. From-SVN: r272674
Diffstat (limited to 'gcc/config')
-rw-r--r--gcc/config/i386/sse.md26
1 files changed, 20 insertions, 6 deletions
diff --git a/gcc/config/i386/sse.md b/gcc/config/i386/sse.md
index abf7d98..29f16bc 100644
--- a/gcc/config/i386/sse.md
+++ b/gcc/config/i386/sse.md
@@ -13747,15 +13747,29 @@
switch (<MODE>mode)
{
case E_V8DFmode:
- return "vmovapd\t{%2, %x0|%x0, %2}";
+ if (misaligned_operand (operands[2], <ssequartermode>mode))
+ return "vmovupd\t{%2, %x0|%x0, %2}";
+ else
+ return "vmovapd\t{%2, %x0|%x0, %2}";
case E_V16SFmode:
- return "vmovaps\t{%2, %x0|%x0, %2}";
+ if (misaligned_operand (operands[2], <ssequartermode>mode))
+ return "vmovups\t{%2, %x0|%x0, %2}";
+ else
+ return "vmovaps\t{%2, %x0|%x0, %2}";
case E_V8DImode:
- return which_alternative == 2 ? "vmovdqa64\t{%2, %x0|%x0, %2}"
- : "vmovdqa\t{%2, %x0|%x0, %2}";
+ if (misaligned_operand (operands[2], <ssequartermode>mode))
+ return which_alternative == 2 ? "vmovdqu64\t{%2, %x0|%x0, %2}"
+ : "vmovdqu\t{%2, %x0|%x0, %2}";
+ else
+ return which_alternative == 2 ? "vmovdqa64\t{%2, %x0|%x0, %2}"
+ : "vmovdqa\t{%2, %x0|%x0, %2}";
case E_V16SImode:
- return which_alternative == 2 ? "vmovdqa32\t{%2, %x0|%x0, %2}"
- : "vmovdqa\t{%2, %x0|%x0, %2}";
+ if (misaligned_operand (operands[2], <ssequartermode>mode))
+ return which_alternative == 2 ? "vmovdqu32\t{%2, %x0|%x0, %2}"
+ : "vmovdqu\t{%2, %x0|%x0, %2}";
+ else
+ return which_alternative == 2 ? "vmovdqa32\t{%2, %x0|%x0, %2}"
+ : "vmovdqa\t{%2, %x0|%x0, %2}";
default:
gcc_unreachable ();
}