Add heap usage for PK in benchmark

This commit is contained in:
Manuel Pégourié-Gonnard 2014-12-19 12:10:37 +01:00
parent 128657d645
commit 50da0482e0
3 changed files with 151 additions and 7 deletions

View file

@ -97,6 +97,27 @@ void memory_buffer_set_verify( int verify );
* trace if POLARSSL_MEMORY_BACKTRACE is defined.
*/
void memory_buffer_alloc_status( void );
/**
* \brief Get the peak heap usage so far
*
* \param max_used Peak number of bytes reauested by the application
* \param max_blocks Peak number of blocks reauested by the application
*/
void memory_buffer_alloc_max_get( size_t *max_used, size_t *max_blocks );
/**
* \brief Reset peak statistics
*/
void memory_buffer_alloc_max_reset( void );
/**
* \brief Get the current heap usage
*
* \param cur_used Number of bytes reauested by the application
* \param cur_blocks Number of blocks reauested by the application
*/
void memory_buffer_alloc_cur_get( size_t *cur_used, size_t *cur_blocks );
#endif /* POLARSSL_MEMORY_DEBUG */
/**