CVR-Lib last update 20 Sep 2009

cvrPerformanceConfig.h

Go to the documentation of this file.
00001 /*
00002  * Copyright (C) 1998-2004
00003  * Lehrstuhl fuer Technische Informatik, RWTH-Aachen, Germany
00004  *
00005  *
00006  * This file is part of the Computer Vision and Robotics Library (CVR-Lib)
00007  *
00008  * The CVR-Lib is free software; you can redistribute it and/or
00009  * modify it under the terms of the BSD License.
00010  *
00011  * All rights reserved.
00012  *
00013  * Redistribution and use in source and binary forms, with or without
00014  * modification, are permitted provided that the following conditions are met:
00015  *
00016  * 1. Redistributions of source code must retain the above copyright notice,
00017  *    this list of conditions and the following disclaimer.
00018  *
00019  * 2. Redistributions in binary form must reproduce the above copyright notice,
00020  *    this list of conditions and the following disclaimer in the documentation
00021  *    and/or other materials provided with the distribution.
00022  *
00023  * 3. Neither the name of the authors nor the names of its contributors may be
00024  *    used to endorse or promote products derived from this software without
00025  *    specific prior written permission.
00026  *
00027  * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
00028  * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
00029  * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
00030  * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE
00031  * LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
00032  * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
00033  * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
00034  * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
00035  * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
00036  * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
00037  * POSSIBILITY OF SUCH DAMAGE.
00038  */
00039 
00040 
00041 /**
00042  * \file   cvrPerformanceConfig.h
00043  *         Definition of constants that are used to tweak the performance of
00044  *         some algorithm but need not be changed for every call of a
00045  *         method. Usually, these constants are architecture dependent,
00046  *         mostly cache. The default values in this file were determined on
00047  *         a P4 1600 with 512 RAM.
00048  * \author Peter Doerfler
00049  * \date   09.02.2004
00050  *
00051  * $Id: cvrPerformanceConfig.h,v 1.4 2004/11/19 16:27:50 gquiros Exp $
00052  */
00053 
00054 #ifndef _CVR_PERFORMANCE_CONFIG_H_
00055 #define _CVR_PERFORMANCE_CONFIG_H_
00056 
00057 /**
00058  * Multiplication of two matrices in cvr::matrix is faster if the
00059  * second matrix is transposed first when that matrix is large. Large
00060  * is defined below.
00061  */
00062 #define _CVR_PERFORMANCE_MATRIX_MATRIX_MULTIPLY 65
00063 
00064 /**
00065  * The QR decomposition algorithm (cvr::qrDecomposition) accesses the
00066  * data matrix column wise. Depending on the size it is faster to
00067  * transpose first and transpose the results again.
00068  */
00069 #define _CVR_PERFORMANCE_QR_DECOMPOSITION 50
00070 
00071 /**
00072  * cvr::sort uses quicksort down to a certain number of elements to
00073  * sort after which it uses a simple sorting algorithm. The value
00074  * below sets that threshold.
00075  */
00076 #define _CVR_PERFORMANCE_SORT_STOP_QUICKSORT 10
00077 
00078 /**
00079  * The segment size of the heap in a smallObjectList. Indicates the
00080  * amount of nodes that will be allocated at once when there is no
00081  * more available memory.
00082  */
00083 #define _CVR_PERFORMANCE_SMALLOBJECTLIST_HEAP_SEGMENT_SIZE 100
00084 
00085 /**
00086  * Object size threshold value for cvr::list (in bytes).
00087  * The list will be implemented as a smallObjectList for types
00088  * whose size is less than or equal to this value, and as a
00089  * std::list for all other types.
00090  */
00091 #define _CVR_PERFORMANCE_LIST_OBJECT_SIZE_THRESHOLD 16
00092 
00093 #endif

Generated on Sun Sep 20 22:08:00 2009 for CVR-Lib by Doxygen 1.5.8