#30 Error while booting the system on MorphOS and MacOSX: unexplained cache miss

PPCJITBETA02
closed
None
2014-03-14
2014-02-23
No

While AmigaOS3.9 is booting the emulation quits suddenly with an error message in the console:
"JIT: Unexplained cache miss [pointer] [pointer]".

This bug cannot be reproduced on AmigaOS4, only on MorphOS and MacOSX. Probably it is related to the memory layout of these systems and it is working on AmigaOS4 by accident.
The bug is not related to any instruction emulation, it can be reproduced if only a few instructions are enabled for the JIT compiling and all the others fall back to the interpretive emulation.

Related

Tickets: #30

Discussion

  • Tobias Netzel

    Tobias Netzel - 2014-02-23

    I don't see this error message here on OS X.

    Instead I get endless resets and a console output like this:
    "reset at 0
    JIT: Compiling reset
    JIT: Change cache emulation: disabled
    PAL mode, 50Hz (h=227 v=312)
    chipmem cleared
    SERIAL: period=372, baud=9600, hsyncs=16 PC=f8018a
    JIT: Change cache emulation: enabled
    JIT: Change cache emulation: enabled
    B-Trap f201 at 00f80ca0 (0x854aca0)
    reset at f80dc8
    JIT: Compiling reset
    JIT: Change cache emulation: disabled
    PAL mode, 50Hz (h=227 v=312)
    reset at f800d0
    JIT: Compiling reset
    JIT: Change cache emulation: disabled
    PAL mode, 50Hz (h=227 v=312)
    JIT: Change cache emulation: enabled
    JIT: Change cache emulation: enabled
    B-Trap f201 at 00f80cac (0x854aca0)
    reset at f80dc8
    JIT: Compiling reset
    JIT: Change cache emulation: disabled
    PAL mode, 50Hz (h=227 v=312)
    reset at f800d0
    JIT: Compiling reset
    JIT: Change cache emulation: disabled
    PAL mode, 50Hz (h=227 v=312)
    JIT: Change cache emulation: enabled
    JIT: Change cache emulation: enabled
    B-Trap f201 at 00f80cac (0x854aca0)
    "

     
    • Almos Rajnai

      Almos Rajnai - 2014-02-23

      Hi Tobias,

      Yes, the exact manifestation of the error depends on the build environment
      as it seems. Probably somehow related to either the used/preserved
      registers in the code or the distances between the various parts inside the
      binary/memory.

      I am still investigating what is going on. I can reproduce it luckily.

      Cheers,

      Almos
      On Feb 24, 2014 10:33 AM, "Tobias Netzel" internetzel@users.sf.net wrote:

      I don't see this error message here on OS X.

      Instead I get endless resets and a console output like this:
      "reset at 0
      JIT: Compiling reset
      JIT: Change cache emulation: disabled
      PAL mode, 50Hz (h=227 v=312)
      chipmem cleared
      SERIAL: period=372, baud=9600, hsyncs=16 PC=f8018a
      JIT: Change cache emulation: enabled
      JIT: Change cache emulation: enabled
      B-Trap f201 at 00f80ca0 (0x854aca0)
      reset at f80dc8
      JIT: Compiling reset
      JIT: Change cache emulation: disabled
      PAL mode, 50Hz (h=227 v=312)
      reset at f800d0
      JIT: Compiling reset
      JIT: Change cache emulation: disabled
      PAL mode, 50Hz (h=227 v=312)
      JIT: Change cache emulation: enabled
      JIT: Change cache emulation: enabled
      B-Trap f201 at 00f80cac (0x854aca0)
      reset at f80dc8
      JIT: Compiling reset
      JIT: Change cache emulation: disabled
      PAL mode, 50Hz (h=227 v=312)
      reset at f800d0
      JIT: Compiling reset
      JIT: Change cache emulation: disabled
      PAL mode, 50Hz (h=227 v=312)
      JIT: Change cache emulation: enabled
      JIT: Change cache emulation: enabled
      B-Trap f201 at 00f80cac (0x854aca0)
      "


      Status: accepted
      Created: Sun Feb 23, 2014 03:35 AM UTC by Almos Rajnai
      Last Updated: Sun Feb 23, 2014 03:36 AM UTC
      Owner: Almos Rajnai

      While AmigaOS3.9 is booting the emulation quits suddenly with an error
      message in the console:
      "JIT: Unexplained cache miss [pointer] [pointer]".

      This bug cannot be reproduced on AmigaOS4, only on MorphOS and MacOSX.
      Probably it is related to the memory layout of these systems and it is
      working on AmigaOS4 by accident.
      The bug is not related to any instruction emulation, it can be reproduced
      if only a few instructions are enabled for the JIT compiling and all the
      others fall back to the interpretive emulation.


      Sent from sourceforge.net because you indicated interest in
      https://sourceforge.net/p/euaeppcjit/tickets/30/

      To unsubscribe from further messages, please visit
      https://sourceforge.net/auth/subscriptions/

       

      Related

      Tickets: #30

  • Almos Rajnai

    Almos Rajnai - 2014-03-01
    • status: accepted --> pending
     
  • Almos Rajnai

    Almos Rajnai - 2014-03-01

    This was a tricky one. It was triggered by the distance between the main code and the code buffer: an indirect jump was compiled if the distance between the target and the jump instruction was larger than 32k. For this indirect jump the LR register was used, so this register was trashed, but the block sent the return address in the LR register. So the execution kept falling back to the block, because it couldn't get the proper return address.
    This bug could also cause crashes or infinite loops as Tobias mentioned.

     
  • Tobias Netzel

    Tobias Netzel - 2014-03-02

    Still getting that infinite reset loop even after updating to the latest revision, when trying to boot Kickstart 3.1 .
    It does boot when turning off macroblock optimization. I don't know if it would have booted without the fix to this bug, but it seems to be another issue.
    Other testing ROMs work fine with macroblock optimization.

     
  • Tobias Netzel

    Tobias Netzel - 2014-03-02

    Just noticed that the README says that optimization currently doesn't work correctly.

     
    • Almos Rajnai

      Almos Rajnai - 2014-03-03

      Yep, that is covered in ticket #14.

       
  • Almos Rajnai

    Almos Rajnai - 2014-03-14
    • Status: pending --> closed
     

Log in to post a comment.

Get latest updates about Open Source Projects, Conferences and News.

Sign up for the SourceForge newsletter:

JavaScript is required for this form.





No, thanks