sort out gpu and nongpu functions for consistent registration