Skip to content

hexagon: fix HVX scatter gather, BE host

Brian Cain qemu-devel 4 versions – In review

Get series with b4
b4 am [email protected]

Versions newest first · linked by author and title

  1. v4 Latest6 patches 3 repliesIn review
  2. v35 patches 4 repliesSuperseded
  3. v25 patches 7 repliesSuperseded
Earlier versions · 1
VersionPostedPatchesRepliesStatus
v13 patches5 repliesSuperseded

Changes in v4 from the cover letter

* Added a 'rename LEN to OFFS_REG_END in VTCM macros' patch

Patches in v4 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/6target/hexagon: fix HVX big-endian byte accesstarget/hexagon/cpu.c target/hexagon/genptr.c target/hexagon/mmvec/macros.h +3 more+59 -210 replies
2/6target/hexagon: fix HVX scatter/gather region-length checktarget/hexagon/mmvec/macros.h+17 -140 replies
3/6tests/tcg/hexagon: add vgather/vscatter region-length teststests/tcg/hexagon/scatter_gather.c+136 -11 reply
4/6target/hexagon: fix HVX predicate save size for histogram opstarget/hexagon/gen_tcg_hvx.h+5 -50 replies
5/6tests/tcg/hexagon: check the two HVX predicate build paths agreetests/tcg/hexagon/hvx_misc.c+45 -01 reply
6/6target/hexagon: rename LEN to OFFS_REG_END in VTCM macrostarget/hexagon/mmvec/macros.h+42 -341 reply

Reviews trailers per patch

All 6 patches have a Reviewed-by or Acked-by.

PatchAnton JohanssonMatheus Tavares BernardinoPhilippe Mathieu-DaudéPierrick Bouvier
1/6R-b R-b
2/6R-b
3/6R-b
4/6R-b R-b
5/6R-b
6/6R-b

Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes. Scroll the table sideways for all 4 reviewers.

Read the v4 thread

Cover letter [PATCH v4 0/6] hexagon: fix HVX scatter gather, BE host

Anton pointed out this endianness issue with HVX,
and found this region length issue along the way.

v4:
* Added a 'rename LEN to OFFS_REG_END in VTCM macros' patch

v3:
* Changed the region-length test to be more consistent between scatter and gather and focusing on just inside, outside, beyond the boundary.

Fixed in v2:
* byte access helpers now all use hexagon_ prefix.
* Predicate bytes are extracted from 32-bit words rather than 64-bit words, matching the host-native predicate layout.
* Gather only reads memory for lanes that are both in range and predicate enabled. So dropped lanes cannot fault or otherwise access memory.
* The gather region-length test now places an out-of-range offset on an inaccessible page, verifying that a dropped lane performs no read.

Added v2 commits:
* fix for histogram predicates - were using the wrong size
* test to cover predicate byte permutation

Brian Cain (6):
target/hexagon: fix HVX big-endian byte access target/hexagon: fix HVX scatter/gather region-length check tests/tcg/hexagon: add vgather/vscatter region-length tests target/hexagon: fix HVX predicate save size for histogram ops tests/tcg/hexagon: check the two HVX predicate build paths agree target/hexagon: rename LEN to OFFS_REG_END in VTCM macros

 target/hexagon/gen_tcg_hvx.h            |  10 +-
 target/hexagon/mmvec/macros.h           | 116 +++++++++++---------
 target/hexagon/mmvec/mmvec.h            |  18 ++++
 target/hexagon/cpu.c                    |  17 +--
 target/hexagon/genptr.c                 |   3 +-
 target/hexagon/mmvec/system_ext_mmvec.c |   2 +-
 target/hexagon/op_helper.c              |  17 ++-
 tests/tcg/hexagon/hvx_misc.c            |  45 ++++++++
 tests/tcg/hexagon/scatter_gather.c      | 137 +++++++++++++++++++++++-
 9 files changed, 297 insertions(+), 68 deletions(-)
Signature · 1 line
2.34.1