• Nils Goroll's avatar
    Fix assertion on region vs object liveliness during log read · a3075023
    Nils Goroll authored
    This concerns an open issue from before the public release, which I
    had not understood before and believe to have understood now.
    
    With this code *) added to the test
    
    @@ -5946,6 +5949,15 @@ t_cache(unsigned chksum)
    	test_bocdone(fbo, TRUST_ME(hash), 1);
    	fellow_cache_obj_deref(fc, fco);
    
    +	// === max out region alloc
    +	fbo = fellow_busy_obj_alloc(fc, &fco, &priv2, 1234).r.ptr;
    +	CHECK_OBJ_NOTNULL(fbo, FELLOW_BUSY_MAGIC);
    +	for (u = 0; u < FCO_MAX_REGIONS; u++)
    +		AN(fellow_busy_region_alloc(fbo, 1234, INT8_MAX));
    +
    +	test_bocdone(fbo, TRUST_ME(hash), 1);
    +	fellow_cache_obj_delete(fc, fco, hash);
    +
    	// === alloc space, dont use
    
    we tripped here
    
       assert(flivs->oob || u == obj_alive);
    
    with u == 1 and obj_alive == 0.
    
    So the offset of a region from a dead object was not taken by a
    subsequent allocation, which is fine, why should it be?
    
    *) Note: The added test code is not correct yet, as it does not
       register the regions with the segment list, so obj_delete leaks.
    a3075023
Name
Last commit
Last update
..
foreign Loading commit data...
tbl Loading commit data...
vtc Loading commit data...
Makefile.am Loading commit data...
VSC_buddy.vsc Loading commit data...
VSC_fellow.vsc Loading commit data...
aux_cache_wrk.c Loading commit data...
bitf.h Loading commit data...
bitsof.h Loading commit data...
buddy.c Loading commit data...
buddy.h Loading commit data...
buddy_storage.c Loading commit data...
buddy_storage.h Loading commit data...
buddy_tune.c Loading commit data...
buddy_tune.h Loading commit data...
buddy_util.h Loading commit data...
buddy_witness.h Loading commit data...
compiler.h Loading commit data...
debug.h Loading commit data...
fcs_states.doth Loading commit data...
fellow_cache.c Loading commit data...
fellow_cache.h Loading commit data...
fellow_cache_storage.h Loading commit data...
fellow_const.h Loading commit data...
fellow_debug.h Loading commit data...
fellow_diag.h Loading commit data...
fellow_errhandling.h Loading commit data...
fellow_hash.c Loading commit data...
fellow_hash.h Loading commit data...
fellow_hashes.h Loading commit data...
fellow_inject.h Loading commit data...
fellow_io.h Loading commit data...
fellow_io_aio.c Loading commit data...
fellow_io_backend.h Loading commit data...
fellow_io_ioctl.c Loading commit data...
fellow_io_ioctl.h Loading commit data...
fellow_io_threads.c Loading commit data...
fellow_io_uring.c Loading commit data...
fellow_log.c Loading commit data...
fellow_log.h Loading commit data...
fellow_log_dbg.c Loading commit data...
fellow_log_dle_chg.h Loading commit data...
fellow_log_iter_out.h Loading commit data...
fellow_log_storage.h Loading commit data...
fellow_log_test.c Loading commit data...
fellow_pri.h Loading commit data...
fellow_regionlist.h Loading commit data...
fellow_sha256.c Loading commit data...
fellow_sha256.h Loading commit data...
fellow_stash.h Loading commit data...
fellow_storage.c Loading commit data...
fellow_storage.h Loading commit data...
fellow_storage_deref.h Loading commit data...
fellow_task.h Loading commit data...
fellow_testenv.c Loading commit data...
fellow_testenv.h Loading commit data...
fellow_tune.c Loading commit data...
fellow_tune.h Loading commit data...
flint.h Loading commit data...
flint.lnt Loading commit data...
pow2_units.c Loading commit data...
pow2_units.h Loading commit data...
slash-counters.rst Loading commit data...
slashmap.c Loading commit data...
slashmap.h Loading commit data...
slashmap.rst.in Loading commit data...
slashmap_options.h Loading commit data...
vmod_slash.c Loading commit data...
vmod_slash.man.rst Loading commit data...
vmod_slash.vcc Loading commit data...
vmod_slash_loadmasters.c Loading commit data...