Above is the code I’m working on. From the left:
- .NET code using DllImport to invoke the C++ function. Tried different calling conventions already.
- C++ function called.
- A big part of the computeNormalsAndFilter function.
During the lifetime of an app, I would like to call the C++ function multiple times. The second time I do it, I get error 1 from computeAndFilter kernel (invalid attributes). The code works just fine if I don’t run cudaFree(); but my gut feeling says it should be there.