• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1; RUN: llc < %s -mtriple=aarch64-eabi -mattr=+slow-paired-128 -verify-machineinstrs -asm-verbose=false | FileCheck %s --check-prefixes=CHECK,SLOW
2; RUN: llc < %s -mtriple=aarch64-eabi -mcpu=exynos-m1         -verify-machineinstrs -asm-verbose=false | FileCheck %s --check-prefixes=CHECK,SLOW
3; RUN: llc < %s -mtriple=aarch64-eabi -mcpu=exynos-m3         -verify-machineinstrs -asm-verbose=false | FileCheck %s --check-prefixes=CHECK,FAST
4
5; CHECK-LABEL: test_nopair_st
6; SLOW: str
7; SLOW: stur
8; SLOW-NOT: stp
9; FAST: stp
10define void @test_nopair_st(double* %ptr, <2 x double> %v1, <2 x double> %v2) {
11  %tmp1 = bitcast double* %ptr to <2 x double>*
12  store <2 x double> %v2, <2 x double>* %tmp1, align 16
13  %add.ptr = getelementptr inbounds double, double* %ptr, i64 -2
14  %tmp = bitcast double* %add.ptr to <2 x double>*
15  store <2 x double> %v1, <2 x double>* %tmp, align 16
16  ret void
17}
18
19; CHECK-LABEL: test_nopair_ld
20; SLOW: ldr
21; SLOW: ldr
22; SLOW-NOT: ldp
23; FAST: ldp
24define <2 x i64> @test_nopair_ld(i64* %p) {
25  %a1 = bitcast i64* %p to <2 x i64>*
26  %tmp1 = load <2 x i64>, < 2 x i64>* %a1, align 8
27  %add.ptr2 = getelementptr inbounds i64, i64* %p, i64 2
28  %a2 = bitcast i64* %add.ptr2 to <2 x i64>*
29  %tmp2 = load <2 x i64>, <2 x i64>* %a2, align 8
30  %add = add nsw <2 x i64> %tmp1, %tmp2
31  ret <2 x i64> %add
32}
33