MeVisLab Toolbox Reference
mlModuleProfiling.h File Reference
#include <mlTypeDefs.h>
#include <mlProfilingManager.h>

Go to the source code of this file.

Classes

class  ml::internal::ProfilingScope
 Helper class that stops measuring when it gets out of scope. More...

Namespaces

namespace  ml
 Defines the class GetTileJob.
namespace  ml::internal

Macros

#define ML_PROFILING_SCOPE(ProfilingIdentifier)

Macro Definition Documentation

◆ ML_PROFILING_SCOPE

#define ML_PROFILING_SCOPE ( ProfilingIdentifier)
Value:
internal::ProfilingScope internal_scope; \
MLMetaProfile* internal_metaProfile = NULL; \
internal_metaProfile = getMetaProfile().get(); \
if (internal_metaProfile) { \
internal_scope.startMeasuring(internal_metaProfile, ProfilingIdentifier, MLMetaProfile::MLCall, this); \
} \
}
MLTimeProfileHandle startMeasuring(const std::string &function, int userId, void *userData=nullptr, const std::string &filename="", int linenumber=-1, const std::string &nodeInfo="")
static bool isProfilingEnabled()
Returns whether profiling is enabled.

Starts profiling using the ML Profiling Manager. This can only be used in classes that implement getMetaProfile(), e.g., ml::Module.

Definition at line 48 of file mlModuleProfiling.h.