• Improving IIgs shadow copy speed with NOPs

    From fadden@21:1/5 to All on Thu Sep 9 08:59:20 2021
    Many years ago I was told that inserting NOPs into IIgs screen updates could actually make things faster, because of the way the different hardware components interact when you're doing a fast copy with shadowed memory (insert a NOP every 8 or 13 PEIs).
    Somebody attached a logic analyzer to a IIgs and timed it a few different ways, and determined that there is actually no value to adding NOPs:

    https://retrocomputing.stackexchange.com/q/228/56

    Is there a flaw in their test methodology, or was this actually a myth?

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From Kent Dickey@21:1/5 to thefadden@gmail.com on Thu Sep 9 12:29:27 2021
    In article <8c43afb7-e8e6-45a5-b3bf-4c0847a2c731n@googlegroups.com>,
    fadden <thefadden@gmail.com> wrote:
    Many years ago I was told that inserting NOPs into IIgs screen updates
    could actually make things faster, because of the way the different
    hardware components interact when you're doing a fast copy with shadowed >memory (insert a NOP every 8 or 13 PEIs). Somebody attached a logic
    analyzer to a IIgs and timed it a few different ways, and determined
    that there is actually no value to adding NOPs:

    https://retrocomputing.stackexchange.com/q/228/56

    Is there a flaw in their test methodology, or was this actually a myth?

    Here is the post:

    ---
    Mythbusted!

    With 2021 knowledge of how the FPI/CYA work, this simply didn't make sense. So I plugged in a logic analyser and timed the Wolfenstein 3D code (NOP every 8 PEI's). I then modified the code to change it to a NOP every 13 PEI's, and finally to remove the NOPs altogether.

    These are the results:

    NOP every 8 PEI's - 40 PEI's takes 0.179005ms (4.475125µs/PEI)
    NOP every 13 PEI's - 39 PEI's takes 0.17446ms (4.473333µs/PEI)
    39 PEI's (No NOPs) takes 0.173758ms (4.445533µs/PEI)
    As you can see it is faster to simply issue PEI's without any NOP's.

    - Ian Brumby ---

    Ian has collected a bunch of data, but he's not fully shared enough to
    prove the NOP doesn't help (in my opinion). He probably has that data,
    and he's convinced, so he's almost certainly right. It is unfair
    to put the burden of proof on Ian to prove the NOP doesn't help.

    A detailed waveform of 40+ PEIs (more would be better--long enough to show a pattern repeating several times) would probably be enough to
  • From fadden@21:1/5 to Kent Dickey on Thu Sep 9 16:21:30 2021
    On Thursday, September 9, 2021 at 10:29:33 AM UTC-7, Kent Dickey wrote:
    A detailed waveform of 40+ PEIs (more would be better--long enough to show a pattern repeating several times) would probably be enough to show NOPs don't help PEIs.

    I was thinking more along the lines of a stripped-down game loop that ran for some large number of iterations, with timings measured by pointing a cell phone camera at it and counting elapsed video frames. Less precise, but it can be done without fancy
    hardware.

    Mostly I was hoping somebody had already done this experiment. If they had reached the conclusion that NOPs do help, it then becomes a question of why different experiments reached different conclusions.

    I wasn't able to find any evidence while researching the question initially, but before I moved the "accepted answer" check I figured I'd ping the world again to see if this was ever more than a rumor.

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)