Open amccaskey opened 1 year ago
I think we may need to mandate that callable parameters to a kernel must be fully typed.
The bridge needs some work in this area, for sure. The AST can appear to be using pass by reference even though the called function is expecting a pass by value. The bridge isn't consistent about handling it; sometimes it just gets confused and fails, but in some cases it does more work and injects a cc.load
, etc.
This can be fixed with an update the sample.h to remove the extra std::forward at line 209.
But this leads to another bug with the argument being valid input to a cuda quantum kernel (
error: kernel argument type not supported
). The argument type is!cc.ptr<!cc.ptr<(!quake.ref) -> ()>>
.