Skip to content

[SYCL][Fusion] Do not internalize stored argument pointers #8376

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

Merged
merged 2 commits into from
Feb 22, 2023

Conversation

victor-eds
Copy link
Contributor

When a pointer to be promoted is stored, internalization is no longer safe to perform. In this case, simply bail out and do not promote the given pointer.

When a pointer to be promoted is stored, internalization is no longer
safe to perform, as it would require further analysis to ensure the
pass is indeed legal. Instead, simply bail out and do not change the
given argument.

Signed-off-by: Victor Perez <[email protected]>
@victor-eds
Copy link
Contributor Author

/verify with intel/llvm-test-suite#1600

@victor-eds victor-eds temporarily deployed to aws February 16, 2023 15:00 — with GitHub Actions Inactive
Copy link
Contributor

@sommerlukas sommerlukas left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM.

@victor-eds victor-eds temporarily deployed to aws February 16, 2023 20:20 — with GitHub Actions Inactive
@victor-eds victor-eds temporarily deployed to aws February 17, 2023 01:02 — with GitHub Actions Inactive
@bader bader temporarily deployed to aws February 18, 2023 19:52 — with GitHub Actions Inactive
@bader bader temporarily deployed to aws February 18, 2023 20:24 — with GitHub Actions Inactive
@bader bader merged commit 570dc5e into intel:sycl Feb 22, 2023
@steffenlarsen
Copy link
Contributor

@victor-eds - abort-promote-stored-ptr.ll is failing in post-commit. Could you please have a look?

******************** TEST 'SYCL-FUSION :: internalization/abort-promote-stored-ptr.ll' FAILED ********************
Script:
--
: 'RUN: at line 1';   .../llvm/build/./lib/SYCLKernelFusion.so -passes=sycl-internalization --sycl-info-path .../llvm/src/sycl-fusion/test/internalization/abort-kernel-info.yaml -S .../llvm/src/sycl-fusion/test/internalization/abort-promote-stored-ptr.ll -debug 2>&1 | .../llvm/build/bin/FileCheck .../llvm/src/sycl-fusion/test/internalization/abort-promote-stored-ptr.ll
--
Exit Code: 1

Command Output (stderr):
--
.../llvm/src/sycl-fusion/test/internalization/abort-promote-stored-ptr.ll:10:16: error: CHECK-LABEL: expected string not found in input
; CHECK-LABEL: define {{[^@]+}}@fused_0
               ^
<stdin>:1:1: note: scanning from here
opt: Unknown command line argument '-debug'. Try: '.../llvm/build/bin/opt --help'
^
<stdin>:1:19: note: possible intended match here
opt: Unknown command line argument '-debug'. Try: '.../llvm/build/bin/opt --help'
                  ^

Input file: <stdin>
Check file: .../llvm/src/sycl-fusion/test/internalization/abort-promote-stored-ptr.ll

-dump-input=help explains the following input dump.

Input was:
<<<<<<
            1: opt: Unknown command line argument '-debug'. Try: '.../llvm/build/bin/opt --help' 
label:10'0     X~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ error: no match found
label:10'1                       ?                                                                      possible intended match
            2: opt: Did you mean '--debugify'? 
label:10'0     ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
>>>>>>

--

@victor-eds
Copy link
Contributor Author

@victor-eds - abort-promote-stored-ptr.ll is failing in post-commit. Could you please have a look?

******************** TEST 'SYCL-FUSION :: internalization/abort-promote-stored-ptr.ll' FAILED ********************
Script:
--
: 'RUN: at line 1';   .../llvm/build/./lib/SYCLKernelFusion.so -passes=sycl-internalization --sycl-info-path .../llvm/src/sycl-fusion/test/internalization/abort-kernel-info.yaml -S .../llvm/src/sycl-fusion/test/internalization/abort-promote-stored-ptr.ll -debug 2>&1 | .../llvm/build/bin/FileCheck .../llvm/src/sycl-fusion/test/internalization/abort-promote-stored-ptr.ll
--
Exit Code: 1

Command Output (stderr):
--
.../llvm/src/sycl-fusion/test/internalization/abort-promote-stored-ptr.ll:10:16: error: CHECK-LABEL: expected string not found in input
; CHECK-LABEL: define {{[^@]+}}@fused_0
               ^
<stdin>:1:1: note: scanning from here
opt: Unknown command line argument '-debug'. Try: '.../llvm/build/bin/opt --help'
^
<stdin>:1:19: note: possible intended match here
opt: Unknown command line argument '-debug'. Try: '.../llvm/build/bin/opt --help'
                  ^

Input file: <stdin>
Check file: .../llvm/src/sycl-fusion/test/internalization/abort-promote-stored-ptr.ll

-dump-input=help explains the following input dump.

Input was:
<<<<<<
            1: opt: Unknown command line argument '-debug'. Try: '.../llvm/build/bin/opt --help' 
label:10'0     X~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ error: no match found
label:10'1                       ?                                                                      possible intended match
            2: opt: Did you mean '--debugify'? 
label:10'0     ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
>>>>>>

--

Fixed by this PR

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

Successfully merging this pull request may close these issues.

4 participants