File tree Expand file tree Collapse file tree 1 file changed +4
-4
lines changed
source/adapters/level_zero Expand file tree Collapse file tree 1 file changed +4
-4
lines changed Original file line number Diff line number Diff line change @@ -433,8 +433,8 @@ ur_result_t ur_platform_handle_t_::populateDeviceCacheIfNeeded() {
433433// Returns plugin specific backend option.
434434// Current support is only for optimization options.
435435// Return '-ze-opt-disable' for frontend_option = -O0.
436- // Return '-ze-opt-level=1' for frontend_option = -O1 or -O2 .
437- // Return '-ze-opt-level=2' for frontend_option = -O3.
436+ // Return '-ze-opt-level=1' for frontend_option = -O1.
437+ // Return '-ze-opt-level=2' for frontend_option = -O2 or - O3.
438438// Return '-igc_opts 'PartitionUnit=1,SubroutineThreshold=50000'' for
439439// frontend_option=-ftarget-compile-fast.
440440UR_APIEXPORT ur_result_t UR_APICALL urPlatformGetBackendOption (
@@ -457,11 +457,11 @@ UR_APIEXPORT ur_result_t UR_APICALL urPlatformGetBackendOption(
457457 *PlatformOption = " -ze-opt-disable" ;
458458 return UR_RESULT_SUCCESS;
459459 }
460- if (FrontendOption == " -O1" sv || FrontendOption == " -O2 " sv ) {
460+ if (FrontendOption == " -O1" sv) {
461461 *PlatformOption = " -ze-opt-level=1" ;
462462 return UR_RESULT_SUCCESS;
463463 }
464- if (FrontendOption == " -O3" sv) {
464+ if (FrontendOption == " -O2 " sv || FrontendOption == " - O3" sv) {
465465 *PlatformOption = " -ze-opt-level=2" ;
466466 return UR_RESULT_SUCCESS;
467467 }
You can’t perform that action at this time.
0 commit comments