Tommaso Sofi
Tommaso Sofi

Reputation: 1

How to change matrices dimensions MatrixMul CUDA sample

Hi I tried changing matrices dimensions in matrixmul by passing paramenters on launch. Unfortunately it accept only some values, like 160*160, 320*320, 320*1280 640*640 but not lower values like 80*80 or others like 56*56. Can you tell me why and what to do? Thank you!

Upvotes: 0

Views: 95

Answers (1)

kangshiyin
kangshiyin

Reputation: 9779

The sample only demonstrates how the mat multiplication could be done in CUDA. It is not a good choice to use that code to do real mat mul. Instead you could use BLAS functions provided by the cuBlas library, which support arbitrary dimensions.

On the other hand, if you want know more about how the mat mul code works, you could attach some code in your Q.

Upvotes: 1

Related Questions