Index: llvm/docs/LangRef.rst =================================================================== --- llvm/docs/LangRef.rst +++ llvm/docs/LangRef.rst @@ -17340,64 +17340,6 @@ uses. It is not meant for general use, only for building temporary renaming forms that require value splits at certain points. -.. _int_noalias: - -'``llvm.noalias``' Intrinsic -^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ - -Syntax: -""""""" - -:: - - declare * @llvm.noalias.p
(* %ptr, metadata %scopes) - -Overview: -""""""""" - -``llvm.noalias`` allows the optimizer to assume that memory accesses using -pointers :ref:`based ` on the return value don't alias with -memory accesses, tagged with the provided ``noalias`` scope, using pointers not -derived from the return value. - -Arguments: -"""""""""" - -The first argument is the pointer on which the aliasing assumption is being -placed. This pointer value is returned, but parts of the optimizer ignore this -fact so that data dependencies on the return value will be maintained. The -aliasing assumptions apply only to uses of pointers -:ref:`based ` on the return value. - -The second argument is metadata that is a list of ``noalias`` metadata -references. The format is identical to that required for ``noalias`` metadata. -This list should have only one element. - -Semantics: -"""""""""" - -``llvm.noalias`` allows the optimizer to assume that memory accesses using -pointers :ref:`based ` on from the return value don't alias -with memory accesses, tagged with compatible ``noalias`` scopes (i.e. the scope -provided to the intrinsic must be one of the scopes with which the access is -tagged), using pointers not based on the return value. See the description of -``alias.scope`` and ``noalias`` metadata for more information. The aliasing -assumptions apply only to uses of pointers based on the return value, and -accesses using those pointers must themselves be tagged with ``noalias`` -metadata with compatible scopes. - -Unlike ``alias.scope`` metadata, which applies to only the access to which it -is attached, the ``llvm.noalias`` intrinsic applies to all pointers based on -from the return value. Placing an ``llvm.noalias`` intrinsic outside of a loop -provides a mechanism for communicating that certain memory accesses don't alias -with uses of a pointer in any loop iteration. This works only if the -``llvm.noalias`` intrinsic itself dominates the loop body. - -Note that the use of ``alias.scope`` metadata does not block potential -optimizations, as ``llvm.noalias`` might, and so use of ``alias.scope`` -metadata when possible is recommended. Nevertheless, no code is generated for -this intrinsic. - .. _type.test: '``llvm.type.test``' Intrinsic