Re: [RFC] RISC-V: Support risc-v bfloat16 This patch support bfloat16 in riscv like x86_64 and arm.

2023-06-17 Thread Jeff Law via Gcc-patches
On 6/15/23 03:52, Jin Ma wrote: There are also some problems here, which cannot be simply handled like HF. Many instructions support HF but do not support BF. For example, fadd.h can be used for HF but cannot be used for BF. I guess it may need to be converted to SF first, then fadd.s, a

Re: [RFC] RISC-V: Support risc-v bfloat16 This patch support bfloat16 in riscv like x86_64 and arm.

2023-06-15 Thread Jin Ma via Gcc-patches
> diff --git a/gcc/config/riscv/iterators.md b/gcc/config/riscv/iterators.md > index 5b70ab20758..6349f032bc8 100644 > --- a/gcc/config/riscv/iterators.md > +++ b/gcc/config/riscv/iterators.md > @@ -61,10 +61,15 @@ > ;; Iterator for hardware-supported floating-point modes. > (define_mode_iterator

Re: [RFC] RISC-V: Support risc-v bfloat16 This patch support bfloat16 in riscv like x86_64 and arm.

2023-06-15 Thread Jin Ma via Gcc-patches
> diff --git a/gcc/common/config/riscv/riscv-common.cc > b/gcc/common/config/riscv/riscv-common.cc > index ebc1ed7d7e4..2b3ff1f5b8e 100644 > --- a/gcc/common/config/riscv/riscv-common.cc > +++ b/gcc/common/config/riscv/riscv-common.cc > @@ -102,6 +102,8 @@ static const riscv_implied_info_t riscv_i

Re: FW: [RFC] RISC-V: Support risc-v bfloat16 This patch support bfloat16 in riscv like x86_64 and arm.

2023-06-01 Thread Jeff Law via Gcc-patches
On 6/1/23 10:56, Palmer Dabbelt wrote: On Thu, 01 Jun 2023 09:48:47 PDT (-0700), jeffreya...@gmail.com wrote: On 6/1/23 01:01, juzhe.zh...@rivai.ai wrote: I plan to implement BF16 vector in GCC but still waiting for ISA ratified since GCC policy doesn't allow un-ratified ISA. Right.  So t

Re: FW: [RFC] RISC-V: Support risc-v bfloat16 This patch support bfloat16 in riscv like x86_64 and arm.

2023-06-01 Thread Philipp Tomsich
On Thu, 1 Jun 2023 at 18:49, Jeff Law via Gcc-patches wrote: > > > > On 6/1/23 01:01, juzhe.zh...@rivai.ai wrote: > > I plan to implement BF16 vector in GCC but still waiting for ISA > > ratified since GCC policy doesn't allow un-ratified ISA. > Right. So those specs need to move along further be

Re: FW: [RFC] RISC-V: Support risc-v bfloat16 This patch support bfloat16 in riscv like x86_64 and arm.

2023-06-01 Thread Palmer Dabbelt
On Thu, 01 Jun 2023 09:48:47 PDT (-0700), jeffreya...@gmail.com wrote: On 6/1/23 01:01, juzhe.zh...@rivai.ai wrote: I plan to implement BF16 vector in GCC but still waiting for ISA ratified since GCC policy doesn't allow un-ratified ISA. Right. So those specs need to move along further befor

Re: FW: [RFC] RISC-V: Support risc-v bfloat16 This patch support bfloat16 in riscv like x86_64 and arm.

2023-06-01 Thread Jeff Law via Gcc-patches
On 6/1/23 01:01, juzhe.zh...@rivai.ai wrote: I plan to implement BF16 vector in GCC but still waiting for ISA ratified since GCC policy doesn't allow un-ratified ISA. Right. So those specs need to move along further before we can start integrating code. Currently, we are working on INT8,

Re: [RFC] RISC-V: Support risc-v bfloat16 This patch support bfloat16 in riscv like x86_64 and arm.

2023-06-01 Thread Liao Shihua
Hi, Ma Jin     1. There are few developments since May in GCC because the spec of Zfbf is constantly changing.     2. We (PLCT lab) will implement Zvfbfmin and Zvfbfwma after Zvfh has been merged in GCC.     3. I will send a patch to support bfloat1

Re: FW: [RFC] RISC-V: Support risc-v bfloat16 This patch support bfloat16 in riscv like x86_64 and arm.

2023-06-01 Thread juzhe.zh...@rivai.ai
he.zh...@rivai.ai From: Li, Pan2 Date: 2023-06-01 14:57 To: juzhe.zh...@rivai.ai Subject: FW: [RFC] RISC-V: Support risc-v bfloat16 This patch support bfloat16 in riscv like x86_64 and arm. FYI. -Original Message- From: Gcc-patches On Behalf Of Jin Ma via Gcc-patches Sent: Thursday, J

[RFC] RISC-V: Support risc-v bfloat16 This patch support bfloat16 in riscv like x86_64 and arm.

2023-05-31 Thread Jin Ma via Gcc-patches
hi, Are there any new developments about Zfb? Are there any plans to implement the Zvfbfmin and Zvfbfwma expansion? I see that Zfb is being reviewed in llvm, maybe we should do the same on gcc. Ref: https://reviews.llvm.org/D151313 https://reviews.llvm.org/D150929

Re: [RFC] RISC-V: Support risc-v bfloat16 This patch support bfloat16 in riscv like x86_64 and arm.

2023-04-25 Thread Kito Cheng via Gcc-patches
Hi ShiHua: Thanks for your contribution to the zfbfmin extension :) General comments: - Add zfbfmin to riscv_ext_version_table - Add test case to verify the -march is accepted. - Add testcase to test argument passing. - Add testcase for operations. - Add testcase for compares. > +(define_insn "*

[RFC] RISC-V: Support risc-v bfloat16 This patch support bfloat16 in riscv like x86_64 and arm.

2023-03-07 Thread Liao Shihua
According to https://github.com/riscv/riscv-bfloat16 , zfbfmin extension depends on zfh/zfhmin extension. According to the discussion https://github.com/riscv-non-isa/riscv-elf-psabi-doc/pull/367, this use __bf16 and use DF16b in riscv_mangle_type like x86. gcc\ChangeLog: * com