|
1 | 1 | ; NOTE: Assertions have been autogenerated by utils/update_llc_test_checks.py UTC_ARGS: --version 5
|
2 |
| -; RUN: llc < %s -mtriple=x86_64-- -mattr=+x87,-sse2,-sse | FileCheck %s --check-prefixes=X64 |
3 |
| -; RUN: llc < %s -mtriple=x86_64-- -mattr=+x87,-sse2,-sse -fast-isel | FileCheck %s --check-prefixes=X64 |
4 |
| -; RUN: llc < %s -mtriple=x86_64-- -mattr=+x87,-sse2,-sse -global-isel -global-isel-abort=1 | FileCheck %s --check-prefixes=X64 |
5 |
| -; RUN: llc < %s -mtriple=i686-- -mattr=+x87,-sse2,-sse | FileCheck %s --check-prefixes=X86,SDAG-ISEL |
6 |
| -; RUN: llc < %s -mtriple=i686-- -mattr=+x87,-sse2,-sse -fast-isel | FileCheck %s --check-prefixes=X86,Fast-ISEL |
7 |
| -; RUN: llc < %s -mtriple=i686-- -mattr=+x87,-sse2,-sse -global-isel -global-isel-abort=0 | FileCheck %s --check-prefixes=X86,GISEL-ISEL |
| 2 | +; RUN: llc < %s -mtriple=x86_64-- -mattr=+x87,-sse2,-sse | FileCheck %s --check-prefixes=X64,SDAG-X64-ISEL |
| 3 | +; RUN: llc < %s -mtriple=x86_64-- -mattr=+x87,-sse2,-sse -fast-isel | FileCheck %s --check-prefixes=X64,FAST-X64-ISEL |
| 4 | +; RUN: llc < %s -mtriple=x86_64-- -mattr=+x87,-sse2,-sse -global-isel -global-isel-abort=1 | FileCheck %s --check-prefixes=X64,GISEL-X64-ISEL |
| 5 | +; RUN: llc < %s -mtriple=i686-- -mattr=+x87,-sse2,-sse | FileCheck %s --check-prefixes=X86,SDAG-X86-ISEL |
| 6 | +; RUN: llc < %s -mtriple=i686-- -mattr=+x87,-sse2,-sse -fast-isel | FileCheck %s --check-prefixes=X86,FAST-X86-ISEL |
| 7 | +; RUN: llc < %s -mtriple=i686-- -mattr=+x87,-sse2,-sse -global-isel -global-isel-abort=0 | FileCheck %s --check-prefixes=X86,GISEL-X86-ISEL |
8 | 8 |
|
9 | 9 | define void @test_float_abs(ptr %argptr) {
|
10 |
| -; SDAG-ISEL-LABEL: test_float_abs: |
11 |
| -; SDAG-ISEL: # %bb.0: |
12 |
| -; SDAG-ISEL-NEXT: movl {{[0-9]+}}(%esp), %eax |
13 |
| -; SDAG-ISEL-NEXT: andb $127, 3(%eax) |
14 |
| -; SDAG-ISEL-NEXT: retl |
15 |
| -; |
16 |
| -; Fast-ISEL-LABEL: test_float_abs: |
17 |
| -; Fast-ISEL: # %bb.0: |
18 |
| -; Fast-ISEL-NEXT: movl {{[0-9]+}}(%esp), %eax |
19 |
| -; Fast-ISEL-NEXT: andb $127, 3(%eax) |
20 |
| -; Fast-ISEL-NEXT: retl |
21 |
| -; |
22 |
| -; GISEL-ISEL-LABEL: test_float_abs: |
23 |
| -; GISEL-ISEL: # %bb.0: |
24 |
| -; GISEL-ISEL-NEXT: movl {{[0-9]+}}(%esp), %eax |
25 |
| -; GISEL-ISEL-NEXT: andl $2147483647, (%eax) # imm = 0x7FFFFFFF |
26 |
| -; GISEL-ISEL-NEXT: retl |
| 10 | +; SDAG-X64-ISEL-LABEL: test_float_abs: |
| 11 | +; SDAG-X64-ISEL: # %bb.0: |
| 12 | +; SDAG-X64-ISEL-NEXT: andb $127, 3(%rdi) |
| 13 | +; SDAG-X64-ISEL-NEXT: retq |
| 14 | +; |
| 15 | +; FAST-X64-ISEL-LABEL: test_float_abs: |
| 16 | +; FAST-X64-ISEL: # %bb.0: |
| 17 | +; FAST-X64-ISEL-NEXT: andb $127, 3(%rdi) |
| 18 | +; FAST-X64-ISEL-NEXT: retq |
| 19 | +; |
| 20 | +; GISEL-X64-ISEL-LABEL: test_float_abs: |
| 21 | +; GISEL-X64-ISEL: # %bb.0: |
| 22 | +; GISEL-X64-ISEL-NEXT: andl $2147483647, (%rdi) # imm = 0x7FFFFFFF |
| 23 | +; GISEL-X64-ISEL-NEXT: retq |
| 24 | +; |
| 25 | +; SDAG-X86-ISEL-LABEL: test_float_abs: |
| 26 | +; SDAG-X86-ISEL: # %bb.0: |
| 27 | +; SDAG-X86-ISEL-NEXT: movl {{[0-9]+}}(%esp), %eax |
| 28 | +; SDAG-X86-ISEL-NEXT: andb $127, 3(%eax) |
| 29 | +; SDAG-X86-ISEL-NEXT: retl |
| 30 | +; |
| 31 | +; FAST-X86-ISEL-LABEL: test_float_abs: |
| 32 | +; FAST-X86-ISEL: # %bb.0: |
| 33 | +; FAST-X86-ISEL-NEXT: movl {{[0-9]+}}(%esp), %eax |
| 34 | +; FAST-X86-ISEL-NEXT: andb $127, 3(%eax) |
| 35 | +; FAST-X86-ISEL-NEXT: retl |
| 36 | +; |
| 37 | +; GISEL-X86-ISEL-LABEL: test_float_abs: |
| 38 | +; GISEL-X86-ISEL: # %bb.0: |
| 39 | +; GISEL-X86-ISEL-NEXT: movl {{[0-9]+}}(%esp), %eax |
| 40 | +; GISEL-X86-ISEL-NEXT: andl $2147483647, (%eax) # imm = 0x7FFFFFFF |
| 41 | +; GISEL-X86-ISEL-NEXT: retl |
27 | 42 | %arg = load float, float* %argptr
|
28 | 43 | %abs = tail call float @llvm.fabs.f32(float %arg)
|
29 | 44 | store float %abs, ptr %argptr
|
30 | 45 | ret void
|
31 | 46 | }
|
32 | 47 |
|
33 | 48 | define void @test_double_abs(ptr %argptr) {
|
| 49 | +; SDAG-X64-ISEL-LABEL: test_double_abs: |
| 50 | +; SDAG-X64-ISEL: # %bb.0: |
| 51 | +; SDAG-X64-ISEL-NEXT: andb $127, 7(%rdi) |
| 52 | +; SDAG-X64-ISEL-NEXT: retq |
| 53 | +; |
| 54 | +; FAST-X64-ISEL-LABEL: test_double_abs: |
| 55 | +; FAST-X64-ISEL: # %bb.0: |
| 56 | +; FAST-X64-ISEL-NEXT: andb $127, 7(%rdi) |
| 57 | +; FAST-X64-ISEL-NEXT: retq |
| 58 | +; |
| 59 | +; GISEL-X64-ISEL-LABEL: test_double_abs: |
| 60 | +; GISEL-X64-ISEL: # %bb.0: |
| 61 | +; GISEL-X64-ISEL-NEXT: movabsq $9223372036854775807, %rax # imm = 0x7FFFFFFFFFFFFFFF |
| 62 | +; GISEL-X64-ISEL-NEXT: andq %rax, (%rdi) |
| 63 | +; GISEL-X64-ISEL-NEXT: retq |
| 64 | +; |
34 | 65 | ; X86-LABEL: test_double_abs:
|
35 | 66 | ; X86: # %bb.0:
|
36 | 67 | ; X86-NEXT: movl {{[0-9]+}}(%esp), %eax
|
|
0 commit comments