llvm.org GIT mirror llvm / b867bf3
[AVX512] Fix shuffle decode printing for several instructions with write masks. There are still more bugs here with UNPCK and PALIGN for sure. But these were the easiest ones to fix. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@272252 91177308-0d34-0410-b5e6-96231b3b80d8 Craig Topper 4 years ago
5 changed file(s) with 25 addition(s) and 25 deletion(s). Raw diff Collapse all Expand all
354354 break;
355355
356356 CASE_SHUF(PSHUFD, ri)
357 Src1Name = getRegName(MI->getOperand(1).getReg());
357 Src1Name = getRegName(MI->getOperand(NumOperands - 2).getReg());
358358 // FALL THROUGH.
359359 CASE_SHUF(PSHUFD, mi)
360360 DestName = getRegName(MI->getOperand(0).getReg());
365365 break;
366366
367367 CASE_SHUF(PSHUFHW, ri)
368 Src1Name = getRegName(MI->getOperand(1).getReg());
368 Src1Name = getRegName(MI->getOperand(NumOperands - 2).getReg());
369369 // FALL THROUGH.
370370 CASE_SHUF(PSHUFHW, mi)
371371 DestName = getRegName(MI->getOperand(0).getReg());
376376 break;
377377
378378 CASE_SHUF(PSHUFLW, ri)
379 Src1Name = getRegName(MI->getOperand(1).getReg());
379 Src1Name = getRegName(MI->getOperand(NumOperands - 2).getReg());
380380 // FALL THROUGH.
381381 CASE_SHUF(PSHUFLW, mi)
382382 DestName = getRegName(MI->getOperand(0).getReg());
64426442 ; CHECK-LABEL: test_int_x86_avx512_mask_pshuf_d_512:
64436443 ; CHECK: ## BB#0:
64446444 ; CHECK-NEXT: kmovw %esi, %k1
6445 ; CHECK-NEXT: vpshufd {{.*#+}} zmm1 = zmm1[3,0,0,0,7,4,4,4,11,8,8,8,15,12,12,12]
6446 ; CHECK-NEXT: vpshufd {{.*#+}} zmm2 = k1[3,0,0,0,7,4,4,4,11,8,8,8,15,12,12,12]
6445 ; CHECK-NEXT: vpshufd {{.*#+}} zmm1 = zmm0[3,0,0,0,7,4,4,4,11,8,8,8,15,12,12,12]
6446 ; CHECK-NEXT: vpshufd {{.*#+}} zmm2 = zmm0[3,0,0,0,7,4,4,4,11,8,8,8,15,12,12,12]
64476447 ; CHECK-NEXT: vpshufd {{.*#+}} zmm0 = zmm0[3,0,0,0,7,4,4,4,11,8,8,8,15,12,12,12]
64486448 ; CHECK-NEXT: vpaddd %zmm2, %zmm1, %zmm1
64496449 ; CHECK-NEXT: vpaddd %zmm0, %zmm1, %zmm0
29912991 ; AVX512BW-LABEL: test_int_x86_avx512_mask_pshufh_w_512:
29922992 ; AVX512BW: ## BB#0:
29932993 ; AVX512BW-NEXT: kmovd %esi, %k1
2994 ; AVX512BW-NEXT: vpshufhw {{.*#+}} zmm1 = zmm1[0,1,2,3,7,4,4,4,8,9,10,11,15,12,12,12,16,17,18,19,23,20,20,20,24,25,26,27,31,28,28,28]
2995 ; AVX512BW-NEXT: vpshufhw {{.*#+}} zmm2 = k1[0,1,2,3,7,4,4,4,8,9,10,11,15,12,12,12,16,17,18,19,23,20,20,20,24,25,26,27,31,28,28,28]
2994 ; AVX512BW-NEXT: vpshufhw {{.*#+}} zmm1 = zmm0[0,1,2,3,7,4,4,4,8,9,10,11,15,12,12,12,16,17,18,19,23,20,20,20,24,25,26,27,31,28,28,28]
2995 ; AVX512BW-NEXT: vpshufhw {{.*#+}} zmm2 = zmm0[0,1,2,3,7,4,4,4,8,9,10,11,15,12,12,12,16,17,18,19,23,20,20,20,24,25,26,27,31,28,28,28]
29962996 ; AVX512BW-NEXT: vpshufhw {{.*#+}} zmm0 = zmm0[0,1,2,3,7,4,4,4,8,9,10,11,15,12,12,12,16,17,18,19,23,20,20,20,24,25,26,27,31,28,28,28]
29972997 ; AVX512BW-NEXT: vpaddw %zmm2, %zmm1, %zmm1
29982998 ; AVX512BW-NEXT: vpaddw %zmm0, %zmm1, %zmm0
30013001 ; AVX512F-32-LABEL: test_int_x86_avx512_mask_pshufh_w_512:
30023002 ; AVX512F-32: # BB#0:
30033003 ; AVX512F-32-NEXT: kmovd {{[0-9]+}}(%esp), %k1
3004 ; AVX512F-32-NEXT: vpshufhw {{.*#+}} zmm1 = zmm1[0,1,2,3,7,4,4,4,8,9,10,11,15,12,12,12,16,17,18,19,23,20,20,20,24,25,26,27,31,28,28,28]
3005 ; AVX512F-32-NEXT: vpshufhw {{.*#+}} zmm2 = k1[0,1,2,3,7,4,4,4,8,9,10,11,15,12,12,12,16,17,18,19,23,20,20,20,24,25,26,27,31,28,28,28]
3004 ; AVX512F-32-NEXT: vpshufhw {{.*#+}} zmm1 = zmm0[0,1,2,3,7,4,4,4,8,9,10,11,15,12,12,12,16,17,18,19,23,20,20,20,24,25,26,27,31,28,28,28]
3005 ; AVX512F-32-NEXT: vpshufhw {{.*#+}} zmm2 = zmm0[0,1,2,3,7,4,4,4,8,9,10,11,15,12,12,12,16,17,18,19,23,20,20,20,24,25,26,27,31,28,28,28]
30063006 ; AVX512F-32-NEXT: vpshufhw {{.*#+}} zmm0 = zmm0[0,1,2,3,7,4,4,4,8,9,10,11,15,12,12,12,16,17,18,19,23,20,20,20,24,25,26,27,31,28,28,28]
30073007 ; AVX512F-32-NEXT: vpaddw %zmm2, %zmm1, %zmm1
30083008 ; AVX512F-32-NEXT: vpaddw %zmm0, %zmm1, %zmm0
30213021 ; AVX512BW-LABEL: test_int_x86_avx512_mask_pshufl_w_512:
30223022 ; AVX512BW: ## BB#0:
30233023 ; AVX512BW-NEXT: kmovd %esi, %k1
3024 ; AVX512BW-NEXT: vpshuflw {{.*#+}} zmm1 = zmm1[3,0,0,0,4,5,6,7,11,8,8,8,12,13,14,15,19,16,16,16,20,21,22,23,27,24,24,24,28,29,30,31]
3025 ; AVX512BW-NEXT: vpshuflw {{.*#+}} zmm2 = k1[3,0,0,0,4,5,6,7,11,8,8,8,12,13,14,15,19,16,16,16,20,21,22,23,27,24,24,24,28,29,30,31]
3024 ; AVX512BW-NEXT: vpshuflw {{.*#+}} zmm1 = zmm0[3,0,0,0,4,5,6,7,11,8,8,8,12,13,14,15,19,16,16,16,20,21,22,23,27,24,24,24,28,29,30,31]
3025 ; AVX512BW-NEXT: vpshuflw {{.*#+}} zmm2 = zmm0[3,0,0,0,4,5,6,7,11,8,8,8,12,13,14,15,19,16,16,16,20,21,22,23,27,24,24,24,28,29,30,31]
30263026 ; AVX512BW-NEXT: vpshuflw {{.*#+}} zmm0 = zmm0[3,0,0,0,4,5,6,7,11,8,8,8,12,13,14,15,19,16,16,16,20,21,22,23,27,24,24,24,28,29,30,31]
30273027 ; AVX512BW-NEXT: vpaddw %zmm2, %zmm1, %zmm1
30283028 ; AVX512BW-NEXT: vpaddw %zmm0, %zmm1, %zmm0
30313031 ; AVX512F-32-LABEL: test_int_x86_avx512_mask_pshufl_w_512:
30323032 ; AVX512F-32: # BB#0:
30333033 ; AVX512F-32-NEXT: kmovd {{[0-9]+}}(%esp), %k1
3034 ; AVX512F-32-NEXT: vpshuflw {{.*#+}} zmm1 = zmm1[3,0,0,0,4,5,6,7,11,8,8,8,12,13,14,15,19,16,16,16,20,21,22,23,27,24,24,24,28,29,30,31]
3035 ; AVX512F-32-NEXT: vpshuflw {{.*#+}} zmm2 = k1[3,0,0,0,4,5,6,7,11,8,8,8,12,13,14,15,19,16,16,16,20,21,22,23,27,24,24,24,28,29,30,31]
3034 ; AVX512F-32-NEXT: vpshuflw {{.*#+}} zmm1 = zmm0[3,0,0,0,4,5,6,7,11,8,8,8,12,13,14,15,19,16,16,16,20,21,22,23,27,24,24,24,28,29,30,31]
3035 ; AVX512F-32-NEXT: vpshuflw {{.*#+}} zmm2 = zmm0[3,0,0,0,4,5,6,7,11,8,8,8,12,13,14,15,19,16,16,16,20,21,22,23,27,24,24,24,28,29,30,31]
30363036 ; AVX512F-32-NEXT: vpshuflw {{.*#+}} zmm0 = zmm0[3,0,0,0,4,5,6,7,11,8,8,8,12,13,14,15,19,16,16,16,20,21,22,23,27,24,24,24,28,29,30,31]
30373037 ; AVX512F-32-NEXT: vpaddw %zmm2, %zmm1, %zmm1
30383038 ; AVX512F-32-NEXT: vpaddw %zmm0, %zmm1, %zmm0
59465946 ; CHECK: ## BB#0:
59475947 ; CHECK-NEXT: kmovw %esi, %k1 ## encoding: [0xc5,0xf8,0x92,0xce]
59485948 ; CHECK-NEXT: vpshufhw $3, %xmm0, %xmm1 {%k1} ## encoding: [0x62,0xf1,0x7e,0x09,0x70,0xc8,0x03]
5949 ; CHECK-NEXT: ## xmm1 = xmm1[0,1,2,3,7,4,4,4]
5949 ; CHECK-NEXT: ## xmm1 = xmm0[0,1,2,3,7,4,4,4]
59505950 ; CHECK-NEXT: vpshufhw $3, %xmm0, %xmm2 {%k1} {z} ## encoding: [0x62,0xf1,0x7e,0x89,0x70,0xd0,0x03]
5951 ; CHECK-NEXT: ## xmm2 = k1[0,1,2,3,7,4,4,4]
5951 ; CHECK-NEXT: ## xmm2 = xmm0[0,1,2,3,7,4,4,4]
59525952 ; CHECK-NEXT: vpshufhw $3, %xmm0, %xmm0 ## encoding: [0x62,0xf1,0x7e,0x08,0x70,0xc0,0x03]
59535953 ; CHECK-NEXT: ## xmm0 = xmm0[0,1,2,3,7,4,4,4]
59545954 ; CHECK-NEXT: vpaddw %xmm2, %xmm1, %xmm1 ## encoding: [0x62,0xf1,0x75,0x08,0xfd,0xca]
59695969 ; CHECK: ## BB#0:
59705970 ; CHECK-NEXT: kmovw %esi, %k1 ## encoding: [0xc5,0xf8,0x92,0xce]
59715971 ; CHECK-NEXT: vpshufhw $3, %ymm0, %ymm1 {%k1} ## encoding: [0x62,0xf1,0x7e,0x29,0x70,0xc8,0x03]
5972 ; CHECK-NEXT: ## ymm1 = ymm1[0,1,2,3,7,4,4,4,8,9,10,11,15,12,12,12]
5972 ; CHECK-NEXT: ## ymm1 = ymm0[0,1,2,3,7,4,4,4,8,9,10,11,15,12,12,12]
59735973 ; CHECK-NEXT: vpshufhw $3, %ymm0, %ymm2 {%k1} {z} ## encoding: [0x62,0xf1,0x7e,0xa9,0x70,0xd0,0x03]
5974 ; CHECK-NEXT: ## ymm2 = k1[0,1,2,3,7,4,4,4,8,9,10,11,15,12,12,12]
5974 ; CHECK-NEXT: ## ymm2 = ymm0[0,1,2,3,7,4,4,4,8,9,10,11,15,12,12,12]
59755975 ; CHECK-NEXT: vpshufhw $3, %ymm0, %ymm0 ## encoding: [0x62,0xf1,0x7e,0x28,0x70,0xc0,0x03]
59765976 ; CHECK-NEXT: ## ymm0 = ymm0[0,1,2,3,7,4,4,4,8,9,10,11,15,12,12,12]
59775977 ; CHECK-NEXT: vpaddw %ymm2, %ymm1, %ymm1 ## encoding: [0x62,0xf1,0x75,0x28,0xfd,0xca]
59925992 ; CHECK: ## BB#0:
59935993 ; CHECK-NEXT: kmovw %esi, %k1 ## encoding: [0xc5,0xf8,0x92,0xce]
59945994 ; CHECK-NEXT: vpshuflw $3, %xmm0, %xmm1 {%k1} ## encoding: [0x62,0xf1,0x7f,0x09,0x70,0xc8,0x03]
5995 ; CHECK-NEXT: ## xmm1 = xmm1[3,0,0,0,4,5,6,7]
5995 ; CHECK-NEXT: ## xmm1 = xmm0[3,0,0,0,4,5,6,7]
59965996 ; CHECK-NEXT: vpshuflw $3, %xmm0, %xmm2 {%k1} {z} ## encoding: [0x62,0xf1,0x7f,0x89,0x70,0xd0,0x03]
5997 ; CHECK-NEXT: ## xmm2 = k1[3,0,0,0,4,5,6,7]
5997 ; CHECK-NEXT: ## xmm2 = xmm0[3,0,0,0,4,5,6,7]
59985998 ; CHECK-NEXT: vpshuflw $3, %xmm0, %xmm0 ## encoding: [0x62,0xf1,0x7f,0x08,0x70,0xc0,0x03]
59995999 ; CHECK-NEXT: ## xmm0 = xmm0[3,0,0,0,4,5,6,7]
60006000 ; CHECK-NEXT: vpaddw %xmm2, %xmm1, %xmm1 ## encoding: [0x62,0xf1,0x75,0x08,0xfd,0xca]
60156015 ; CHECK: ## BB#0:
60166016 ; CHECK-NEXT: kmovw %esi, %k1 ## encoding: [0xc5,0xf8,0x92,0xce]
60176017 ; CHECK-NEXT: vpshuflw $3, %ymm0, %ymm1 {%k1} ## encoding: [0x62,0xf1,0x7f,0x29,0x70,0xc8,0x03]
6018 ; CHECK-NEXT: ## ymm1 = ymm1[3,0,0,0,4,5,6,7,11,8,8,8,12,13,14,15]
6018 ; CHECK-NEXT: ## ymm1 = ymm0[3,0,0,0,4,5,6,7,11,8,8,8,12,13,14,15]
60196019 ; CHECK-NEXT: vpshuflw $3, %ymm0, %ymm2 {%k1} {z} ## encoding: [0x62,0xf1,0x7f,0xa9,0x70,0xd0,0x03]
6020 ; CHECK-NEXT: ## ymm2 = k1[3,0,0,0,4,5,6,7,11,8,8,8,12,13,14,15]
6020 ; CHECK-NEXT: ## ymm2 = ymm0[3,0,0,0,4,5,6,7,11,8,8,8,12,13,14,15]
60216021 ; CHECK-NEXT: vpshuflw $3, %ymm0, %ymm0 ## encoding: [0x62,0xf1,0x7f,0x28,0x70,0xc0,0x03]
60226022 ; CHECK-NEXT: ## ymm0 = ymm0[3,0,0,0,4,5,6,7,11,8,8,8,12,13,14,15]
60236023 ; CHECK-NEXT: vpaddw %ymm2, %ymm1, %ymm1 ## encoding: [0x62,0xf1,0x75,0x28,0xfd,0xca]
95519551 ; CHECK: ## BB#0:
95529552 ; CHECK-NEXT: kmovw %esi, %k1 ## encoding: [0xc5,0xf8,0x92,0xce]
95539553 ; CHECK-NEXT: vpshufd $3, %xmm0, %xmm1 {%k1} ## encoding: [0x62,0xf1,0x7d,0x09,0x70,0xc8,0x03]
9554 ; CHECK-NEXT: ## xmm1 = xmm1[3,0,0,0]
9554 ; CHECK-NEXT: ## xmm1 = xmm0[3,0,0,0]
95559555 ; CHECK-NEXT: vpshufd $3, %xmm0, %xmm2 {%k1} {z} ## encoding: [0x62,0xf1,0x7d,0x89,0x70,0xd0,0x03]
9556 ; CHECK-NEXT: ## xmm2 = k1[3,0,0,0]
9556 ; CHECK-NEXT: ## xmm2 = xmm0[3,0,0,0]
95579557 ; CHECK-NEXT: vpshufd $3, %xmm0, %xmm0 ## encoding: [0x62,0xf1,0x7d,0x08,0x70,0xc0,0x03]
95589558 ; CHECK-NEXT: ## xmm0 = xmm0[3,0,0,0]
95599559 ; CHECK-NEXT: vpaddd %xmm2, %xmm1, %xmm1 ## encoding: [0x62,0xf1,0x75,0x08,0xfe,0xca]
95749574 ; CHECK: ## BB#0:
95759575 ; CHECK-NEXT: kmovw %esi, %k1 ## encoding: [0xc5,0xf8,0x92,0xce]
95769576 ; CHECK-NEXT: vpshufd $3, %ymm0, %ymm1 {%k1} ## encoding: [0x62,0xf1,0x7d,0x29,0x70,0xc8,0x03]
9577 ; CHECK-NEXT: ## ymm1 = ymm1[3,0,0,0,7,4,4,4]
9577 ; CHECK-NEXT: ## ymm1 = ymm0[3,0,0,0,7,4,4,4]
95789578 ; CHECK-NEXT: vpshufd $3, %ymm0, %ymm2 {%k1} {z} ## encoding: [0x62,0xf1,0x7d,0xa9,0x70,0xd0,0x03]
9579 ; CHECK-NEXT: ## ymm2 = k1[3,0,0,0,7,4,4,4]
9579 ; CHECK-NEXT: ## ymm2 = ymm0[3,0,0,0,7,4,4,4]
95809580 ; CHECK-NEXT: vpshufd $3, %ymm0, %ymm0 ## encoding: [0x62,0xf1,0x7d,0x28,0x70,0xc0,0x03]
95819581 ; CHECK-NEXT: ## ymm0 = ymm0[3,0,0,0,7,4,4,4]
95829582 ; CHECK-NEXT: vpaddd %ymm2, %ymm1, %ymm1 ## encoding: [0x62,0xf1,0x75,0x28,0xfe,0xca]