commit | f47034cbe5c02b748742c733cf453b3b907687e5 | [log] [tgz] |
---|---|---|
author | Changpeng Fang <changpeng.fang@amd.com> | Fri Apr 04 21:19:43 2025 -0700 |
committer | GitHub <noreply@github.com> | Fri Apr 04 21:19:43 2025 -0700 |
tree | 59c93294eedf0b2efd6b1ab237559b54fb012e11 | |
parent | a07b37475ccbf6b718fdf64fd6f0756ea1958852 [diff] |
AMDGPU: Add round-to-odd rounding during f64 to bf16 conversion (#133995) f64 -> bf16 conversion can be lowered to f64 -> f32 followed by f32 -> bf16: v_cvt_f32_f64_e32 v0, v[0:1] v_cvt_pk_bf16_f32 v0, v0, s0 Both conversion instructions will do round-to-even rounding, and thus we will have double rounding issue which may generate incorrect result in some data range. We need to add round-to-odd rounding during f64 -> f32 to avoid double rounding,. NOTE: we are having the same issue with f64 -> f16 conversion. Will add round-to-odd rounding for it in a separate patch, which fixes SWDEV-523856 --------- Co-authored-by: Matt Arsenault <arsenm2@gmail.com>
Welcome to the LLVM project!
This repository contains the source code for LLVM, a toolkit for the construction of highly optimized compilers, optimizers, and run-time environments.
The LLVM project has multiple components. The core of the project is itself called “LLVM”. This contains all of the tools, libraries, and header files needed to process intermediate representations and convert them into object files. Tools include an assembler, disassembler, bitcode analyzer, and bitcode optimizer.
C-like languages use the Clang frontend. This component compiles C, C++, Objective-C, and Objective-C++ code into LLVM bitcode -- and from there into object files, using LLVM.
Other components include: the libc++ C++ standard library, the LLD linker, and more.
Consult the Getting Started with LLVM page for information on building and running LLVM.
For information on how to contribute to the LLVM project, please take a look at the Contributing to LLVM guide.
Join the LLVM Discourse forums, Discord chat, LLVM Office Hours or Regular sync-ups.
The LLVM project has adopted a code of conduct for participants to all modes of communication within the project.