RetroPie forum home
    • Recent
    • Tags
    • Popular
    • Home
    • Docs
    • Register
    • Login
    Please do not post a support request without first reading and following the advice in https://retropie.org.uk/forum/topic/3/read-this-first

    advmame 3.9 crash on exit

    Scheduled Pinned Locked Moved Help and Support
    rpiadvmamecrash
    18 Posts 8 Posters 1.3k Views
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • J
      joyrider3774
      last edited by joyrider3774

      i just ran into this same problem but left misc_smp off as i'm not sure if the error occurs if nvram and highscores are saved as well. did anyone verify that ?

      1 Reply Last reply Reply Quote 0
      • A
        andrewsi
        last edited by

        I have certainly seen NVRAM and high scores be updated with SMP on, so it seems like it's the config file writing that somehow seems to be implicated in the crash. On the Pi4 turning SMP off seems like a non-starter, performance is severely impacted, evidently due to the emulated frame buffer. The official Advmame page recommends turning off the DRM/KMS driver to get a real frame buffer, but then EmulationStation doesn't run, so it's a little bit of a no-win situation at the moment.

        1 Reply Last reply Reply Quote 0
        • G
          grant2258 Banned
          last edited by

          @andrewsi said in advmame 3.9 crash on exit:

          rter, performance is severely impacted, evidently due to the emulated frame buffer. The official Advmame page recommends turning off the DRM/KMS driver to get a

          compile this with debugging info and asan it will give you fault location

          A 1 Reply Last reply Reply Quote 0
          • A
            andrewsi @grant2258
            last edited by

            @grant2258 Well, I used ./configure --include-debug, rebuilt, and repro'd it, but not sure the info is all that useful:

            Executing: /opt/retropie/emulators/advmame/bin/advmame "arkanoid"
            Signal SIGSEGV[fffffffah], fault at 0x324, from code at (nil)
            Compiled Jun 14 2020, 18:48:58

            1 Reply Last reply Reply Quote 0
            • G
              grant2258 Banned
              last edited by

              well all i can suggest is add -fsanitize=address,undefined CFLAGS and LDFLAGS here https://github.com/amadvance/advancemame/blob/95a36b507aaddbc7f71691a292919a1edc1af495/configure.ac#L168 that should give you and indication of whats going wrong

              1 Reply Last reply Reply Quote 0
              • A
                andrewsi
                last edited by

                I spent a bunch of time trying to get it to build correctly with --enable-debug AND with the configure.ac edited with -fsanitize=address,undefined in the CFLAGS and LFLAGS, but I have not been successful. I wind up with a huge pile of BFD assertion failures during link, and one unresolved reference that keep the build from completing:

                /usr/bin/ld: obj/cfg/linux/debug/blit/blit.o: in function interp_16_dist3': /home/pi/RetroPie-Setup/tmp/build/advmame/advance/blit/interp.h:494: undefined reference to interp_16_dist'
                /usr/bin/ld: /home/pi/RetroPie-Setup/tmp/build/advmame/advance/blit/interp.h:494: undefined reference to `interp_16_dist'
                collect2: error: ld returned 1 exit status
                make: *** [advance/cfg.mak:269: obj/cfg/linux/debug/advcfg] Error 1
                make: *** Waiting for unfinished jobs....
                /usr/bin/ld: BFD (GNU Binutils for Raspbian) 2.31.1 assertion fail ../../bfd/elf32-arm.c:9853
                /usr/bin/ld: BFD (GNU Binutils for Raspbian) 2.31.1 assertion fail ../../bfd/elf32-arm.c:9853
                /usr/bin/ld: BFD (GNU Binutils for Raspbian) 2.31.1 assertion fail ../../bfd/elf32-arm.c:9853
                ...repeat a few hundred times...

                Neither of these occurs with a standard build.

                1 Reply Last reply Reply Quote 0
                • A
                  andrewsi
                  last edited by

                  Actually, I retract that. I did get it compiled with these options, but the data returned after the crash was equally unhelpful. The address changed but still no symbols, source location, or anything useful.

                  1 Reply Last reply Reply Quote 0
                  • J
                    joyrider3774
                    last edited by

                    Somthing corrupting the stack then or error happening in a lib?

                    A 1 Reply Last reply Reply Quote 0
                    • A
                      andrewsi @joyrider3774
                      last edited by

                      @joyrider3774 Well, must be pretty bad since I can’t get any kind of location or call stack. Unfortunately I’m much better at debugging in Windows than on GDB. In did try to get it to break into GDB but between the video not being in a text mode when the error occurs and the lack of usable info on the segfault I’m out of my depth. Since it’s easy to repro, I’m hoping somebody more skilled will take up the charge.

                      J 1 Reply Last reply Reply Quote 0
                      • J
                        joyrider3774 @andrewsi
                        last edited by

                        @andrewsi starting it from gdb inside a ssh session could work to have text mode, unless you tried that. But could be it wont break on correct location either then. Not used gdb that much for such problems

                        1 Reply Last reply Reply Quote 0
                        • First post
                          Last post

                        Contributions to the project are always appreciated, so if you would like to support us with a donation you can do so here.

                        Hosting provided by Mythic-Beasts. See the Hosting Information page for more information.