Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fixes to the FPU and the run_test script #425

Merged
merged 5 commits into from
Feb 7, 2024

Commits on Jan 19, 2024

  1. scripts/run_test: Use grep -E instead of egrep

    Grep in Fedora 39 has started warning when invoked as 'egrep',
    so use grep -E instead to avoid the warnings.
    
    Signed-off-by: Paul Mackerras <[email protected]>
    paulusmack committed Jan 19, 2024
    Configuration menu
    Copy the full SHA
    9a4f0c1 View commit details
    Browse the repository at this point in the history

Commits on Jan 23, 2024

  1. FPU: Fix setting of FPRF

    The sign recorded in FPRF was sometimes wrong because we weren't doing
    the modifications that were done in pack_dp when setting FPRF (FPSCR
    field).  These modifications are: set sign for zero result of
    subtraction based on rounding mode; negate result for fnmadd/sub;
    but don't modify sign of NaNs.
    
    Instead we now do these modifications in the main state machine code
    and put the result in an 'rsign' variable that is used to set
    v.res_sign, then r.res_sign is used in the next cycle both for setting
    FPRF and in the pack_dp functions.  That simplifies pack_dp and lets
    us get rid of r.res_negate, r.res_subtract and r.res_rmode.
    
    Signed-off-by: Paul Mackerras <[email protected]>
    paulusmack committed Jan 23, 2024
    Configuration menu
    Copy the full SHA
    eecf1ca View commit details
    Browse the repository at this point in the history
  2. tests/fpu: Add checks for correct setting of FPRF

    Signed-off-by: Paul Mackerras <[email protected]>
    paulusmack committed Jan 23, 2024
    Configuration menu
    Copy the full SHA
    59a7996 View commit details
    Browse the repository at this point in the history

Commits on Feb 7, 2024

  1. FPU: Fix behaviour of fdiv with denormalized divisor

    Renormalization of the divisor for fdiv[s] was adjusting the result
    exponent in the wrong direction, making the result smaller in
    magnitude than it should be by a power of 2.  Fix this by negating
    r.shift in the RENORM_B2 state and then subtracting it in the LOOKUP
    cycle.
    
    Signed-off-by: Paul Mackerras <[email protected]>
    paulusmack committed Feb 7, 2024
    Configuration menu
    Copy the full SHA
    5195467 View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    7b86bf8 View commit details
    Browse the repository at this point in the history