Skip to content

cmalloc function missing #7

Description

@LourensVeen

When compiling with OpenCL, I get

./include/ocldev.h: In member function ‘void dev::memory<T>::copy(const dev::memory<T>&, cl_bool)’:
./include/ocldev.h:578:9: error: there are no arguments to ‘cmalloc’ that depend on a template parameter, so a declaration of ‘cmalloc’ must be available [-fpermissive]
  578 |         cmalloc(src.n, DeviceMemFlags);
      |         ^~~~~~~
./include/ocldev.h:578:9: note: (if you use ‘-fpermissive’, G++ will accept your code, but allowing the use of an undeclared name is deprecated)

There seems to be a cmalloc in bonsai's my_ocl.h, but it's not quite compatible. Anyway this code looks a bit odd to me, maybe it should be calling allocate(src.n, DeviceMemFlags);? That compiles, but I haven't tested it yet, I need to go find a machine that can actually run OpenCL 😄.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions