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

release/19.x: [loongarch][DAG][FREEZE] Fix crash when FREEZE a half(f16) type on loongarch (#107791) #109093

Open
wants to merge 1 commit into
base: release/19.x
Choose a base branch
from

Commits on Oct 19, 2024

  1. [loongarch][DAG][FREEZE] Fix crash when FREEZE a half(f16) type on lo…

    …ongarch (llvm#107791)
    
    For zig with LLVM 19.1.0rc4, we are seeing the following error when
    bootstrapping a `loongarch64-linux-musl` target.
    
    ziglang/zig-bootstrap#164 (comment)
    
    It seems that this issue is caused by `PromoteFloatResult` is not
    handling FREEZE OP on loongarch.
    
    Here is the reproduction of the error: https://godbolt.org/z/PPfvWjjG5
    
    ~~This patch adds the FREEZE OP handling with `PromoteFloatRes_UnaryOp`
    and adds a test case.~~
    
    This patch changes loongarch's way of floating point promotion to soft
    promotion to avoid this problem.
    
    See: loongarch's handling of `half`:
    - llvm#93894
    - llvm#94456
    
    Also see: other float promotion FREEZE handling
    -
    llvm@0019c2f
    
    (cherry picked from commit 13280d9)
    yxd-ym authored and heiher committed Oct 19, 2024
    Configuration menu
    Copy the full SHA
    bd494f3 View commit details
    Browse the repository at this point in the history