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

[IR][Pass] Refactor the fusion implementation #164

Merged
merged 11 commits into from Apr 7, 2023

Conversation

yaoyaoding
Copy link
Member

@yaoyaoding yaoyaoding commented Apr 7, 2023

This PR refactor the implementation of post-scheduling fusion.

Previously, we use a TaskGraph to store the sub-graph inside each Task.

After this refactor, we remove the TaskGraph attribute of Task, but created a new kind of operator to represent the fused sub-graph. This allows us to support more kinds of fusion, and make the IR more clean.

Some other udpates:

  1. Each lib.so will contains a single operator. We fix the name of packed function to 'launch' (previously, the name of packed function is the name of the task). This will avoid passing the function name and make the code more clean.
  2. Now, the implement_cpu and implement_cuda methods of class Task can return a list of IRModule, indicating the tunable schedules.
  3. Move the generation of 'launch' function to pass list. Now, we do not need to call the add_packed_func to manually add it.

@yaoyaoding yaoyaoding merged commit 3cc75b6 into hidet-org:main Apr 7, 2023
2 checks passed
@yaoyaoding yaoyaoding deleted the refactor-fusion branch April 7, 2023 18:22
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.

None yet

1 participant