r621: --print-qname also shows kalloc status

This commit is contained in:
Heng Li 2017-12-11 12:30:08 -05:00
parent f6608fe99c
commit 43960a8ca7
2 changed files with 3 additions and 2 deletions

2
main.c
View File

@ -6,7 +6,7 @@
#include "mmpriv.h"
#include "getopt.h"
#define MM_VERSION "2.5-r620-dirty"
#define MM_VERSION "2.5-r621-dirty"
#ifdef __linux__
#include <sys/resource.h>

3
map.c
View File

@ -375,7 +375,8 @@ void mm_map_frag(const mm_idx_t *mi, int n_segs, const int *qlens, const char **
if (b->km) {
km_stat(b->km, &kmst);
// fprintf(stderr, "QM\t%s\t%d\tcap=%ld,nCore=%ld,largest=%ld\n", qname, qlen_sum, kmst.capacity, kmst.n_cores, kmst.largest);
if (mm_dbg_flag & MM_DBG_PRINT_QNAME)
fprintf(stderr, "QM\t%s\t%d\tcap=%ld,nCore=%ld,largest=%ld\n", qname, qlen_sum, kmst.capacity, kmst.n_cores, kmst.largest);
assert(kmst.n_blocks == kmst.n_cores); // otherwise, there is a memory leak
if (kmst.largest > 1U<<28) {
km_destroy(b->km);