Amjad Aboud | f296082 | 2016-05-12 19:58:32 +0000 | [diff] [blame^] | 1 | ; RUN: llc -verify-machineinstrs -mtriple=x86_64-apple-macosx -show-mc-encoding -mattr=+avx512f < %s | FileCheck %s -check-prefix=CHECK -check-prefix=CHECK64 |
| 2 | ; RUN: llc -verify-machineinstrs -mtriple=i386-apple-macosx -show-mc-encoding -mattr=+avx512f < %s | FileCheck %s -check-prefix=CHECK -check-prefix=CHECK32 |
Quentin Colombet | ee5f36b | 2016-05-10 01:09:14 +0000 | [diff] [blame] | 3 | |
Amjad Aboud | f296082 | 2016-05-12 19:58:32 +0000 | [diff] [blame^] | 4 | ; Make sure we spill the high numbered ZMM registers and K registers with the right encoding. |
Quentin Colombet | ee5f36b | 2016-05-10 01:09:14 +0000 | [diff] [blame] | 5 | ; CHECK-LABEL: foo |
Amjad Aboud | f296082 | 2016-05-12 19:58:32 +0000 | [diff] [blame^] | 6 | ; CHECK: kmovq %k7, {{.+}} |
| 7 | ; CHECK64: encoding: [0xc4,0xe1,0xf8,0x91,0xbc,0x24,0x68,0x08,0x00,0x00] |
| 8 | ; CHECK32: encoding: [0xc4,0xe1,0xf8,0x91,0xbc,0x24,0x68,0x02,0x00,0x00] |
| 9 | ; k6 is used as an anchor for the previous regexp. |
| 10 | ; CHECK-NEXT: kmovq %k6 |
| 11 | |
| 12 | ; CHECK64: movups %zmm31, {{.+}} |
| 13 | ; CHECK64: encoding: [0x62,0x61,0x7c,0x48,0x11,0xbc,0x24,0xe0,0x07,0x00,0x00] |
Craig Topper | 3fef1de | 2016-05-10 05:27:56 +0000 | [diff] [blame] | 14 | ; zmm30 is used as an anchor for the previous regexp. |
Amjad Aboud | f296082 | 2016-05-12 19:58:32 +0000 | [diff] [blame^] | 15 | ; CHECK64-NEXT: movups %zmm30 |
| 16 | |
| 17 | ; CHECK32-NOT: zmm31 |
| 18 | ; CHECK32-NOT: zmm8 |
| 19 | ; CHECK32: movups %zmm7, {{.+}} |
| 20 | ; CHECK32: encoding: [0x62,0xf1,0x7c,0x48,0x11,0xbc,0x24,0xe0,0x01,0x00,0x00] |
| 21 | ; zmm6 is used as an anchor for the previous regexp. |
| 22 | ; CHECK32-NEXT: movups %zmm6 |
| 23 | |
Quentin Colombet | ee5f36b | 2016-05-10 01:09:14 +0000 | [diff] [blame] | 24 | ; CHECK: call |
| 25 | ; CHECK: iret |
| 26 | |
| 27 | define x86_intrcc void @foo(i8* %frame) { |
| 28 | call void @bar() |
| 29 | ret void |
| 30 | } |
| 31 | |
| 32 | declare void @bar() |
| 33 | |