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

[LoongArch] Pass 'half' in the lower 16 bits of an f32 value with F/D ABI #109368

Closed
wants to merge 2 commits into from

Commits on Sep 20, 2024

  1. [LoongArch] Pass 'half' in the lower 16 bits of an f32 value when F e…

    …xtension is enabled
    
    LoongArch currently lacks a hardware extension for the fp16 data type, and the
    ABI documentation does not explicitly define how to handle fp16. Future revsions
    of the LoongArch specification will include conventions to address fp16 requirements.
    
    Previously, we maintained the 'half' type in its 16-bit format between operations.
    Regardless of whether the F extension is enabled, the value would be passed in the
    lower 16 bits of a GPR in its 'half' format.
    
    With this patch, depending on the ABI in use, the value will be passed either in
    an FPR or a GPR in 'half' format. This ensures consistency with the bits location
    when the fp16 hardware extension is enabled.
    heiher committed Sep 20, 2024
    Configuration menu
    Copy the full SHA
    235cada View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    cda651c View commit details
    Browse the repository at this point in the history