flgrx driver eats a large amount of memory when the same texture is mapped many times
I have a problem with the fglrx driver. When doing simple things like showing a single texture, the driver takes somewhere between 300MB and 900MB. I think the memory is allocated from the kernel module, because the process shows small amount of memory used, but the free memory of the system decreases. I can see in /proc/meminfo that the "HighFree:" field decreases when I run a sample program. The decrease is relatively slow, at around 10MB/sec.
I am attaching the sample program so that it is seen exactly what I am doing. The program requires a parameter that tells it how many lines from the image to transfer at once. I noticed, that when the texture is loaded in smaller chunks (800kB or so) the problem dissapears. Only when I load the texture with chunks of 1MB or more the problem is seen.
In other words if the program is run with parameter 200 - no problem. If the parameter is 300 or more the problem appears.
Can someone see if I am doing something wrong or is this a bug in the driver? Is there a workaround in this situation?
AMD Athlon Neo dual core 1.5GHz
Video card: ATI RADEON E4690
Memory: 3GB of RAM
Debian Squeeze with linux 2.6.32 (32bit)
Ati catalyst driver 11.8
X.Org X Server 1.7.7