All of lore.kernel.org
 help / color / mirror / Atom feed
* [lm-sensors]  Memory usage of sysfs files
@ 2006-03-08 22:36 Hartmut Rick
  2006-03-09 19:41 ` Jean Delvare
                   ` (9 more replies)
  0 siblings, 10 replies; 11+ messages in thread
From: Hartmut Rick @ 2006-03-08 22:36 UTC (permalink / raw)
  To: lm-sensors



Hi everybody,

On Wed, 8 Mar 2006, Jean Delvare wrote:

> The only data I am missing now is the memory used by each additional
> sysfs file we create. We need to know, as Hans objected that too many
> sysfs files could have a negative impact on memory consumption. I dug

I've just created a couple sysfs files in order to find out, and the 
conclusion is that each additional sysfs file reduces the remaining free 
memory by something on the order of 90-95 bytes.
It turns out that the memory reported by 'free' varies quite a bit between 
calls, which disturbs somewhat the precision of this measurement. I had to 
create 10000 sysfs files in order to get a statistically significant 
result. Now this result is correct on the 10% level, which I think is good 
enough for our discussion.
For this experiment, I used the same callback function for all sysfs 
files, so each additional file has just one SENSOR_DEVICE_ATTR struct 
definition and a device_create_file() call, but no extra supporting code.
This is the typical situation for the individual alarm files, I guess.

With current DRAM prices, 100 extra bytes correspond to extra costs of 
around 1e-5 EUR or USD for each additional file, which I think is 
tolerable.

Best regards,
  Hartmut


^ permalink raw reply	[flat|nested] 11+ messages in thread

end of thread, other threads:[~2006-03-10 15:28 UTC | newest]

Thread overview: 11+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2006-03-08 22:36 [lm-sensors] Memory usage of sysfs files Hartmut Rick
2006-03-09 19:41 ` Jean Delvare
2006-03-09 20:05 ` Hans de Goede
2006-03-09 20:06 ` Hans de Goede
2006-03-09 21:05 ` Jean Delvare
2006-03-09 21:41 ` Hans de Goede
2006-03-09 23:16 ` Hans de Goede
2006-03-10 11:11 ` Hans de Goede
2006-03-10 13:46 ` Jean Delvare
2006-03-10 14:09 ` Jean Delvare
2006-03-10 15:28 ` Jim Cromie

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.