flang/test/Lower/Intrinsics/dprod.f90
raw| 1 | ! RUN: bbc -emit-fir -hlfir=false %s -o - | FileCheck %s |
| 2 | |
| 3 | ! CHECK-LABEL: dprod_test |
| 4 | subroutine dprod_test (x, y, z) |
| 5 | real :: x,y |
| 6 | double precision :: z |
| 7 | z = dprod(x,y) |
| 8 | ! CHECK-DAG: %[[x:.*]] = fir.load %arg0 |
| 9 | ! CHECK-DAG: %[[y:.*]] = fir.load %arg1 |
| 10 | ! CHECK-DAG: %[[a:.*]] = fir.convert %[[x]] : (f32) -> f64 |
| 11 | ! CHECK-DAG: %[[b:.*]] = fir.convert %[[y]] : (f32) -> f64 |
| 12 | ! CHECK: %[[res:.*]] = arith.mulf %[[a]], %[[b]] |
| 13 | ! CHECK: fir.store %[[res]] to %arg2 |
| 14 | end subroutine |