Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in / Register
Toggle navigation
O
opencv
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Packages
Packages
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
submodule
opencv
Commits
d8ab8360
Commit
d8ab8360
authored
5 years ago
by
Alexander Alekhin
Browse files
Options
Browse Files
Download
Plain Diff
Merge pull request #15761 from alalek:core_trace_itt_parameter
parents
7cf1054d
6ec5ae02
No related merge requests found
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
18 additions
and
5 deletions
+18
-5
trace.cpp
modules/core/src/trace.cpp
+18
-5
No files found.
modules/core/src/trace.cpp
View file @
d8ab8360
...
...
@@ -196,14 +196,27 @@ static __itt_domain* domain = NULL;
static
bool
isITTEnabled
()
{
static
bool
isInitialized
=
false
;
static
volatile
bool
isInitialized
=
false
;
static
bool
isEnabled
=
false
;
if
(
!
isInitialized
)
{
isEnabled
=
!!
(
__itt_api_version
());
CV_LOG_ITT
(
"ITT is "
<<
(
isEnabled
?
"enabled"
:
"disabled"
));
domain
=
__itt_domain_create
(
"OpenCVTrace"
);
isInitialized
=
true
;
cv
::
AutoLock
lock
(
cv
::
getInitializationMutex
());
if
(
!
isInitialized
)
{
bool
param_traceITTEnable
=
utils
::
getConfigurationParameterBool
(
"OPENCV_TRACE_ITT_ENABLE"
,
true
);
if
(
param_traceITTEnable
)
{
isEnabled
=
!!
(
__itt_api_version
());
CV_LOG_ITT
(
"ITT is "
<<
(
isEnabled
?
"enabled"
:
"disabled"
));
domain
=
__itt_domain_create
(
"OpenCVTrace"
);
}
else
{
CV_LOG_ITT
(
"ITT is disabled through OpenCV parameter"
);
isEnabled
=
false
;
}
isInitialized
=
true
;
}
}
return
isEnabled
;
}
...
...
This diff is collapsed.
Click to expand it.
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment