Skip to content

Can not generate omp parallel code for sparse tensors #561

Description

@MaxwellF1

I'm using the taco C++ API (built with OpenMP ON) to compute the contraction between two sparse tensors using this code:

Format csf({Sparse, Sparse, Sparse, Sparse});
Tensor<double> X = read("x.tns", csf);
Tensor<double> Y = read("y.tns", csf);
Tensor<double> Z({X.getDimension(0),X.getDimension(1),Y.getDimension(0),Y.getDimension(1)}, csf);

IndexVar i, j, k, l, m, n;
Z(i,j,m,n) = X(i,j,k,l) * Y(m,n,k,l); 

Z.compile();
Z.printComputeIR(std::cout);
Z.assemble();
Z.compute();

And I found the printed code is not omp parallel in the loop. However, I test the spmv computation and it is generated with omp parallel.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions