On 5/24/24 5:39 PM, Palmer Dabbelt wrote:
On Fri, 24 May 2024 16:31:48 PDT (-0700), jeffreya...@gmail.com wrote:


On 5/24/24 11:14 AM, Palmer Dabbelt wrote:
On Fri, 24 May 2024 09:19:09 PDT (-0700), Robin Dapp wrote:
We should have something in doc/invoke too, this one is going to be
tricky for users.  We'll also have to define how this interacts with
the existing -mstrict-align.

Addressed the rest in the attached v2 which also fixes tests.
I'm really not sure about -mstrict-align.  I would have hoped that using
-mstrict-align we'd never run into any movmisalign situation but that
might be wishful thinking.  Do we need to specify an
interaction, though?  For now the new options disables movmisalign so
if we hit that despite -mstrict-align we'd still not vectorize it.

I think we just need to write it down.  I think there's two ways to
encode this: either we treat scalar and vector as independent, or we
couple them.  If we treat them independently then we end up with four
cases, it's not clear if they're all interesting.  IIUC with this patch
we'd be able to encode
Given the ISA documents them as independent, I think we should follow
suit and allow them to vary independently.

I'm only reading Zicclsm as saying both scalar and vector misaligned accesses are supported, but nothing about the performance.
I think it was in the vector docs. It didn't say anything about performance, just a note that scalar & vector behavior could differ.




Seems reasonable to me.  Just having a regular naming scheme for the scalar/vector makes it clear what we're doing, and it's not like having the extra name for -mscalar-strict-align really costs anything.
That was my thinking -- get the names right should help avoid confusion.

Jeff

Reply via email to