ds12c887 causes a crash on exit for x64 (64bit)
Versatile Commodore Emulator
Brought to you by:
blackystardust,
gpz
I've noticed that when turning on support for ds12c887 RTC support (I used $D500), that when closing out Winvice, it will crash instead of a clean exit. This only seems to happen with the 64bit version of WinVice, 32bit version exits cleanly.
I'll also include a program which can be used to test/use with the RTC to get/display the time, date and day. Bug ticket #467 I noticed on here was asking for something such as this in order to test the RTC.
this one is strange... i could reproduce it first, then changed some stuff in order to track down the bug, and the crash disappeared, cant reproduce it now shrug
could you try with a recent snapshot from pokefinder?
now it happened again, here is a backtrace:
Error in `x64sc': double free or corruption (!prev): 0x0000000001d8b940
======= Backtrace: =========
/lib64/libc.so.6(+0x79053)[0x7f8d5697c053]
/lib64/libc.so.6(+0x7ebe6)[0x7f8d56981be6]
/lib64/libc.so.6(+0x7fdb2)[0x7f8d56982db2]
x64sc(cart_resources_shutdown+0xe)[0x48edfe]
x64sc(cartridge_resources_shutdown+0x9)[0x48e129]
x64sc(machine_resources_shutdown+0x35)[0x4700c5]
x64sc(machine_shutdown+0xe5)[0x45c355]
x64sc(main_exit+0x29)[0x58f639]
/lib64/libc.so.6(+0x3b319)[0x7f8d5693e319]
/lib64/libc.so.6(+0x3b3a5)[0x7f8d5693e3a5]
x64sc(ui_exit+0x128)[0x59aa28]
it may be related to switching off/on the rtc at runtime, or changing the base address....
likely related to the RTC being mapped to "internal" I/O space and still registered as a cartridge (see "export" command in monitor). likely related to bug #467
backtrace from gdb:
#0 0x00007ffff0c9d7a5 in raise () from /lib64/libc.so.6
#1 0x00007ffff0c9ec18 in abort () from /lib64/libc.so.6
#2 0x00007ffff0cde058 in __libc_message () from /lib64/libc.so.6
#3 0x00007ffff0ce3be6 in malloc_printerr () from /lib64/libc.so.6
#4 0x00007ffff0ce4db2 in _int_free () from /lib64/libc.so.6
#5 0x000000000048eeae in cart_resources_shutdown () at c64carthooks.c:590
#6 0x000000000048e1d9 in cartridge_resources_shutdown () at c64cart.c:342
#7 0x00000000004700c5 in machine_resources_shutdown () at c64.c:540
#8 0x000000000045c355 in machine_shutdown () at machine.c:298
#9 0x000000000058f6e9 in main_exit () at unixmain.c:56
Last edit: gpz 2014-10-30
applied a fix to r28662 - please retest
no more crashes here, tested [r28665] x64.
Related
Commit: [r28665]