File: x86-64-veccallcc.ll

package info (click to toggle)
llvm-toolchain-17 1%3A17.0.6-22
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid, trixie
  • size: 1,799,624 kB
  • sloc: cpp: 6,428,607; ansic: 1,383,196; asm: 793,408; python: 223,504; objc: 75,364; f90: 60,502; lisp: 33,869; pascal: 15,282; sh: 9,684; perl: 7,453; ml: 4,937; awk: 3,523; makefile: 2,889; javascript: 2,149; xml: 888; fortran: 619; cs: 573
file content (27 lines) | stat: -rw-r--r-- 1,168 bytes parent folder | download | duplicates (23)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
; RUN: llc -mtriple=x86_64-pc-windows-msvc < %s | FileCheck %s

; Test 1st and 2nd arguments passed in XMM0 and XMM1.
; Test 7nd argument passed by reference in stack: 56(%rsp).
define x86_vectorcallcc <4 x float> @test_m128_7(<4 x float> %a, <4 x float> %b, <4 x float> %c, <4 x float> %d, <4 x float> %e, <4 x float> %f, <4 x float> %g) #0 {
  ; CHECK-LABEL: test_m128_7@@112:
  ; CHECK: movq 56(%rsp), %rax
  ; CHECK: vaddps %xmm1, %xmm0, %xmm0
  ; CHECK: vsubps (%rax), %xmm0, %xmm0
  %add.i = fadd <4 x float> %a, %b
  %sub.i = fsub <4 x float> %add.i, %g
  ret <4 x float> %sub.i
}

; Test 1st and 2nd arguments passed in YMM0 and YMM1.
; Test 7nd argument passed by reference in stack: 56(%rsp).
define x86_vectorcallcc <8 x float> @test_m256_7(<8 x float> %a, <8 x float> %b, <8 x float> %c, <8 x float> %d, <8 x float> %e, <8 x float> %f, <8 x float> %g) #0 {
  ; CHECK-LABEL: test_m256_7@@224:
  ; CHECK: movq 56(%rsp), %rax
  ; CHECK: vaddps %ymm1, %ymm0, %ymm0
  ; CHECK: vsubps (%rax), %ymm0, %ymm0
  %add.i = fadd <8 x float> %a, %b
  %sub.i = fsub <8 x float> %add.i, %g
  ret <8 x float> %sub.i
}

attributes #0 = { nounwind "target-cpu"="core-avx2" }