@@ -3295,7 +3295,8 @@ that is :ref:`based on <pointeraliasing>` the allocation value. If a pointer
32953295that is not based on the object tries to read or write to the object, it is
32963296undefined behavior.
32973297
3298- The following properties hold for all allocated objects:
3298+ The following properties hold for all allocated objects, otherwise the
3299+ behavior is undefined:
32993300
33003301- no allocated object may cross the unsigned address space boundary (including
33013302 the pointer after the end of the object),
@@ -11718,8 +11719,9 @@ For ``nuw`` (no unsigned wrap):
1171811719For ``inbounds`` all rules of the ``nusw`` attribute apply. Additionally,
1171911720if the ``getelementptr`` has any non-zero indices, the following rules apply:
1172011721
11721- * The base pointer has an *in bounds* address of the allocated object that it
11722- is :ref:`based <pointeraliasing>` on. This means that it points into that
11722+ * The base pointer has an *in bounds* address of the
11723+ :ref:`allocated object<allocatedobjects>` that it is
11724+ :ref:`based <pointeraliasing>` on. This means that it points into that
1172311725 allocated object, or to its end. Note that the object does not have to be
1172411726 live anymore; being in-bounds of a deallocated object is sufficient.
1172511727 * During the successive addition of offsets to the address, the resulting
@@ -11730,9 +11732,6 @@ Note that ``getelementptr`` with all-zero indices is always considered to be
1173011732As a corollary, the only pointer in bounds of the null pointer in the default
1173111733address space is the null pointer itself.
1173211734
11733- These rules are based on the assumption for
11734- :ref:`allocated object<allocatedobjects>`.
11735-
1173611735If ``inbounds`` is present on a ``getelementptr`` instruction, the ``nusw``
1173711736attribute will be automatically set as well. For this reason, the ``nusw``
1173811737will also not be printed in textual IR if ``inbounds`` is already present.
@@ -26468,7 +26467,7 @@ can belong to any address space.
2646826467Overview:
2646926468"""""""""
2647026469
26471- The '``llvm.invariant.end``' intrinsic specifies that the contents of a
26470+ The '``llvm.invariant.end``' intrinsic specifies that the contents of an
2647226471:ref:`allocated object<allocatedobjects>` are mutable.
2647326472
2647426473Arguments:
0 commit comments