Re: [Gaul-devel] glibc detected *** double free or corruption (!prev) for integer Differential Evol
Brought to you by:
stewartadcock
From: Gangadhar N. <npk...@gm...> - 2008-03-05 17:36:37
|
Stewart, I also don't have access to the code right now to be certain as to what is the problem, but the question from the stack trace I have is - why should the datatype of whatever is being deleted be instrumental in a coredump. From the stack it looks like it is a double delete. So, is it a case of a border condition being hit when the data became float. Just a thought. Thank you Gangadhar On 3/2/08, Stewart Adcock <ste...@gm...> wrote: > Hi Nick, > > I don't have access to the source to check, but I am pretty sure that > the differential evolution algorithm requires chromosomes with > continuous rather than discrete values. Therefore, it does not > support integers; it probably only supports doubles as currently > implemented. > > This should be documented somewhere, but it most likely not. So, > sorry about that, > > Regards, > Stewart. > > 2008/2/26 Nick Hall <dar...@gm...>: > > Hello, > > > > I recently started using GAUL and I like it so far, however, I've run into a > > problem. > > > > If I compile and run the polynomial_de example it works just fine, however, > > I changed the chromosomes, which were doubles, to ints, and also changed the > > call to ga_genesis_double to ga_genesis_int to account for the change in > > data type. > > > > Now when I run the program it crashes with the output: > > > > Strategy DE/best/1/exp (DE0) ; C = 0.800000 ; F = 0.500000 > > 0: A = 1 B = 1 C = 1 D = 1 (fitness = -0.716106) > > *** glibc detected *** double free or corruption (!prev): 0x0000000000503d70 > > *** > > Aborted (core dumped) > > > > I ran valgrind on the program and got the following output: > > > > Strategy DE/best/1/exp (DE0) ; C = 0.800000 ; F = 0.500000 > > ==3256== Conditional jump or move depends on uninitialised value(s) > > ==3256== at 0x36DA011C46: > > ga_population_set_differentialevolution_parameters (in > > /usr/lib64/libgaul.so.0.0.49) > > ==3256== by 0x400C99: main (polynomial_de.c:231) > > 0: A = 1 B = 1 C = 1 D = 1 (fitness = -0.716106) > > ==3256== > > ==3256== Invalid read of size 8 > > ==3256== at 0x36DA012C13: ga_differentialevolution (in > > /usr/lib64/libgaul.so.0.0.49) > > ==3256== by 0x400CA6: main (polynomial_de.c:237) > > ==3256== Address 0x4A31C60 is 8 bytes after a block of size 16 alloc'd > > ==3256== at 0x4904A06: malloc (vg_replace_malloc.c:149) > > ==3256== by 0x36D9E09693: s_malloc_safe (in > > /usr/lib64/libgaul_util.so.0.0.49) > > ==3256== by 0x36DA009712: ga_chromosome_integer_allocate (in > > /usr/lib64/libgaul.so.0.0.49) > > ==3256== by 0x36DA00DEAB: ga_get_free_entity (in > > /usr/lib64/libgaul.so.0.0.49) > > ==3256== by 0x36DA00E067: gaul_population_fill (in > > /usr/lib64/libgaul.so.0.0.49) > > ==3256== by 0x36DA01219E: ga_differentialevolution (in > > /usr/lib64/libgaul.so.0.0.49) > > ==3256== by 0x400CA6: main (polynomial_de.c:237) > > etc...... > > > > Just for comparison, I tried running valgrind on the original program (with > > doubles) and it did not detect any memory problems. > > > > I am running GAUL 0.1849-0, CentOS 4.6, Linux kernel 2.6.9-67.0.4, GCC > > version 3.4.6. > > > > I also wrote my own program using ints and differential evolution and have > > the same issue. Does anyone know what could be causing this problem with > > ints? Thanks, > > > > Nick > > > > > > ------------------------------------------------------------------------- > > This SF.net email is sponsored by: Microsoft > > Defy all challenges. Microsoft(R) Visual Studio 2008. > > http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/ > > _______________________________________________ > > Gaul-devel mailing list > > Gau...@li... > > https://lists.sourceforge.net/lists/listinfo/gaul-devel > > > > > > > > -- > ste...@gm... http://www.linkedin.com/in/stewartadcock > 14 Royal Native Way, Whitstable, Kent CT5 4UE > Home: +44 (0) 1227 262 311 Mobile: +44 (0) 7733 337 674 > > ------------------------------------------------------------------------- > This SF.net email is sponsored by: Microsoft > Defy all challenges. Microsoft(R) Visual Studio 2008. > http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/ > _______________________________________________ > Gaul-devel mailing list > Gau...@li... > https://lists.sourceforge.net/lists/listinfo/gaul-devel > |