Talk:TIP Use memory on video card as swap
From Gentoo Linux Wiki
20070704: changed mention of hal creating stuff in /dev to udev, as it worked for me with just udev
20070930: I liked the idea of using video RAM as swap - I have a tired old headless server with 128MB of video RAM doing nothing, so I followed your (well-written) instructions. Perhaps it's a confused thing to do, but I used hdparm -t to check the performance of the swap devices. The current swap device is on an IDE disk attached to a SiS5513 controller, for which hdparm -t reports around 57MB/sec. For mtdblock0 (a SiS661 on-board), the figure is around 17MB/sec, more than 3 times slower. hdparm -T (cached test) reports nearly 400MB/sec for both. Will the MTD swap be slower than the disk-based swap? Thanks for an interesting diversion! Sean (sean4u at gmail).
20071011: I'm just curious if this would work for a set of crossfire cards? Could you address 2 x 512mb as one 1020mb swap? If it possible, would the directions be any different 69.229.233.149 18:12, 11 October 2007 (UTC)
20071022: I have found that for some reason phram and slram fail to work on my system (nothing is even printed to dmesg), i'll have to do some modification to its configuration to find if anything is conflicting.
20071207: This tip rules. Now, could someone explain how to exploit the massive processing power of the GPU as well to offload some kinds of jobs from the CPU? Some are speculating that the video card can be a sort of blade server to run server images sucked down from the web using a virtualization technology like Xen. If you're already using the RAM and the GPU the only reason to do this would be firewalling (having a separate processor handle stuff sucked down from the web). More tips please on how to do this kind of insane but useful stuff.
Answer: Exploiting the power of the GPU is much more difficult as programming them is not standardized or well documented. There are also some limitations with using the GPU for processing. For one, most GPUs are restricted to single precision floating point. There is a group that is utilizing the GPU to do computations http://gpgpu.org/ .
20071218: I have found that the speed reported by hdparm -t is not accurate. To get some idea of the speed you need to do a "time dd if=/dev/zero of=/mnt/some_place/somefile bs=1024 count=65536" and a "time cp /mnt/some_place/somefile /dev/null" then calculate it.
