This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [RFC][PATCH] Remove SLOW_BYTE_ACCESS


On 11/17/2017 12:01 PM, Wilco Dijkstra wrote:
> Remove SLOW_BYTE_ACCESS given it's confusing, badly named,
> badly documented and used incorrectly.  Although most targets
> define it as 1, there are several targets which confuse it
> (based on comments next to it) and set it to 0 since the name 
> obviously implies it should be 0 when byte accesses are not slow.
> 
> It's hard to tell whether there are targets which actually have
> slow *WORD* accesses, where it may be preferable to use narrow
> accesses for bitfields.  If this is the case (maybe an old 8-bit
> target?) then we should consider improving the narrow_volatile_bitfield
> callback. That way you could pass the size/alignment/volatile and
> decide per bitfield access.
> 
> What do people think?
This just looks wrong to me.  You're going to end up pessimizing those
ports where sub-word access is cheaper than full word access.  This is
fairly common in ciscy processors.

ISTM the better approach is to fix the documentation to be clear then
review the ports to verify their definition makes sense.

Which ports did you think were incorrect?  I've familiar with a lot of
them so I can probably help confirm one way or the other.



Jeff


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]