# compiletime_settings.h

Go to the documentation of this file.

    00001 // -*- C++ -*-
    00002
    00003 // Copyright (C) 2007 Free Software Foundation, Inc.
    00004 //
    00005 // This file is part of the GNU ISO C++ Library.  This library is free
    00006 // software; you can redistribute it and/or modify it under the terms
    00007 // of the GNU General Public License as published by the Free Software
    00008 // Foundation; either version 2, or (at your option) any later
    00009 // version.
    00010
    00011 // This library is distributed in the hope that it will be useful, but
    00012 // WITHOUT ANY WARRANTY; without even the implied warranty of
    00013 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
    00014 // General Public License for more details.
    00015
    00016 // You should have received a copy of the GNU General Public License
    00017 // along with this library; see the file COPYING.  If not, write to
    00018 // the Free Software Foundation, 59 Temple Place - Suite 330, Boston,
    00019 // MA 02111-1307, USA.
    00020
    00021 // As a special exception, you may use this file as part of a free
    00022 // software library without restriction.  Specifically, if other files
    00023 // instantiate templates or use macros or inline functions from this
    00024 // file, or you compile this file and link it with other files to
    00025 // produce an executable, this file does not by itself cause the
    00026 // resulting executable to be covered by the GNU General Public
    00027 // License.  This exception does not however invalidate any other
    00028 // reasons why the executable file might be covered by the GNU General
    00029 // Public License.
    00030
    00031 /** @file parallel/compiletime_settings.h
    00032  *  @brief Defines on options concerning debugging and performance, at
    00033  *  compile-time.
    00034  *  This file is a GNU parallel extension to the Standard C++ Library.
    00035  */
    00036
    00037 // Written by Johannes Singler.
    00038
    00039 #include <cstdio>
    00040
    00041 /** @brief Determine verbosity level of the parallel mode.
    00042  *  Level 1 prints a message each time a parallel-mode function is entered. */
    00043 #define _GLIBCXX_VERBOSE_LEVEL 0
    00044
    00045 /** @def _GLIBCXX_CALL
    00046  *  @brief Macro to produce log message when entering a function.
    00047  *  @param n Input size.
    00048  *  @see _GLIBCXX_VERBOSE_LEVEL */
    00049 #if (_GLIBCXX_VERBOSE_LEVEL == 0)
    00050 #define _GLIBCXX_CALL(n)
    00051 #endif
    00052 #if (_GLIBCXX_VERBOSE_LEVEL == 1)
    00053 #define _GLIBCXX_CALL(n) \
    00054   printf("   %s:\niam = %d, n = %ld, num_threads = %d\n", \
    00055   __PRETTY_FUNCTION__, omp_get_thread_num(), (n), get_max_threads());
    00056 #endif
    00057
    00058 #ifndef _GLIBCXX_SCALE_DOWN_FPU
    00059 /** @brief Use floating-point scaling instead of modulo for mapping
    00060  *  random numbers to a range.  This can be faster on certain CPUs. */
    00061 #define _GLIBCXX_SCALE_DOWN_FPU 0
    00062 #endif
    00063
    00064 #ifndef _GLIBCXX_ASSERTIONS
    00065 /** @brief Switch on many _GLIBCXX_PARALLEL_ASSERTions in parallel code.
    00066  *  Should be switched on only locally. */
    00067 #define _GLIBCXX_ASSERTIONS 0
    00068 #endif
    00069
    00070 #ifndef _GLIBCXX_RANDOM_SHUFFLE_CONSIDER_L1
    00071 /** @brief Switch on many _GLIBCXX_PARALLEL_ASSERTions in parallel code.
    00072  *  Consider the size of the L1 cache for
    00073  *  __gnu_parallel::parallel_random_shuffle(). */
    00074 #define _GLIBCXX_RANDOM_SHUFFLE_CONSIDER_L1 0
    00075 #endif
    00076 #ifndef _GLIBCXX_RANDOM_SHUFFLE_CONSIDER_TLB
    00077 /** @brief Switch on many _GLIBCXX_PARALLEL_ASSERTions in parallel code.
    00078  *  Consider the size of the TLB for
    00079  *  __gnu_parallel::parallel_random_shuffle(). */
    00080 #define _GLIBCXX_RANDOM_SHUFFLE_CONSIDER_TLB 0
    00081 #endif
    00082
    00083 #ifndef _GLIBCXX_MULTIWAY_MERGESORT_COPY_LAST
    00084 /** @brief First copy the data, sort it locally, and merge it back
    00085  * (0); or copy it back after everything is done (1).
    00086  *
    00087  *  Recommendation: 0 */
    00088 #define _GLIBCXX_MULTIWAY_MERGESORT_COPY_LAST 0
    00089 #endif