Commit 3110d8e2 authored by Samuel Thibault's avatar Samuel Thibault

Remove external otf, it is already packaged separately

parent c408ea82
Andreas Knuepfer <andreas.knuepfer AT tu-dresden.de>
Ronny Brendel <ronny.brendel AT tu-dresden.de>
Johannes Spazier <johannes.spazier AT tu-dresden.de>
Matthias Jurenz <matthias.jurenz AT tu-dresden.de>
Bert Wesarg <bert.wesarg AT tu-dresden.de>
Michael Heyde <michael.heyde AT tu-dresden.de>
Michael Kluge <michael.kluge AT tu-dresden.de>
Holger Mickler <holger.mickler AT tu-dresden.de>
Holger Brunst <holger.brunst AT tu-dresden.de>
Hartmut Mix <hartmut.mix AT tu-dresden.de>
Copyright (c) 2005-2011, ZIH, Technische Universitaet Dresden,
Federal Republic of Germany
All rights reserved.
Redistribution and use in source and binary forms, with or without modification,
are permitted provided that the following conditions are met:
- Redistributions of source code must retain the above copyright notice,
this list of conditions and the following disclaimer.
- Redistributions in binary form must reproduce the above copyright notice,
this list of conditions and the following disclaimer in the documentation and/or
other materials provided with the distribution.
- Neither the name of ZIH, TU Dresden nor the names of its contributors
may be used to endorse or promote products derived from this software without
specific prior written permission.
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR
ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
(INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
This diff is collapsed.
This diff is collapsed.
Copyright (c) 2005-2011, ZIH, Technische Universitaet Dresden,
Federal Republic of Germany
All rights reserved.
Redistribution and use in source and binary forms, with or without modification,
are permitted provided that the following conditions are met:
- Redistributions of source code must retain the above copyright notice,
this list of conditions and the following disclaimer.
- Redistributions in binary form must reproduce the above copyright notice,
this list of conditions and the following disclaimer in the documentation and/or
other materials provided with the distribution.
- Neither the name of ZIH, TU Dresden nor the names of its contributors
may be used to endorse or promote products derived from this software without
specific prior written permission.
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR
ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
(INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
ACLOCAL_AMFLAGS = -I config/m4
if AMHAVESWIGPYTHON
OTFLIB_PY = otflib_py
else
OTFLIB_PY =
endif
SUBDIRS = \
otflib \
$(OTFLIB_PY) \
tools \
docu
EXTRA_DIST= \
otf_vc08.sln \
config/otf_get_version.sh \
tests/hello/Makefile \
tests/hello/hello_otf.c \
tests/otf_python/groups.py \
tests/otf_python/test_read.py \
tests/otf_python/test_read_qt.py \
tests/otf_python/test_write.py \
tests/otf_python/python3/groups.py \
tests/otf_python/python3/test_read.py \
tests/otf_python/python3/test_read_qt.py \
tests/otf_python/python3/test_write.py \
tests/otf_read_from_buffer/hello_world.0.def--missing \
tests/otf_read_from_buffer/hello_world.0.marker \
tests/otf_read_from_buffer/hello_world.1.events \
tests/otf_read_from_buffer/hello_world.2.events \
tests/otf_read_from_buffer/hello_world.otf \
tests/otf_read_from_buffer/Makefile \
tests/otf_read_from_buffer/otf_read_from_buffer.c \
VERSION
This diff is collapsed.
Open Trace Format (OTF)
Detailed program analysis of massively parallel programs requires the recording of event based performance data during run-time and its visualisation with appropriate software tools like the Vampir framework.
The specification of a convenient and powerful trace file format has to fulfill a large number of requirements. It must allow an efficient collection of the event based performance data on a parallel program environment. On the other hand it has to provide a very fast and convenient access to the large amount of performance data and the corresponding event definitions by the analysis software tools.
To improve scalability for very large and massively parallel traces the Open Trace Format (OTF) has been developed at ZIH as a successor format to the Vampir Trace Format (VTF3).
The Open Trace Format makes use of a portable ASCII encoding. It distributes single traces to multiple so called streams with one or more files each. Merging of records from multiple files is done transparently by the OTF library. The number of possible streams is not limited by the number of available file handles.
The provided read/write library should be used as a convenient interface for third party software. The library supports efficient parallel and distributed access to trace data and offers selective reading access regarding arbitrary time intervals, process selection and record types.
Optional auxiliary information can assist this selective access.
The software package contains additional tools for trace date conversion or preparation.
More information can be found in the provided documentation.
OTF version is available as open source software under the BSD license, see 'COPYING'. The software comes as a source code package. It can be installed by using autoconf procedures, see 'INSTALL'.
- re-design OTF's error/success return values for handlers and functions
- ideas for future development
- add memory allocation/deallocation record types, how?
- have more semantics
- have less semantics
- add general purpose record types like (type/owner,key,value) with no semantics,
-- can be used freely, ignored if unknown,
-- key/value are either uint64_t, array of uint64_t or text
- add record to write wall clock time or epoch or year:month:day:hour:minute:second
with this, VT can record time at start and end of trace (request by Robert Henschel)
- create a (graphical) tool for changing definition records:
- grouping functions
- ...
- solve the problem that when only reading statistic records one cannot
determine the begin and end of a process !!!!!
You might introduce a new record for this. ( maybe like begin/endprocess
for events? )
You could also write a statistics comment record when the first event appears,
(in otfaux)
- add new statistics record type that gives the caller-callee relation
- only write this at the end of a trace run
- use asynchronous write (aio_write) and maybe even read for performance
# This is the VERSION file for OTF, describing the precise version of OTF in
# this distribution. The various components of the version number below are
# combined to form a single version number string.
# major, minor, and sub are generally combined in the form
# <major>.<minor>.<sub>. If sub is zero, then it is omitted.
major=1
minor=8
sub=1
# string is used for alpha, beta, or release tags. If it is non-empty, it will
# be appended to the version number.
#
# history of release tags:
# 0.2.* octopussy
# 0.3.*-1.1.* starfish
# 1.2.* pufferfish
# 1.3.* jellyfish
# 1.4.* shark
# 1.5.* dolphin
# 1.6.* stingray
# 1.7.* catfish
# 1.8.* sturgeon
#
string=sturgeon
# library is used for the library versioning. These three numbers will be added
# to the name of the library (e.g. libotf.so.1.2.3).
# The meaning of these numbers is as follows (from left to right):
#
# current The number of the current API exported by the library.
# That must be incremented, if the API has changed.
# revision The implementation number of the most recent API
# exported by the library. A value of '0' means that this
# is the first implementation of the API.
# If any of the source for the library has changed,
# revision must be incremented.
# age The number of previous additional APIs supported by the
# library. If age is '2', the library can be linked into
# executables built with a release of the library that
# exported the current API number (current), or any of
# the preceding two APIs.
# If the new API is backward-compatible with the preceding
# release, age must be incremented. Otherwise, reset age
# to '0'.
library=2:1:1
m4_include(config/m4/acinclude.debug.m4)
m4_include(config/m4/acinclude.math.m4)
m4_include(config/m4/acinclude.mpi.m4)
m4_include(config/m4/acinclude.omp.m4)
m4_include(config/m4/acinclude.swig_python.m4)
m4_include(config/m4/acinclude.vtf3.m4)
m4_include(config/m4/acinclude.verbose.m4)
m4_include(config/m4/acinclude.zlib.m4)
m4_include(config/m4/acarchive/ax_mpi.m4)
m4_include(config/m4/acarchive/ax_openmp.m4)
This diff is collapsed.
/* config.h.in. Generated from configure.in by autoheader. */
/* Define to 1 if you have the `asprintf' function. */
#undef HAVE_ASPRINTF
/* Define to 1 if you have the declaration of `O_NOATIME', and to 0 if you
don't. */
#undef HAVE_DECL_O_NOATIME
/* Define to 1 if you have the <dlfcn.h> header file. */
#undef HAVE_DLFCN_H
/* Define to 1 if you have the <fcntl.h> header file. */
#undef HAVE_FCNTL_H
/* Define to 1 if fseeko (and presumably ftello) exists and is declared. */
#undef HAVE_FSEEKO
/* Define to 1 if you have the `gettimeofday' function. */
#undef HAVE_GETTIMEOFDAY
/* Define to 1 if you have the <inttypes.h> header file. */
#undef HAVE_INTTYPES_H
/* Define to 1 if you have the <memory.h> header file. */
#undef HAVE_MEMORY_H
/* Define to 1 if you have the `snprintf' function. */
#undef HAVE_SNPRINTF
/* Define to 1 if you have the <stddef.h> header file. */
#undef HAVE_STDDEF_H
/* Define to 1 if you have the <stdint.h> header file. */
#undef HAVE_STDINT_H
/* Define to 1 if you have the <stdlib.h> header file. */
#undef HAVE_STDLIB_H
/* Define to 1 if you have the `strdup' function. */
#undef HAVE_STRDUP
/* Define to 1 if you have the <strings.h> header file. */
#undef HAVE_STRINGS_H
/* Define to 1 if you have the <string.h> header file. */
#undef HAVE_STRING_H
/* Define to 1 if you have the <sys/param.h> header file. */
#undef HAVE_SYS_PARAM_H
/* Define to 1 if you have the <sys/select.h> header file. */
#undef HAVE_SYS_SELECT_H
/* Define to 1 if you have the <sys/stat.h> header file. */
#undef HAVE_SYS_STAT_H
/* Define to 1 if you have the <sys/time.h> header file. */
#undef HAVE_SYS_TIME_H
/* Define to 1 if you have the <sys/types.h> header file. */
#undef HAVE_SYS_TYPES_H
/* Define to 1 if you have the `__va_copy' function. */
#undef HAVE_UNDERSCORE_VA_COPY
/* Define to 1 if you have the <unistd.h> header file. */
#undef HAVE_UNISTD_H
/* Define to 1 if you have the `vasprintf' function. */
#undef HAVE_VASPRINTF
/* Define to 1 if you have the `va_copy' function. */
#undef HAVE_VA_COPY
/* Define to 1 if you have the `vsnprintf' function. */
#undef HAVE_VSNPRINTF
/* */
#undef HAVE_VTF3
/* */
#undef HAVE_ZLIB
/* Define to the sub-directory in which libtool stores uninstalled libraries.
*/
#undef LT_OBJDIR
/* */
#undef OTF_DEBUG
/* */
#undef OTF_VERBOSE
/* Name of package */
#undef PACKAGE
/* Define to the address where bug reports for this package should be sent. */
#undef PACKAGE_BUGREPORT
/* Define to the full name of this package. */
#undef PACKAGE_NAME
/* Define to the full name and version of this package. */
#undef PACKAGE_STRING
/* Define to the one symbol short name of this package. */
#undef PACKAGE_TARNAME
/* Define to the home page for this package. */
#undef PACKAGE_URL
/* Define to the version of this package. */
#undef PACKAGE_VERSION
/* The size of `long', as computed by sizeof. */
#undef SIZEOF_LONG
/* Define to 1 if you have the ANSI C header files. */
#undef STDC_HEADERS
/* Version number of package */
#undef VERSION
/* Define to 1 to make fseeko visible on some hosts (e.g. glibc 2.2). */
#undef _LARGEFILE_SOURCE
/* Define to `unsigned int' if <sys/types.h> does not define. */
#undef size_t
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
# ===========================================================================
# http://www.nongnu.org/autoconf-archive/ax_mpi.html
# ===========================================================================
#
# SYNOPSIS
#
# AX_MPI([ACTION-IF-FOUND[, ACTION-IF-NOT-FOUND]])
#
# DESCRIPTION
#
# This macro tries to find out how to compile programs that use MPI
# (Message Passing Interface), a standard API for parallel process
# communication (see http://www-unix.mcs.anl.gov/mpi/)
#
# On success, it sets the MPICC, MPICXX, MPIF77, or MPIFC output variable
# to the name of the MPI compiler, depending upon the current language.
# (This may just be $CC/$CXX/$F77/$FC, but is more often something like
# mpicc/mpiCC/mpif77/mpif90.) It also sets MPILIBS to any libraries that
# are needed for linking MPI (e.g. -lmpi or -lfmpi, if a special
# MPICC/MPICXX/MPIF77/MPIFC was not found).
#
# If you want to compile everything with MPI, you should set:
#
# CC="MPICC" #OR# CXX="MPICXX" #OR# F77="MPIF77" #OR# FC="MPIFC"
# LIBS="$MPILIBS $LIBS"
#
# NOTE: The above assumes that you will use $CC (or whatever) for linking
# as well as for compiling. (This is the default for automake and most
# Makefiles.)
#
# The user can force a particular library/compiler by setting the
# MPICC/MPICXX/MPIF77/MPIFC and/or MPILIBS environment variables.
#
# ACTION-IF-FOUND is a list of shell commands to run if an MPI library is
# found, and ACTION-IF-NOT-FOUND is a list of commands to run if it is not
# found. If ACTION-IF-FOUND is not specified, the default action will
# define HAVE_MPI.
#
# LICENSE
#
# Copyright (c) 2008 Steven G. Johnson <stevenj@alum.mit.edu>
# Copyright (c) 2008 Julian C. Cummings <cummings@cacr.caltech.edu>
#
# This program is free software: you can redistribute it and/or modify it
# under the terms of the GNU General Public License as published by the
# Free Software Foundation, either version 3 of the License, or (at your
# option) any later version.
#
# This program is distributed in the hope that it will be useful, but
# WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General
# Public License for more details.
#
# You should have received a copy of the GNU General Public License along
# with this program. If not, see <http://www.gnu.org/licenses/>.
#
# As a special exception, the respective Autoconf Macro's copyright owner
# gives unlimited permission to copy, distribute and modify the configure
# scripts that are the output of Autoconf when processing the Macro. You
# need not follow the terms of the GNU General Public License when using
# or distributing such scripts, even though portions of the text of the
# Macro appear in them. The GNU General Public License (GPL) does govern
# all other use of the material that constitutes the Autoconf Macro.
#
# This special exception to the GPL applies to versions of the Autoconf
# Macro released by the Autoconf Archive. When you make and distribute a
# modified version of the Autoconf Macro, you may extend this special
# exception to the GPL to apply to your modified version as well.
#serial 4
AU_ALIAS([ACX_MPI], [AX_MPI])
AC_DEFUN([AX_MPI], [
AC_PREREQ(2.50) dnl for AC_LANG_CASE
AC_LANG_CASE([C], [
AC_REQUIRE([AC_PROG_CC])
AC_ARG_VAR(MPICC,[MPI C compiler command])
AC_CHECK_PROGS(MPICC, mpicc hcc mpxlc_r mpxlc mpcc cmpicc, $CC)
ax_mpi_save_CC="$CC"
CC="$MPICC"
AC_SUBST(MPICC)
],
[C++], [
AC_REQUIRE([AC_PROG_CXX])
AC_ARG_VAR(MPICXX,[MPI C++ compiler command])
AC_CHECK_PROGS(MPICXX, mpic++ mpicxx mpiCC hcp mpxlC_r mpxlC mpCC cmpic++, $CXX)
ax_mpi_save_CXX="$CXX"
CXX="$MPICXX"
AC_SUBST(MPICXX)
],
[Fortran 77], [
AC_REQUIRE([AC_PROG_F77])
AC_ARG_VAR(MPIF77,[MPI Fortran 77 compiler command])
AC_CHECK_PROGS(MPIF77, mpif77 hf77 mpxlf_r mpxlf mpf77 cmpifc, $F77)
ax_mpi_save_F77="$F77"
F77="$MPIF77"
AC_SUBST(MPIF77)
],
[Fortran], [
AC_REQUIRE([AC_PROG_FC])
AC_ARG_VAR(MPIFC,[MPI Fortran compiler command])
AC_CHECK_PROGS(MPIFC, mpif90 mpxlf95_r mpxlf90_r mpxlf95 mpxlf90 mpf90 cmpif90c, $FC)
ax_mpi_save_FC="$FC"
FC="$MPIFC"
AC_SUBST(MPIFC)
])
if test x = x"$MPILIBS"; then
AC_LANG_CASE([C], [AC_CHECK_FUNC(MPI_Init, [MPILIBS=" "])],
[C++], [AC_CHECK_FUNC(MPI_Init, [MPILIBS=" "])],
[Fortran 77], [AC_MSG_CHECKING([for MPI_Init])
AC_LINK_IFELSE([AC_LANG_PROGRAM([],[ call MPI_Init])],[MPILIBS=" "
AC_MSG_RESULT(yes)], [AC_MSG_RESULT(no)])],
[Fortran], [AC_MSG_CHECKING([for MPI_Init])
AC_LINK_IFELSE([AC_LANG_PROGRAM([],[ call MPI_Init])],[MPILIBS=" "
AC_MSG_RESULT(yes)], [AC_MSG_RESULT(no)])])
fi
AC_LANG_CASE([Fortran 77], [
if test x = x"$MPILIBS"; then
AC_CHECK_LIB(fmpi, MPI_Init, [MPILIBS="-lfmpi"])
fi
if test x = x"$MPILIBS"; then
AC_CHECK_LIB(fmpich, MPI_Init, [MPILIBS="-lfmpich"])
fi
],
[Fortran], [
if test x = x"$MPILIBS"; then
AC_CHECK_LIB(fmpi, MPI_Init, [MPILIBS="-lfmpi"])
fi
if test x = x"$MPILIBS"; then
AC_CHECK_LIB(mpichf90, MPI_Init, [MPILIBS="-lmpichf90"])
fi
])
if test x = x"$MPILIBS"; then
AC_CHECK_LIB(mpi, MPI_Init, [MPILIBS="-lmpi"])
fi
if test x = x"$MPILIBS"; then
AC_CHECK_LIB(mpich, MPI_Init, [MPILIBS="-lmpich"])
fi
dnl We have to use AC_TRY_COMPILE and not AC_CHECK_HEADER because the
dnl latter uses $CPP, not $CC (which may be mpicc).
AC_LANG_CASE([C], [if test x != x"$MPILIBS"; then
AC_MSG_CHECKING([for mpi.h])
AC_TRY_COMPILE([#include <mpi.h>],[],[AC_MSG_RESULT(yes)], [MPILIBS=""
AC_MSG_RESULT(no)])
fi],
[C++], [if test x != x"$MPILIBS"; then
AC_MSG_CHECKING([for mpi.h])
AC_TRY_COMPILE([#include <mpi.h>],[],[AC_MSG_RESULT(yes)], [MPILIBS=""
AC_MSG_RESULT(no)])
fi],
[Fortran 77], [if test x != x"$MPILIBS"; then
AC_MSG_CHECKING([for mpif.h])
AC_COMPILE_IFELSE([AC_LANG_PROGRAM([],[ include 'mpif.h'])],[AC_MSG_RESULT(yes)], [MPILIBS=""
AC_MSG_RESULT(no)])
fi],
[Fortran], [if test x != x"$MPILIBS"; then
AC_MSG_CHECKING([for mpif.h])
AC_COMPILE_IFELSE([AC_LANG_PROGRAM([],[ include 'mpif.h'])],[AC_MSG_RESULT(yes)], [MPILIBS=""
AC_MSG_RESULT(no)])
fi])
AC_LANG_CASE([C], [CC="$ax_mpi_save_CC"],
[C++], [CXX="$ax_mpi_save_CXX"],
[Fortran 77], [F77="$ax_mpi_save_F77"],
[Fortran], [FC="$ax_mpi_save_FC"])
AC_SUBST(MPILIBS)
# Finally, execute ACTION-IF-FOUND/ACTION-IF-NOT-FOUND:
if test x = x"$MPILIBS"; then
$2
:
else
ifelse([$1],,[AC_DEFINE(HAVE_MPI,1,[Define if you have the MPI library.])],[$1])
:
fi
])dnl AX_MPI
dnl @synopsis AX_OPENMP([ACTION-IF-FOUND[, ACTION-IF-NOT-FOUND]])
dnl
dnl @summary determine how to compile programs using OpenMP
dnl
dnl This macro tries to find out how to compile programs that use
dnl OpenMP a standard API and set of compiler directives for parallel
dnl programming (see http://www-unix.mcs/)
dnl
dnl On success, it sets the
dnl OPENMP_CFLAGS/OPENMP_CXXFLAGS/OPENMP_F77FLAGS output variable to
dnl the flag (e.g. -omp) used both to compile *and* link OpenMP
dnl programs in the current language.
dnl
dnl NOTE: You are assumed to not only compile your program with these
dnl flags, but also link it with them as well.
dnl
dnl If you want to compile everything with OpenMP, you should set:
dnl
dnl CFLAGS="$CFLAGS $OPENMP_CFLAGS"
dnl #OR# CXXFLAGS="$CXXFLAGS $OPENMP_CXXFLAGS"
dnl #OR# FFLAGS="$FFLAGS $OPENMP_FFLAGS"
dnl
dnl (depending on the selected language).
dnl
dnl The user can override the default choice by setting the
dnl corresponding environment variable (e.g. OPENMP_CFLAGS).
dnl
dnl ACTION-IF-FOUND is a list of shell commands to run if an OpenMP
dnl flag is found, and ACTION-IF-NOT-FOUND is a list of commands to run
dnl it if it is not found. If ACTION-IF-FOUND is not specified, the
dnl default action will define HAVE_OPENMP.
dnl
dnl @category InstalledPackages
dnl @author Steven G. Johnson <stevenj@alum.mit.edu>
dnl @version 2006-01-24
dnl @license GPLWithACException
AC_DEFUN([AX_OPENMP], [
AC_PREREQ(2.59) dnl for _AC_LANG_PREFIX
AC_CACHE_CHECK([for OpenMP flag of _AC_LANG compiler], ax_cv_[]_AC_LANG_ABBREV[]_openmp, [save[]_AC_LANG_PREFIX[]FLAGS=$[]_AC_LANG_PREFIX[]FLAGS
ax_cv_[]_AC_LANG_ABBREV[]_openmp=unknown
# Flags to try: -fopenmp (gcc), -openmp (icc), -mp (SGI & PGI),
# -xopenmp (Sun), -omp (Tru64), -qsmp=omp (AIX),
# -Popenmp (NECSX), none
ax_openmp_flags="-fopenmp -openmp -mp -xopenmp -omp -qsmp=omp -Popenmp none"
if test "x$OPENMP_[]_AC_LANG_PREFIX[]FLAGS" != x; then
ax_openmp_flags="$OPENMP_[]_AC_LANG_PREFIX[]FLAGS $ax_openmp_flags"
fi
for ax_openmp_flag in $ax_openmp_flags; do
case $ax_openmp_flag in
none) []_AC_LANG_PREFIX[]FLAGS=$save[]_AC_LANG_PREFIX[] ;;
*) []_AC_LANG_PREFIX[]FLAGS="$save[]_AC_LANG_PREFIX[]FLAGS $ax_openmp_flag" ;;
esac
AC_TRY_COMPILE([], [
#ifndef _OPENMP
# error "_OPENMP not defined"
#endif
], [ax_cv_[]_AC_LANG_ABBREV[]_openmp=$ax_openmp_flag; break])
done
[]_AC_LANG_PREFIX[]FLAGS=$save[]_AC_LANG_PREFIX[]FLAGS
])
if test "x$ax_cv_[]_AC_LANG_ABBREV[]_openmp" = "xunknown"; then
m4_default([$2],:)
else
if test "x$ax_cv_[]_AC_LANG_ABBREV[]_openmp" != "xnone"; then
OPENMP_[]_AC_LANG_PREFIX[]FLAGS=$ax_cv_[]_AC_LANG_ABBREV[]_openmp
fi
m4_default([$1],:)
fi
])dnl AX_OPENMP
dnl switch on/off additonal debug output in otf lib
AC_DEFUN([WITH_DEBUG],
[
AH_TEMPLATE(OTF_DEBUG, [], [switch on/off additonal debug checks in otf lib])
AC_ARG_WITH([debug],
AC_HELP_STRING([--with-debug],[additonal debug checks]),
[debug=$withval],
[debug=""])
if test "$debug" = yes; then
AC_DEFINE(OTF_DEBUG)
fi
])
AC_DEFUN([CHECK_MATH],
[
LIBS="$LIBS -lm"
AC_MSG_CHECKING([whether linking with -lm works])
AC_TRY_LINK([],[],
[AC_MSG_RESULT([yes]); math_lib=-lm],[AC_MSG_RESULT([no])])
LIBS=$sav_LIBS
AS_IF([test x"$math_lib" != x],
[
AC_MSG_CHECKING([whether we need to link -lm to get math functions])
AC_TRY_LINK([#include <math.h>],
[
volatile double c, x = 47.11;
c = ceil(x);
],
[AC_MSG_RESULT([no])], [AC_MSG_RESULT([yes]); MATHLIB=$math_lib])
])
AC_SUBST(MATHLIB)
])
AC_DEFUN([CHECK_MPI],
[
mpi_error="no"
check_mpi="yes"
force_mpi="no"
have_mpi="no"
AC_ARG_WITH([mpi],
AC_HELP_STRING([--with-mpi],
[use MPI for some OTF tools, default: yes if found by configure]),
[if test "$withval" = "yes"; then force_mpi="yes"; else check_mpi="no"; fi])
AC_ARG_WITH([mpi-dir],
AC_HELP_STRING([--with-mpi-dir],
[give the path for MPI, default: /usr]),
[mpi_dir="$withval/"])