File tree Expand file tree Collapse file tree 1 file changed +24
-0
lines changed
unified-runtime/source/loader/layers/sanitizer/tsan Expand file tree Collapse file tree 1 file changed +24
-0
lines changed Original file line number Diff line number Diff line change @@ -535,6 +535,25 @@ __urdlllocal ur_result_t UR_APICALL urGetEnqueueExpProcAddrTable(
535
535
return UR_RESULT_SUCCESS;
536
536
}
537
537
538
+ // /////////////////////////////////////////////////////////////////////////////
539
+ // / @brief Exported function for filling application's EnqueueExp table
540
+ // / with current process' addresses
541
+ // /
542
+ // / @returns
543
+ // / - ::UR_RESULT_SUCCESS
544
+ // / - ::UR_RESULT_ERROR_INVALID_NULL_POINTER
545
+ __urdlllocal ur_result_t UR_APICALL urGetEnqueueExpProcAddrTable (
546
+ // / [in,out] pointer to table of DDI function pointers
547
+ ur_enqueue_exp_dditable_t *pDdiTable) {
548
+ if (nullptr == pDdiTable) {
549
+ return UR_RESULT_ERROR_INVALID_NULL_POINTER;
550
+ }
551
+
552
+ pDdiTable->pfnCooperativeKernelLaunchExp =
553
+ ur_sanitizer_layer::tsan::urEnqueueCooperativeKernelLaunchExp;
554
+ return UR_RESULT_SUCCESS;
555
+ }
556
+
538
557
} // namespace tsan
539
558
540
559
ur_result_t initTsanDDITable (ur_dditable_t *dditable) {
@@ -576,6 +595,11 @@ ur_result_t initTsanDDITable(ur_dditable_t *dditable) {
576
595
&dditable->EnqueueExp );
577
596
}
578
597
598
+ if (UR_RESULT_SUCCESS == result) {
599
+ result = ur_sanitizer_layer::tsan::urGetEnqueueExpProcAddrTable (
600
+ &dditable->EnqueueExp );
601
+ }
602
+
579
603
if (result != UR_RESULT_SUCCESS) {
580
604
getContext ()->logger .error (" Initialize TSAN DDI table failed: {}" , result);
581
605
}
You can’t perform that action at this time.
0 commit comments