• MPL wonkyness

    From Gryphon@21:1/120 to g00r00 on Thursday, December 28, 2017 23:10:27
    g00r00,

    I just upgraded to the latest alpha as you can see in my tear line. I'm
    trying to play some MPL games and I'm having some severe issues. I'm playing my latest double-up! and reversi. When I exit the games, the app hangs for a second, then it drops carrier on me. It doesn't happen with each mpl, but
    it's consistant with these two. There's no entry in the node.log nor in the mis.log files.

    The only time I see things like this happen is if arrays inadvertently get overrun or if the app tries to access element zero. I've tried a number of other my apps and only the ones that don't use multidimentional arrays are the ones that don't bork.

    It's possible that I'm not doing enough error checking and am violating
    memory space so I'll check my code again. But they were working just fine before the upgrade, and now they are consistently failing. But they only
    fail after the game is played once or if I try to quit the game after
    playing. If I play once, then try to play a second time in the same session, it will fail.

    --- Mystic BBS v1.12 A37 2017/12/28 (Linux/64)
    * Origin: Cyberia BBS | cyberia.darktech.org | San Jose, CA (21:1/120)
  • From Static@21:2/140 to Gryphon on Friday, December 29, 2017 04:26:34
    On 12/28/17, Gryphon said the following...

    It's possible that I'm not doing enough error checking and am violating memory space so I'll check my code again. But they were working just
    fine before the upgrade, and now they are consistently failing.

    The code undergoing rearrangement and the prealphas being built with a lot
    of debugging enabled will make them more sensitive to bugs like buffer overflows, so that's certainly a possibility. Unless something actively stops you, you can overflow an array and nothing bad will happen as long as the affected memory belongs to you and other parts of your code never need to
    read or execute what used to be there. No signal or exception thrown, no
    foul. If something changes the way the memory is mapped out significantly between builds though, it may end up in an arrangement that isn't as okay
    with the situation as it was previously. Or the debugger itself could
    introduce watchdogs or other enforcement, etc...

    --- Mystic BBS v1.12 A36 2017/12/03 (Linux/64)
    * Origin: Subcarrier BBS (21:2/140)
  • From g00r00@21:1/108 to Gryphon on Friday, December 29, 2017 23:45:08
    The only time I see things like this happen is if arrays inadvertently
    get overrun or if the app tries to access element zero. I've tried a number of other my apps and only the ones that don't use
    multidimentional arrays are the ones that don't bork.

    This was a great observation, thank you for pointing me in the right direction. MPL can be a gigantic pain to debug.

    I made some changes for 2D and 3D arrays and I tested it with Double Up which seems to run now regardless of how I compile Mystic. I worry this change
    could break something else though, but it doesn't appear to have broken my
    BBS which has some custom MPL.

    --- Mystic BBS v1.12 A37 2017/12/29 (Windows/32)
    * Origin: Sector 7 [Mystic BBS WHQ] (21:1/108)
  • From Gryphon@21:1/120 to g00r00 on Saturday, December 30, 2017 18:05:56
    On 12/29/17, g00r00 said the following...

    The only time I see things like this happen is if arrays inadvertentl get overrun or if the app tries to access element zero. I've tried a number of other my apps and only the ones that don't use multidimentional arrays are the ones that don't bork.

    This was a great observation, thank you for pointing me in the right direction. MPL can be a gigantic pain to debug.

    I made some changes for 2D and 3D arrays and I tested it with Double Up which seems to run now regardless of how I compile Mystic. I worry this change could break something else though, but it doesn't appear to have broken my BBS which has some custom MPL.

    FWIW, I noticed that the MPY apps I wrote are also having this issue. Both
    the IBOL and SBBL apps are now just dropping carrier on me when I run them. They were running just fine before the upgrade. The only difference is that IBOL gives an error in the logs:

    2017.12.30 18:01:28 Python execute: ibol.mpy
    2017.12.30 18:01:28 An error has occured (216)
    2017.12.30 18:01:28 Shutting down

    I don't know if it's related but its definately a persistant issue.

    --- Mystic BBS v1.12 A37 2017/12/28 (Linux/64)
    * Origin: Cyberia BBS | cyberia.darktech.org | San Jose, CA (21:1/120)