25 lines · c
1// RUN: %clang_cc1 -triple x86_64-unknown-linux-gnu -Wno-unused-value -fclangir -emit-cir %s -o %t.cir2// RUN: FileCheck --input-file=%t.cir %s -check-prefix=CIR3// RUN: %clang_cc1 -triple x86_64-unknown-linux-gnu -fclangir -emit-llvm %s -o %t-cir.ll4// RUN: FileCheck --input-file=%t-cir.ll %s --check-prefix=LLVM5 6void f1() {7 // CIR: cir.asm(x86_att, 8 // CIR: out = [],9 // CIR: in = [],10 // CIR: in_out = [],11 // CIR: {"" "~{dirflag},~{fpsr},~{flags}"}) side_effects12 // LLVM: call void asm sideeffect "", "~{dirflag},~{fpsr},~{flags}"()13 __asm__ volatile("" : : : );14}15 16void f2() {17 // CIR: cir.asm(x86_att,18 // CIR: out = [],19 // CIR: in = [],20 // CIR: in_out = [],21 // CIR: {"nop" "~{dirflag},~{fpsr},~{flags}"}) side_effects22 // LLVM: call void asm sideeffect "nop", "~{dirflag},~{fpsr},~{flags}"()23 __asm__ volatile("nop" : : : );24}25