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

Add an option for insert gpu allocs to treat allocations as gpu-native #354

Merged
merged 1 commit into from
Sep 24, 2024

Conversation

zhczhong
Copy link
Member

Track #344

@@ -76,7 +76,10 @@ void populateGPUPipeline(mlir::OpPassManager &pm) {
pm.addNestedPass<func::FuncOp>(createGpuMapParallelLoopsPass());
pm.addNestedPass<func::FuncOp>(createParallelLoopToGpuPass());

pm.addNestedPass<func::FuncOp>(imex::createInsertGPUAllocsPass("opencl"));
imex::InsertGPUAllocsOptions insertGPUAllocsOption{
/*clientAPI*/ "opencl", /*inRegions*/ false, /*isUsmArgs*/ true};
Copy link
Contributor

Choose a reason for hiding this comment

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

can we make isUsmArgs a parameter of the pipeline?

Copy link
Member Author

Choose a reason for hiding this comment

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

Yes! An option is added to the pipeline

@zhczhong zhczhong force-pushed the zhicong/remove_cpy_in_args branch from 3906c28 to 9041a84 Compare September 24, 2024 07:00
@kurapov-peter kurapov-peter merged commit 71041d5 into main Sep 24, 2024
6 checks passed
@kurapov-peter kurapov-peter deleted the zhicong/remove_cpy_in_args branch September 24, 2024 09:45
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants