Port-arm archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
Re: Inline asm constraint help
> On Jan 31, 2019, at 7:54 AM, Jason Thorpe <thorpej%me.com@localhost> wrote:
>
> No, I mean wN (32-bit) vs xN (64-bit) names of the general purpose registers. Specifically, I want to use ldxr and stxr to operate on “int *” memory locations. I know the syntax, just can’t get GCC to emit it :-/
>
> (Sorry, I just don’t have the GCC source handy right now... and it’s online docs don’t even mention the “x” modifier as far as I can tell, but I observed its behavior.)
To follow-up, I figured it out.
ldxr %0,%2
resulted in:
ldxr x2,[x0]
...and:
ldxr %w0,%2
...did what I want:
ldxr w2,[x0]
I had assumed I needed to use a constraint modifier, but I was obviously wrong :-)
-- thorpej
Home |
Main Index |
Thread Index |
Old Index