cutlass icon indicating copy to clipboard operation
cutlass copied to clipboard

[FEA] Passing the copy type as a parameter to `copy`

Open ZelboK opened this issue 7 months ago • 4 comments

Kind of a small change. So I was looking at https://github.com/NVIDIA/cutlass/issues/1231

and I was wondering if it made sense to refactor the code so that it will accept the type of copy they want to rely on like so copy(gmem_tiled_copy, SM80_CP_ASYNC_CACHEALWAYS<float>{}, tAgA, tAsA) so that way you can have the user be aware of what's going on internally. Right now if you use DefaultCopy for example it'll dispatch to that instruction which requires the code to have more synchronization which is a little unintuitive.

You might be able to get the copy type inferred from gmem_tiled_copy but passing it as an explicit parameter is probably much easier.

I'm wondering if there's any flaws/problems with doing this? Perhaps the default should always be copy(gmem_tiled_copy, DefaultCopy{}, tAgA, tAsA).

I could work on a PR for implementing this if it's beneficial. Would like to know ahead of time if this is even desired or if there are problems with this approach before I commit my time to a PR though.

ZelboK avatar Aug 01 '24 14:08 ZelboK