[PATCH] An llvm.noalias intrinsic

Daniel Berlin dberlin at dberlin.org
Tue May 12 13:00:41 PDT 2015


This looks 100% reasonable to me otherwise ;)


================
Comment at: docs/LangRef.rst:10343
@@ +10342,3 @@
+return value don't alias with those used by memory accesses tagged with
+associated ``noalias`` metadata.
+
----------------
This wording is a little odd.
I realize you are trying to say something about other pointers, but this intrinsic is really saying something about the accesses with the right metadata, not about their pointers.
(unless there's something i missed, and the fact that a pointer has the right noalias data in one access also implies something about that pointer when used in an access *not* in the right scope)


So i would say "llvm.noalias allows the assume that accesses using pointers derived from the return value don't alias with those accesses tagged with associated noalias scopes"
or something

You also need to very carefully define "derived".
Derived could mean a lot of things (IE if i ptrtoint it, add 6, and intoptr it, is it still derived?)




================
Comment at: docs/LangRef.rst:10363
@@ +10362,3 @@
+return value don't alias with those used by memory accesses tagged with
+``noalias`` metadata with compatible scopes. See the description of
+``alias.scope`` and ``noalias`` metadata for more information. The aliasing
----------------
Similar wording issue
You probably mean:
``llvm.noalias`` allows the optimizer to assume that memory accesses using pointers derived from the
return value don't alias with  memory accesses tagged with
``noalias`` metadata with compatible scopes.

http://reviews.llvm.org/D9375

EMAIL PREFERENCES
  http://reviews.llvm.org/settings/panel/emailpreferences/






More information about the llvm-commits mailing list