llvm-project/flang/test/Lower/module-debug-file-loc-linux.f90
Kiran Chandramohan eef0210706 [Flang][Debug] Modifications for getting pathname
-> Use file pathname from the Flang frontend. It is the frontend
that is in-charge of finding the files and is hence the canonical
source for paths.
-> Convert pathname to absolute pathname while creating the moduleOp.

Co-authored-by: Peter Klausler <pklausler@nvidia.com>

Reviewed By: PeteSteinfeld, vzakhari, jeanPerier, awarzynski

Differential Revision: https://reviews.llvm.org/D141674
2023-01-19 16:58:39 +00:00

15 lines
389 B
Fortran

! Test that the module has the location information
! RUN: %flang_fc1 -mmlir --mlir-print-debuginfo -emit-fir -o - %s | FileCheck %s
! REQUIRES: linux
subroutine sb1()
end subroutine
! CHECK: module attributes
! CHECK: func.func @_QPsb1() {
! CHECK: }
! CHECK: } loc(#[[MODULE_LOC:.*]])
! CHECK: #[[MODULE_LOC]] = loc("/{{.*}}flang/test/Lower/module-debug-file-loc-linux.f90":0:0)