Can the GPU use the data placed in your file system?Assuming the GPU can access any part of VRAM, yes. Files created in vramfs will always have content that exists somewhere in video ram. A file you create never moves, and is always contiguous in memory. All your program needs to direct the GPU to it is the block offset from the start of VRAM, which can be obtained by an ioctl() or bmap().
Do you have strong control as to exactly how the data is mapped into VRAM?Not exactly. When you create a file you get whatever free space is available. However, vramfs does guarantee that your file is never fragmented, never sparse, and will always exist for the life of the file from it's offset in video ram to the offset plus the file size. I believe I've written the code to be flexible enough however to allow stronger control if needed.
I'm thinking about parallel processing - Linux puts data there and thenOr multimedia uses too. I'd like to see this used by MPlayer or Xine someday for example to make use of the MPEG-2 or H.264 hardware GPU decoding that today's graphics cards support: Just feed in the H.264 in one file and direct the GPU to spit out decoded video to another file, which MPlayer would have memory-mapped and could directly do something with it, -vf filters and all.
the GPU works on it to produce a result which Linux can eventually
fetch.
- Mark