rtprofile.h

来自「此文件包含了在linux下实现tpr-tree索引的源代码」· C头文件 代码 · 共 66 行

H
66
字号
//--------------------------------------------------------------------//      RTprofile.h//      -----------//      Profiling capabilities////      Macros defined: //      PROFILE_ACTION_BEGIN (act_var) - start counting time//      PROFILE_ACTION_END   (act_var) - end counting time//      PROFILE_OUTPUT                 - outputs profile to standart output////      TPR-tree - Index for continuously moving objects//      July 2001 release, Aalborg University//#ifndef RTPROFILE_H#define RTPROFILE_H#ifdef PROFILING#include <time.h>// TProfileActionVarstruct TProfileActionVar{   TProfileActionVar() : total(0), level(0) {}   double  total;     // total time elapsed on this activity   clock_t start;     // starting time of activity   short   level;     // number of BEGIN calls, not closed by END calls};// Action variables, each accumulating time spent on some type of activityextern TProfileActionVar profile_total;extern TProfileActionVar profile_search;extern TProfileActionVar profile_delete;extern TProfileActionVar profile_insert;extern TProfileActionVar profile_removetop;extern TProfileActionVar profile_split;extern TProfileActionVar profile_packnode;extern TProfileActionVar profile_unpacknode;extern TProfileActionVar profile_choosesubtree;extern TProfileActionVar profile_overlaparea;#define PROFILE_ACTION_BEGIN(act_var)  profile_action_begin(act_var)#define PROFILE_ACTION_END(act_var)    profile_action_end(act_var)#define PROFILE_OUTPUT                 profile_output()void profile_action_begin (TProfileActionVar& var);void profile_action_end   (TProfileActionVar& var);void profile_output();#else#define PROFILE_ACTION_BEGIN(act_var)  #define PROFILE_ACTION_END(act_var)    #define PROFILE_OUTPUT                 #endif   // PROFILING#endif   // RTPROFILE_H

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?