- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I use ifort 8.0 and have many #ifdef...#endif's (thousands) in the .F files used to compile/exclude large sections of code. Is there a way collate runs from various -Dxxx options usedinto one output from codecov?
Link Copied
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Make a directory for projects
Make a sub-directory in it called Source
In the Source directory enter the code:
PROGRAM ProfBug
! **********************************************************************
write(*,*) "Compile this with:"
write(*,*) "ifort -fpp -prof_genx -qp -p -g Source/profbugger.F"
write(*,*) "from a directory above the source file."
if (.true.) then
write(*,*) "Run the code a.out"
else
write(*,*) "This is line 3"
endif
call other
write(*,*) "Look at the dyn file and you will see the source"
write(*,*) "listed wrong"
end
subroutine other
integer I
do I = 1,3
write(*,*) "I: ", I
end do
return
end subroutine
Move up one directory and compile and profmerge:
$ ifort -fpp -prof_genx -qp -p -g Source/profbugger.F
$ a.out
Compile this with:
ifort -fpp -prof_genx -qp -p -g Source/profbugger.F
from a directory above the source file.
Run the code a.out
I: 1
I: 2
I: 3
Look at the dyn file and you will see the source
listed wrong
[mjcrawf@crater projects]$ profmerge
profmerge: merging dynamic file: ./4489b960_17385.dyn
[mjcrawf@crater projects]$ codecov
Intel C++/Fortran Compiler code-coverage tool for 32-bit applications, Version 9.0 Build 20050430Z Package ID: l_fc_p_9.0.021
Copyright (C) 1985-2005 Intel Corporation. All rights reserved.
Warning - File /chome/mjcrawf/projects/profbugger.F not found!
50% .. 100%
Also try:
$ profmerge -src_old /chome/mjcrawf/projects -src_new /chome/mjcrawf/projects/Source
profmerge: DPI Source Relocation:
profmerge: old source dir = /chome/mjcrawf/projects
profmerge: new source dir = /chome/mjcrawf/projects/Source
profmerge: relocated 2 of 2 source routines
[mjcrawf@crater projects]$ codecov
Intel C++/Fortran Compiler code-coverage tool for 32-bit applications, Version 9.0 Build 20050430Z Package ID: l_fc_p_9.0.021
Copyright (C) 1985-2005 Intel Corporation. All rights reserved.
Warning - File /chome/mjcrawf/projects/profbugger.F not found!
50% .. 100%
Any suggestions???
Vital Info:
Intel Fortran compiler for Linux
ifort -v
Version 9.0
Linux version 2.4.21-40.ELsmp (bhcompile@hs20-bc1-1.build.redhat.com) (gcc version 3.2.3 20030502 (Red Hat Linux 3.2.3-54)) #1 SMP Thu Feb 2 22:14:12 EST 2006
glibc-2.3.2-95.39
glibc-devel-2.3.2-95.39
glibc-common-2.3.2-95.39
glibc-headers-2.3.2-95.39
glibc-kernheaders-2.4-8.34.2
glibc-utils-2.3.2-95.39
glibc-profile-2.3.2-95.39
gcc -v
Reading specs from /usr/local/lib/gcc/i686-pc-linux-gnu/3.4.1/specs
Configured with: ./configure : (reconfigured) ./configure
< font size="2">Thread model: posix
gcc version 3.4.1
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Back to the original question, but I upgraded to ifort 9.0, and ICC 9.1 and using profmerge l_cc_p_9.1.038 and codecov l_fc_p_9.0.021 with the same result:

- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page