Use VRAM as RAM -- might be going crazy
Hi! I was wondering if I could use VRAM as RAM (not the other way around, yeah), here's some context:
I'm running this system with some scrap parts I had around, those being an i7-8700K, 4+2 GB DDR4, an extremely unreliable, but functional 256GB SSD I bought off AliExpress for $7 and a Quadro P5000.
Since energy for me is pratically free (solar in Japan, completely self-sustainable), I thought about using this as a little shits and giggles rig for mining, and it ran well. But XMRig's not-so-nice-but-extremely-profitable huge pages feature + GPU mining has left me torturing the SSD in exchange for swap.
Since the GPU mining only takes up around 6 GB of VRAM, I was wondering if I could use the rest of that as actual system RAM instead, does anybody here have any clue about how I could accomplish this?
Comments
Hey, I just found this github repository when I searched for "VRAM Disk" on Google: https://github.com/prsyahmi/GpuRamDrive
Also there seems to be someone who installed Crysis 3 on the VRAM of his RTX 3090 using this tool: https://x.com/Strife212/status/1312553602934865923 (Reddit post where I found this tweet: https://www.reddit.com/r/pcgaming/comments/j54qh4/gamer_installs_crysis_3_on_geforce_rtx_3090s_vram/).
I am however not sure if this would work for your usecase.
Good find. He can simply put his swap partition on his VRAM disk. Not exactly turning VRAM into actual RAM but similar.
The KingSpec were known for being a decent Chinese brand if you managed to get original ones off Aliexpress. But SSDs on Aliexpress are likely counterfeit, report fake capacity, or may be an array of cheap SD cards on a SATA adapter. I was defrauded last week on AliScamfest.
Thank you, it worked really well, although as @lowendspiritxdax mentioned that it wouldn't be considered as actual RAM, I just shoved a swap file there and it worked just as good.
datalix's aff #1 fan
Nowadays Chinese phone manufacturers are all claiming they have 8+8GB RAM xD
Basically the same thing with 8GB swap but calling their phones "16GB" haha
Anyways, SWAP on VRAM is significantly faster than SWAP on SSD and it also doesn't degrade over time.
(Cheap SSDs probably gonna die in a few weeks if you use your swap all the time)
In the same vein, it is not VRAM as RAM but VRAM as small storage.
It is quite fast and can be used as swap.
https://wiki.archlinux.org/title/Swap_on_video_RAM
I already tried the method with phram and MTD on an old Athlon64 desktop used as a server which had a integrated nvidia GPU (yes it existed in 2006).
As the computer was not used with a GUI anyway and because the integrated GPU reserved to much RAM (as VRAM) for my taste, I used that technique to have fast swap.
Cheers,
Oh I've fallen for one of those, almighty "Memory Extension" on Redmi 9T.
Shiver me timbers, would be my first experience with arch but this sounds considerably better than what I'm doing right now, I'll give it a shot and keep you guys updated. Thanks for the suggestions so far
datalix's aff #1 fan