evilsocket / cake

Distributed LLM and StableDiffusion inference for mobile, desktop and server.
Other
2.64k stars 141 forks source link

Building on ubuntu errors `cuMemAdvise_v2` on cuda 12.1 #3

Closed b0xtch closed 4 months ago

b0xtch commented 4 months ago
Compiling tracing-core v0.1.32
error[E0599]: no method named `cuMemAdvise_v2` found for reference `&'static driver::sys::sys_12010::Lib` in the current scope
   --> /home/ubuntu/.cargo/registry/src/index.crates.io-6f17d22bba15001f/cudarc-0.11.7/src/driver/result.rs:613:10
    |
612 | /     lib()
613 | |         .cuMemAdvise_v2(dptr, num_bytes, advice, location)
    | |_________-^^^^^^^^^^^^^^
    |
help: there is a method `cuMemAdvise` with a similar name
    |
613 |         .cuMemAdvise(dptr, num_bytes, advice, location)
    |          ~~~~~~~~~~~

error[E0599]: no method named `cuMemPrefetchAsync_v2` found for reference `&'static driver::sys::sys_12010::Lib` in the current scope
     --> /home/ubuntu/.cargo/registry/src/index.crates.io-6f17d22bba15001f/cudarc-0.11.7/src/driver/result.rs:628:10
      |
627   | /     lib()
628   | |         .cuMemPrefetchAsync_v2(dptr, num_bytes, location, 0, stream)
      | |_________-^^^^^^^^^^^^^^^^^^^^^
      |
help: there is a method `cuMemPrefetchAsync` with a similar name, but with different arguments
     --> /home/ubuntu/.cargo/registry/src/index.crates.io-6f17d22bba15001f/cudarc-0.11.7/src/driver/sys/sys_12010.rs:13548:5
      |
13548 | /     pub unsafe fn cuMemPrefetchAsync(
13549 | |         &self,
13550 | |         devPtr: CUdeviceptr,
13551 | |         count: usize,
13552 | |         dstDevice: CUdevice,
13553 | |         hStream: CUstream,
13554 | |     ) -> CUresult {
      | |_________________^
image
b0xtch commented 4 months ago

Perhaps ill upgrade cuda first

evilsocket commented 4 months ago

I know it compiles on 12.4, no idea about previous versions :D

evilsocket commented 4 months ago

yep it looks like that API is part of unified addressing that's been introduced with CUDA 12.2, so that is the minimum required version