Skip to content

Parallel tc to ttgt #100

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 3 commits into from
Apr 10, 2025
Merged

Parallel tc to ttgt #100

merged 3 commits into from
Apr 10, 2025

Conversation

pthomadakis
Copy link
Collaborator

This PR introduces a parallel implementation of TC-to-TTGT pass and parallel implementation for OptDenseTransposePass

As an example, the performance of the following intensli.ta kernel:

def main() {
	#IndexLabel Declarations
	IndexLabel [a, b, d] = [1024];
	IndexLabel [c] = [512];

	#Tensor Declarations
	Tensor<double> v([d, c, a], {Dense});
	Tensor<double> t2([b, d], {Dense});
	Tensor<double> i0([a, b, c], {Dense});

	#Tensor Fill Operation
	v[d, c, a] = 2.3;
	t2[b, d] = 3.4;
	i0[a, b, c] = 0.0;


        var time0 = getTime();
	i0[a, b, c] = v[d, c, a] * t2[b, d];
        var time1 = getTime();
	printElapsedTime(time0, time1);
        var out = SUM(i0[a,b,c]);
        print(out);
}

Improves ~6x on my 8-core CPU (~24s to ~4s).
However, we still need to investigate why we are behind numpy and why cometpy is way behind

@pthomadakis pthomadakis merged commit f922015 into dev-new Apr 10, 2025
2 of 3 checks passed
@pthomadakis pthomadakis deleted the parallel-tc-to-ttgt branch April 16, 2025 17:49
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.

1 participant