21 lines · plain
1! This test checks bind(c) procs inside BLOCK construct.2 3!RUN: %flang_fc1 -emit-hlfir %s -o - | FileCheck %s4 5module m6 interface7 subroutine test_proc() bind(C)8 end subroutine test_proc9 end interface10end module m11!CHECK-DAG: %[[S0:.*]] = llvm.intr.stacksave : !llvm.ptr12!CHECK-DAG: fir.call @test_proc() proc_attrs<bind_c> fastmath<contract> : () -> ()13!CHECK-DAG: llvm.intr.stackrestore %[[S0]] : !llvm.ptr14!CHECK-DAG: func.func private @test_proc() attributes {fir.bindc_name = "test_proc", fir.proc_attrs = #fir.proc_attrs<bind_c>}15subroutine test16 BLOCK17 use m18 call test_proc19 END BLOCK20end subroutine test21