All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH 0/4] Refactor get_fpstatus_ptr() ready for AArch32 fp16
@ 2020-08-06 10:44 Peter Maydell
  2020-08-06 10:44 ` [PATCH 1/4] target/arm: Replace A64 get_fpstatus_ptr() with generic fpstatus_ptr() Peter Maydell
                   ` (4 more replies)
  0 siblings, 5 replies; 13+ messages in thread
From: Peter Maydell @ 2020-08-06 10:44 UTC (permalink / raw)
  To: qemu-arm, qemu-devel

This patchset refactors the existing get_fpstatus_ptr() functions,
and fixes a bug where we weren't getting FZ16 right for AArch32
VCMLA, VCADD of fp16 types.

We currently have two versions of get_fpstatus_ptr(), which both take
an effectively boolean argument:
 * the one for A64 takes "bool is_f16" to distinguish fp16 from other ops
 * the one for A32/T32 takes "int neon" to distinguish Neon from other ops

This is confusing, and to implement ARMv8.2-FP16 the A32/T32 one will
need to make a four-way distinction between "non-Neon, FP16",
"non-Neon, single/double", "Neon, FP16" and "Neon, single/double".
The A64 version will then be a strict subset of the A32/T32 version.

The patchset creates a single fpstatus_ptr() function which takes
an enum selecting between the 4 possible fpstatus options.
It then adds the implementation of the "Neon standard FPST for f16".
Finally, we can then use to fix a bug in the VCMLA/VCADD fp16
handling where we were using FPST_STD rather than FPST_STD_F16.
(The difference is that the former will not honour FPSCR.FZ16.)

Based-on: 20200803111849.13368-1-peter.maydell@linaro.org
("[PATCH 0/7] target/arm: copro decode cleanup)
but only textually; there are no semantic dependencies to that series.

thanks
-- PMM

Peter Maydell (4):
  target/arm: Replace A64 get_fpstatus_ptr() with generic fpstatus_ptr()
  target/arm: Make A32/T32 use new fpstatus_ptr() API
  target/arm: Implement FPST_STD_F16 fpstatus
  target/arm: Use correct FPST for VCMLA, VCADD on fp16

 target/arm/cpu.h                |  9 +++-
 target/arm/translate-a64.h      |  1 -
 target/arm/translate.h          | 52 +++++++++++++++++++
 target/arm/cpu.c                |  3 ++
 target/arm/translate-a64.c      | 89 +++++++++++++--------------------
 target/arm/translate-neon.inc.c | 28 +++++------
 target/arm/translate-sve.c      | 34 ++++++-------
 target/arm/translate-vfp.inc.c  | 44 ++++++++--------
 target/arm/translate.c          | 13 -----
 target/arm/vfp_helper.c         |  5 ++
 10 files changed, 156 insertions(+), 122 deletions(-)

-- 
2.20.1


^ permalink raw reply	[flat|nested] 13+ messages in thread

end of thread, other threads:[~2020-08-06 21:08 UTC | newest]

Thread overview: 13+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2020-08-06 10:44 [PATCH 0/4] Refactor get_fpstatus_ptr() ready for AArch32 fp16 Peter Maydell
2020-08-06 10:44 ` [PATCH 1/4] target/arm: Replace A64 get_fpstatus_ptr() with generic fpstatus_ptr() Peter Maydell
2020-08-06 11:44   ` Alex Bennée
2020-08-06 10:44 ` [PATCH 2/4] target/arm: Make A32/T32 use new fpstatus_ptr() API Peter Maydell
2020-08-06 11:46   ` Alex Bennée
2020-08-06 11:46     ` Alex Bennée
2020-08-06 10:44 ` [PATCH 3/4] target/arm: Implement FPST_STD_F16 fpstatus Peter Maydell
2020-08-06 11:47   ` Alex Bennée
2020-08-06 11:47     ` Alex Bennée
2020-08-06 10:44 ` [PATCH 4/4] target/arm: Use correct FPST for VCMLA, VCADD on fp16 Peter Maydell
2020-08-06 11:50   ` Alex Bennée
2020-08-06 11:50     ` Alex Bennée
2020-08-06 21:08 ` [PATCH 0/4] Refactor get_fpstatus_ptr() ready for AArch32 fp16 Richard Henderson

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.