Skip to content

Commit 398628e

Browse files
authored
Add Passing in the Result to Validation Checkers at Epilogue (#235)
* Add Passing in the Result to Validation Checkers at Epilogue * Always return the Driver Result in validation layer * Update Copyright Signed-off-by: Neil R. Spruit <[email protected]>
1 parent ea296eb commit 398628e

File tree

8 files changed

+1691
-1691
lines changed

8 files changed

+1691
-1691
lines changed

scripts/templates/validation/entry_points.h.mako

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ from templates import helper as th
1111
* ***THIS FILE IS GENERATED. ***
1212
* See entry_points.h.mako for modifications
1313
*
14-
* Copyright (C) 2019-2023 Intel Corporation
14+
* Copyright (C) 2019-2024 Intel Corporation
1515
*
1616
* SPDX-License-Identifier: MIT
1717
*
@@ -36,7 +36,7 @@ ${line} \
3636
%for line in th.make_param_lines(n, tags, obj, format=["type", "name", "delim"]):
3737
${line} \
3838
%endfor
39-
) {return ZE_RESULT_SUCCESS;}
39+
, ze_result_t result) {return ZE_RESULT_SUCCESS;}
4040
%endfor
4141
virtual ~${N}ValidationEntryPoints() {}
4242
};

scripts/templates/validation/valddi.cpp.mako

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ from templates import helper as th
1111
* ***THIS FILE IS GENERATED. ***
1212
* See valddi.cpp.mako for modifications
1313
*
14-
* Copyright (C) 2019-2023 Intel Corporation
14+
* Copyright (C) 2019-2024 Intel Corporation
1515
*
1616
* SPDX-License-Identifier: MIT
1717
*
@@ -68,20 +68,20 @@ ${line} \
6868
if(result!=${X}_RESULT_SUCCESS) return result;
6969
}
7070

71-
auto result = ${th.make_pfn_name(n, tags, obj)}( ${", ".join(th.make_param_lines(n, tags, obj, format=["name"]))} );
71+
auto driver_result = ${th.make_pfn_name(n, tags, obj)}( ${", ".join(th.make_param_lines(n, tags, obj, format=["name"]))} );
7272

7373
for (size_t i = 0; i < numValHandlers; i++) {
7474
auto result = context.validationHandlers[i]->${n}Validation->${th.make_func_name(n, tags, obj)}Epilogue( \
7575
% for line in th.make_param_lines(n, tags, obj, format=['name','delim']):
7676
${line} \
7777
%endfor
78-
);
78+
,driver_result);
7979
if(result!=${X}_RESULT_SUCCESS) return result;
8080
}
8181

8282
%if generate_post_call:
8383

84-
if( result == ${X}_RESULT_SUCCESS && context.enableHandleLifetime ){
84+
if( driver_result == ${X}_RESULT_SUCCESS && context.enableHandleLifetime ){
8585
## Add 'Created' handles/objects to dependent maps
8686
<% lines = th.make_param_lines(n, tags, obj, format=['name','delim'])
8787
%>
@@ -111,7 +111,7 @@ ${line} \
111111
%endfor
112112
}
113113
%endif
114-
return result;
114+
return driver_result;
115115
}
116116
%if 'condition' in obj:
117117
#endif // ${th.subt(n, tags, obj['condition'])}

source/layers/validation/common/ze_entry_points.h

Lines changed: 189 additions & 189 deletions
Large diffs are not rendered by default.

source/layers/validation/common/zes_entry_points.h

Lines changed: 149 additions & 149 deletions
Large diffs are not rendered by default.

source/layers/validation/common/zet_entry_points.h

Lines changed: 67 additions & 67 deletions
Large diffs are not rendered by default.

0 commit comments

Comments
 (0)