[PATCH] Implement low-level ARM ldrex/strex intrinsics

Tim Northover t.p.northover at gmail.com
Mon Jul 15 04:22:59 PDT 2013


Hi,

Thanks for your comments Eli, JF and Manish, I think I've implemented
almost all of them in the updated patches.

I wasn't quite sure how strongly we wanted the AST to match reality
for builtins, so I inserted the qualifier cast anyway to be on the
safe side.

The one exception:

> > I really want about the most conservative interpretation possible. I
> > thought that was with no specifier (though admittedly only from the
> > vagueish documentation). In particular just reading and writing
> > argument memory is too weak, in my opinion. They shouldn't be
> > reordered with other ldrex/strex intrinsics even if LLVM can prove
> > that there's no overlap in the addresses.

> I'm interested in other's opinions on this too :)

I've checked the TableGen source, and the default if no modifiers are
specified is "ReadWriteMem", which is what I want. There also appears
to be no way to explicitly specify that explicitly, so I think the
current implementation is the best we can do.

Do these look reasonable?

Cheers.

Tim.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: ldrex-clang.diff
Type: application/octet-stream
Size: 25019 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20130715/cfb46684/attachment.obj>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: ldrex-llvm.diff
Type: application/octet-stream
Size: 19305 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20130715/cfb46684/attachment-0001.obj>


More information about the cfe-commits mailing list