Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
D
darshan
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
72
Issues
72
List
Boards
Labels
Milestones
Merge Requests
5
Merge Requests
5
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
darshan
darshan
Commits
c3946b9d
Commit
c3946b9d
authored
Mar 12, 2015
by
Philip Carns
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
detect dynamic linking in profile conf
parent
2eae92a3
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
58 additions
and
21 deletions
+58
-21
darshan-runtime/share/mpi-profile/darshan-cc.conf.in
darshan-runtime/share/mpi-profile/darshan-cc.conf.in
+16
-5
darshan-runtime/share/mpi-profile/darshan-cxx.conf.in
darshan-runtime/share/mpi-profile/darshan-cxx.conf.in
+21
-8
darshan-runtime/share/mpi-profile/darshan-f.conf.in
darshan-runtime/share/mpi-profile/darshan-f.conf.in
+21
-8
No files found.
darshan-runtime/share/mpi-profile/darshan-cc.conf.in
View file @
c3946b9d
#!/bin/bash
# Example Darshan profiling configuration file for MPICH.
DARSHAN_PREFIX
=
@prefix@
# Check to see if user explicitly specified dynamic linking options
echo
$CFLAGS
|grep
"
\\
-dynamic"
>
& /dev/null
dyncheck1
=
$?
echo
$LDFLAGS
|grep
"
\\
-dynamic"
>
& /dev/null
dyncheck2
=
$?
echo
"
${
allargs
[@]
}
"
|
grep
"
\\
-dynamic"
>
& /dev/null
dyncheck3
=
$?
DARSHAN_PREFIX
=
@prefix@
# Skip profiling if we know that dynamic linking is in use. See LD_PRELOAD
# method instead.
if
[
"
$dyncheck1
"
-ne
0
-a
"
$dyncheck2
"
-ne
0
-a
"
$dyncheck3
"
-ne
0
]
;
then
# Libraries (and paths) to include before the MPI library
export
PROFILE_PRELIB
=
`
$DARSHAN_PREFIX
/bin/darshan-config
--pre-ld-flags
`
# Libraries (and paths) to include before the MPI library
export
PROFILE_PRELIB
=
`
$DARSHAN_PREFIX
/bin/darshan-config
--pre-ld-flags
`
# Libraries to include after the MPI library
export
PROFILE_POSTLIB
=
`
$DARSHAN_PREFIX
/bin/darshan-config
--post-ld-flags
`
# Libraries to include after the MPI library
export
PROFILE_POSTLIB
=
`
$DARSHAN_PREFIX
/bin/darshan-config
--post-ld-flags
`
fi
# C preprocessor arguments for any include files For example, to add
# /usr/local/myprof/include to the include path and the library libmyprof.a in
...
...
darshan-runtime/share/mpi-profile/darshan-cxx.conf.in
View file @
c3946b9d
...
...
@@ -6,15 +6,28 @@
DARSHAN_PREFIX
=
@prefix@
MPICH_LIB_OLD
=
@MPICH_LIB_OLD@
# Libraries (and paths) to include before the MPI library
if
[
$MPICH_LIB_OLD
-eq
1
]
;
then
export
PROFILE_PRELIB
=
"-lmpichcxx
`
$DARSHAN_PREFIX
/bin/darshan-config
--pre-ld-flags
`
"
else
export
PROFILE_PRELIB
=
"-lmpicxx
`
$DARSHAN_PREFIX
/bin/darshan-config
--pre-ld-flags
`
"
fi
# Check to see if user explicitly specified dynamic linking options
echo
$CFLAGS
|grep
"
\\
-dynamic"
>
& /dev/null
dyncheck1
=
$?
echo
$LDFLAGS
|grep
"
\\
-dynamic"
>
& /dev/null
dyncheck2
=
$?
echo
"
${
allargs
[@]
}
"
|
grep
"
\\
-dynamic"
>
& /dev/null
dyncheck3
=
$?
# Skip profiling if we know that dynamic linking is in use. See LD_PRELOAD
# method instead.
if
[
"
$dyncheck1
"
-ne
0
-a
"
$dyncheck2
"
-ne
0
-a
"
$dyncheck3
"
-ne
0
]
;
then
# Libraries to include after the MPI library
export
PROFILE_POSTLIB
=
`
$DARSHAN_PREFIX
/bin/darshan-config
--post-ld-flags
`
# Libraries (and paths) to include before the MPI library
if
[
$MPICH_LIB_OLD
-eq
1
]
;
then
export
PROFILE_PRELIB
=
"-lmpichcxx
`
$DARSHAN_PREFIX
/bin/darshan-config
--pre-ld-flags
`
"
else
export
PROFILE_PRELIB
=
"-lmpicxx
`
$DARSHAN_PREFIX
/bin/darshan-config
--pre-ld-flags
`
"
fi
# Libraries to include after the MPI library
export
PROFILE_POSTLIB
=
`
$DARSHAN_PREFIX
/bin/darshan-config
--post-ld-flags
`
fi
# C preprocessor arguments for any include files For example, to add
# /usr/local/myprof/include to the include path and the library libmyprof.a in
...
...
darshan-runtime/share/mpi-profile/darshan-f.conf.in
View file @
c3946b9d
...
...
@@ -6,15 +6,28 @@
DARSHAN_PREFIX
=
@prefix@
MPICH_LIB_OLD
=
@MPICH_LIB_OLD@
# Libraries (and paths) to include before the MPI library
if
[
$MPICH_LIB_OLD
-eq
1
]
;
then
export
PROFILE_PRELIB
=
"-lfmpich
`
$DARSHAN_PREFIX
/bin/darshan-config
--pre-ld-flags
`
"
else
export
PROFILE_PRELIB
=
"-lmpifort
`
$DARSHAN_PREFIX
/bin/darshan-config
--pre-ld-flags
`
"
fi
# Check to see if user explicitly specified dynamic linking options
echo
$CFLAGS
|grep
"
\\
-dynamic"
>
& /dev/null
dyncheck1
=
$?
echo
$LDFLAGS
|grep
"
\\
-dynamic"
>
& /dev/null
dyncheck2
=
$?
echo
"
${
allargs
[@]
}
"
|
grep
"
\\
-dynamic"
>
& /dev/null
dyncheck3
=
$?
# Skip profiling if we know that dynamic linking is in use. See LD_PRELOAD
# method instead.
if
[
"
$dyncheck1
"
-ne
0
-a
"
$dyncheck2
"
-ne
0
-a
"
$dyncheck3
"
-ne
0
]
;
then
# Libraries to include after the MPI library
export
PROFILE_POSTLIB
=
`
$DARSHAN_PREFIX
/bin/darshan-config
--post-ld-flags
`
# Libraries (and paths) to include before the MPI library
if
[
$MPICH_LIB_OLD
-eq
1
]
;
then
export
PROFILE_PRELIB
=
"-lfmpich
`
$DARSHAN_PREFIX
/bin/darshan-config
--pre-ld-flags
`
"
else
export
PROFILE_PRELIB
=
"-lmpifort
`
$DARSHAN_PREFIX
/bin/darshan-config
--pre-ld-flags
`
"
fi
# Libraries to include after the MPI library
export
PROFILE_POSTLIB
=
`
$DARSHAN_PREFIX
/bin/darshan-config
--post-ld-flags
`
fi
# C preprocessor arguments for any include files For example, to add
# /usr/local/myprof/include to the include path and the library libmyprof.a in
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment