Using secure memory
opalraava at hushmail.com
Mon Apr 20 14:39:20 CEST 2015
Oh well, there is a GCRYCTL_DUMP_MEMORY_STATS that does nothing but
there is also a GCRYCTL_DUMP_SECMEM_STATS that does print usage statistics.
On 04/20/2015 01:45 PM, Opal Raava wrote:
> Hi folks,
> I made a little test program to se what dump_memory_stats would look
> like. Nothing happened, and I saw that GCRYCTL_DUMP_MEMORY_STATS is a
> no-op right now:
> $ grep -n -A2 GCRYCTL_DUMP_MEMORY_STATS `find . -name *.c`
> ./src/global.c:361: case GCRYCTL_DUMP_MEMORY_STATS:
> ./src/global.c-362- /*m_print_stats("[fixme: prefix]");*/
> ./src/global.c-363- break;
> I can't find the function m_print_stats() anywhere either.
> On 04/20/2015 11:01 AM, Werner Koch wrote:
>> On Mon, 20 Apr 2015 01:10, julien.voisin at dustri.org said:
>>> Also, I'm wondering how I can estimate how much memory I should
>>> allocate; for now I tried with 32k and the testsuite is running great,
>>> but I'm worried about some possible breakages.
>> You may call
>> gcry_control (GCRYCTL_DUMP_MEMORY_STATS);
>> which prints some memory stats to stderr or the Libgcrypt log handler.
>> But see also the other comments.
> Gcrypt-devel mailing list
> Gcrypt-devel at gnupg.org
More information about the Gcrypt-devel