File tree Expand file tree Collapse file tree 1 file changed +4
-4
lines changed
amd/comgr/test-lit/comgr-sources Expand file tree Collapse file tree 1 file changed +4
-4
lines changed Original file line number Diff line number Diff line change @@ -27,11 +27,11 @@ int main(int argc, char *argv[]) {
2727 SizeSource = setBuf (argv [1 ], & BufSource );
2828
2929 amd_comgr_language_t OpenCLVersion ;
30- if (strcmp (argv [3 ], "1.2" )) {
30+ if (strcmp (argv [3 ], "1.2" ) == 0 ) {
3131 OpenCLVersion = AMD_COMGR_LANGUAGE_OPENCL_1_2 ;
3232 }
33- else if (strcmp (argv [3 ], "2.0" )) {
34- OpenCLVersion = AMD_COMGR_LANGUAGE_OPENCL_1_2 ;
33+ else if (strcmp (argv [3 ], "2.0" ) == 0 ) {
34+ OpenCLVersion = AMD_COMGR_LANGUAGE_OPENCL_2_0 ;
3535 }
3636 else
3737 fail ("unsupported OCL version: %s" , argv [3 ]);
@@ -44,7 +44,7 @@ int main(int argc, char *argv[]) {
4444
4545 amd_comgr_ (create_action_info (& DataAction ));
4646 amd_comgr_ (
47- action_info_set_language (DataAction , AMD_COMGR_LANGUAGE_OPENCL_1_2 ));
47+ action_info_set_language (DataAction , OpenCLVersion ));
4848 amd_comgr_ (action_info_set_isa_name (DataAction , "amdgcn-amd-amdhsa--gfx900" ));
4949 amd_comgr_ (action_info_set_option_list (DataAction , CodeGenOptions ,
5050 CodeGenOptionsCount ));
You can’t perform that action at this time.
0 commit comments