[LLVM][IR] Use splat syntax when printing ConstantExpr based splats. (#116856)
[llvm-project.git] / clang / test / CodeGen / asm_arm64.c
blob4834eea85f6734b9525d60ce5864d5afa33b6710
1 // RUN: %clang_cc1 -triple arm64-apple-ios -emit-llvm -o - %s | FileCheck %s
3 int t1(void)
5 int x;
6 __asm__("mov %0, 7" : "=r" (x));
7 return x;
10 long t2(void)
12 long x;
13 __asm__("mov %0, 7" : "=r" (x));
14 return x;
17 long t3(void)
19 long x;
20 __asm__("mov %w0, 7" : "=r" (x));
21 return x;
24 void t4(long op) {
25 long x1;
26 asm ("mov x0, %1; svc #0;" : "=r"(x1) :"r"(op),"r"(x1) :"x0" );
29 float t5(float x) {
30 __asm__("fadd %0, %0, %0" : "+w" (x));
31 return x;
34 void t6 (void *f, int g) {
35 // CHECK: t6
36 // CHECK: call void asm "str $1, $0", "=*Q,r"
37 asm("str %1, %0" : "=Q"(f) : "r"(g));