Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Semantically different code when noinline is applied to functions #287

Open
victor-eds opened this issue Mar 23, 2023 · 4 comments
Open
Assignees

Comments

@victor-eds
Copy link

victor-eds commented Mar 23, 2023

When running this intel/llvm-test-suite test passing -O0 on OpenCL/L0 GPU platforms (driver versions tested: 22.28.23726.1 and 22.53.25242.13 on Ubuntu Linux 22.10), we found that the test was failing due to wrong computation being performed. After debugging, we think this might be in fact an IGC bug (or missing metadata you might be expecting to perform further transformations on the module).

This test is passing with the same options on OpenCL CPU and, when modifying the output module generated by DPC++'s sycl-fusion JIT compiler replacing noinline attributes with alwaysinline, it is also passing on GPU platforms. You can find the IGC dump for both runs attached (original.zip, alwaysinline.zip).

When debugging, we saw the codegen dump in original.zip had some calls to the following builtin, which we assume should've been handled by one of IGC's passes and replaced by additional arguments in calling functions:

declare <8 x i32> @llvm.genx.GenISA.getPayloadHeader.v8i32() #9
@victor-eds victor-eds changed the title Semantically different code when noinline is applied Semantically different code when noinline is applied to functions Mar 23, 2023
@amielcza
Copy link
Contributor

Hello,

I am currently trying to reproduce your problem, however I ran into some problems in the process. I cannot seem to recreate the error on my machine - on both drivers (22.28.23726.1 and 22.53.25242.13). Could you please provide some additional information regarding reproduction of the error you seem to be having:

 - The version of DPC++

 - The platform you are using

 - Full IGC dumps (IGC_ShaderDumpEnable=1)

@amielcza
Copy link
Contributor

Hello, could you please provide the information I asked for in the message above? @victor-eds

@pszymich
Copy link
Contributor

pszymich commented Jun 6, 2023

Closing as inactive.

@victor-eds
Copy link
Author

Sorry, I missed the first message and was off on holidays for the past couple of weeks.
DPC++ version: clang version 17.0.0 ([email protected]:intel/llvm.git 1404ff1dec552053b49cdf8d6fdab72f42f8beb6)
Platform: Ubuntu 20.04.6 LTS (GNU/Linux 5.15.0-71-generic x86_64)
complete_fusio_768621.tar.gz

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants