Sergio Baldoví - 2012-03-16

"valgrind --track-origins=yes" give more details, mainly "Uninitialised value was created by a heap allocation". Full log here:
http://pastebin.com/EDvjMXj0

z80_ed.c:41 is a "SBC16(BD)" sentence. Unrolling this macro shows warnings with overflow_sub_table[] and halfcarry_sub_table[] array access.
opcodes_base.c:725 is a "OR(A)" sentence. Unrolling this macro shows warnings with sz53p_table[] array access.
opcodes_base.c:803 is a "if (F & FLAG_Z)" sentence.

It seems that BD, A and F registers have uninitialised data that valgrind has tracked from divide_ram pages. Initializing allocated RAM cleans these messages, but I'm not sure if this really fix or hide the real issue. Patch here:
http://pastebin.com/tapCnfLf

Any views on this?