File tree Expand file tree Collapse file tree 2 files changed +2
-2
lines changed Expand file tree Collapse file tree 2 files changed +2
-2
lines changed Original file line number Diff line number Diff line change @@ -32,6 +32,7 @@ struct ur_queue_handle_t_ {
32
32
// Stream used solely when profiling is enabled
33
33
native_type ProfStream;
34
34
bool IsProfStreamCreated{false };
35
+ std::once_flag ProfStreamFlag;
35
36
// delay_compute_ keeps track of which streams have been recently reused and
36
37
// their next use should be delayed. If a stream has been recently reused it
37
38
// will be skipped the next time it would be selected round-robin style. When
@@ -107,7 +108,6 @@ struct ur_queue_handle_t_ {
107
108
// Function which creates the profiling stream. Called only if profiling is
108
109
// enabled.
109
110
void createProfilingStream () {
110
- static std::once_flag ProfStreamFlag;
111
111
std::call_once (ProfStreamFlag, [&]() {
112
112
UR_CHECK_ERROR (
113
113
cuStreamCreateWithPriority (&ProfStream, CU_STREAM_NON_BLOCKING, 0 ));
Original file line number Diff line number Diff line change @@ -28,6 +28,7 @@ struct ur_queue_handle_t_ {
28
28
// Stream used solely when profiling is enabled
29
29
native_type ProfStream;
30
30
bool IsProfStreamCreated{false };
31
+ std::once_flag ProfStreamFlag;
31
32
// DelayCompute keeps track of which streams have been recently reused and
32
33
// their next use should be delayed. If a stream has been recently reused it
33
34
// will be skipped the next time it would be selected round-robin style. When
@@ -104,7 +105,6 @@ struct ur_queue_handle_t_ {
104
105
// Function which creates the profiling stream. Called only if profiling is
105
106
// enabled.
106
107
void createProfilingStream () {
107
- static std::once_flag ProfStreamFlag;
108
108
std::call_once (ProfStreamFlag, [&]() {
109
109
UR_CHECK_ERROR (
110
110
hipStreamCreateWithFlags (&ProfStream, hipStreamNonBlocking));
You can’t perform that action at this time.
0 commit comments