memory_usage_return_type

Greetings,

I noticed the return types for the memory usage function in fix.h and compute.h are set to double? is that intentional or should it be an int?

that is intentional. as doubles can represent much larger numbers. these are estimates anyway and usually a lower boundary of how much memory is allocated (as it usually only counts large memory allocations).

axel.

Yea that sounds reasonable, thanks for explaining.

Adrian Diaz

BTW: if you are running on Linux, you can query the total amount of memory that has been reserved through malloc (reserved memory pool) as part of the “info memory” command.

axel.

Sounds handy, thanks.

Adrian Diaz