Re:70B Llama 2 at 35tokens/second on 4090
by rwmj on Wednesday September 13, 2023 @06:00AM
(#37494627)
If you need to use all the memory then swapping breaks down, best you can do is try to divide the work so half can be done, then you completely swap all the memory and do the other half. Also PCIe is (relatively) slow for moving gigabytes of data back and forth.
Re:70B Llama 2 at 35tokens/second on 4090
by rahimnathwani on Wednesday September 13, 2023 @10:16AM
(#37497077)
Swapping would be too slow.
Llama.cpp allows you to specify that n layers load into the GPU's VRAM, and the rest load into main memory.
Re:70B Llama 2 at 35tokens/second on 4090
by brucethemoose2 on Wednesday September 13, 2023 @12:10PM
(#37498612)
Some frameworks have tried to do this automatically, but its extremely slow. You are better off just running whatever won't fit on the CPU (which is what llama.cpp does).
Obviously that would be useless for games, but for LLMs it may be an option?