File tree Expand file tree Collapse file tree 1 file changed +6
-0
lines changed 
sycl/unittests/Extensions Expand file tree Collapse file tree 1 file changed +6
-0
lines changed Original file line number Diff line number Diff line change 66// 
77// ===----------------------------------------------------------------------===//
88
9+ #include  < detail/queue_impl.hpp> 
910#include  < gtest/gtest.h> 
1011#include  < helpers/ScopedEnvVar.hpp> 
1112#include  < helpers/UrMock.hpp> 
@@ -39,6 +40,11 @@ class ExtOneapiBarrierOptTest : public ::testing::Test {
3940TEST_F (ExtOneapiBarrierOptTest, EmptyEventTest) {
4041  sycl::queue q1{{sycl::property::queue::in_order ()}};
4142
43+   //  To avoid current optimizations for empty queues, we trick q1 into thinking
44+   //  that it isn't empty.
45+   int  dummyInt;
46+   q1.prefetch (&dummyInt, sizeof (int ));
47+ 
4248  mock::getCallbacks ().set_after_callback (
4349      " urEnqueueEventsWaitWithBarrierExt" 
4450      &redefinedEnqueueEventsWaitWithBarrierExt);
 
 
   
 
     
   
   
          
    
    
     
    
      
     
     
    You can’t perform that action at this time.
  
 
    
  
    
      
        
     
       
      
     
   
 
    
    
  
 
  
 
     
    
0 commit comments