emacs-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Question: estimating size of a buffer when written to file?


From: Qiantan Hong
Subject: Question: estimating size of a buffer when written to file?
Date: Wed, 8 Dec 2021 15:33:06 +0000

Is there any reliable way to get (or conservatively estimate) 
the size of a buffer when written to file?

I’m thinking about using it for an optimization for persistent kv store.
If we know a log entry, when written out, is shorter than PIPE_BUF,
then we can skip the file locking/unlocking.
Emacs lock file doesn’t seem to be particularly fast.

Best,
Qiantan


reply via email to

[Prev in Thread] Current Thread [Next in Thread]