qemu-devel
[Top][All Lists]
Advanced

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

Re: [Qemu-devel] [PATCH v3 02/12] add hierarchical bitmap data type and


From: Paolo Bonzini
Subject: Re: [Qemu-devel] [PATCH v3 02/12] add hierarchical bitmap data type and test cases
Date: Tue, 22 Jan 2013 07:57:27 -0500 (EST)

> make check failed for me, and it turns out it was because
> MALLOC_CHECK_=3 was set. Look:
> 
> $ valgrind tests/test-hbitmap
> ==5964== Memcheck, a memory error detector
> ==5964== Copyright (C) 2002-2010, and GNU GPL'd, by Julian Seward et
> al.
> ==5964== Using Valgrind-3.6.1 and LibVEX; rerun with -h for copyright
> info
> ==5964== Command: tests/test-hbitmap
> ==5964==
> /hbitmap/size/0: OK
> /hbitmap/size/unaligned: OK
> /hbitmap/iter/empty: OK
> /hbitmap/iter/past: ==5964== Invalid read of size 8
> ==5964==    at 0x10A6E1: hbitmap_iter_init (hbitmap.c:158)
> ==5964==    by 0x108D24: hbitmap_test_check (test-hbitmap.c:42)
> ==5964==    by 0x50ABCA7: g_test_run_suite_internal
> (gtestutils.c:1174)
> ==5964==    by 0x50ABE15: g_test_run_suite_internal
> (gtestutils.c:1233)
> ==5964==    by 0x50ABE15: g_test_run_suite_internal
> (gtestutils.c:1233)
> ==5964==    by 0x50AC10E: g_test_run_suite (gtestutils.c:1282)
> ==5964==    by 0x108B12: main (test-hbitmap.c:405)
> ==5964==  Address 0x9af7c90 is 0 bytes after a block of size 32,768
> alloc'd
> ==5964==    at 0x4A04B84: calloc (vg_replace_malloc.c:467)
> ==5964==    by 0x508E667: g_malloc0 (gmem.c:196)
> ==5964==    by 0x10AE63: hbitmap_alloc (hbitmap.c:390)
> ==5964==    by 0x108F95: hbitmap_test_init (test-hbitmap.c:80)
> ==5964==    by 0x109DF3: test_hbitmap_iter_past (test-hbitmap.c:204)
> ==5964==    by 0x50ABCA7: g_test_run_suite_internal
> (gtestutils.c:1174)
> ==5964==    by 0x50ABE15: g_test_run_suite_internal
> (gtestutils.c:1233)
> ==5964==    by 0x50ABE15: g_test_run_suite_internal
> (gtestutils.c:1233)
> ==5964==    by 0x50AC10E: g_test_run_suite (gtestutils.c:1282)
> ==5964==    by 0x108B12: main (test-hbitmap.c:405)
> ==5964==

I'll replace the faulty testcase with an assertion and delete it.

Paolo



reply via email to

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