[llvm] [LangRef/DataLayout] Spell out requirements for alignment values (PR #104705)
Nikita Popov via llvm-commits
llvm-commits at lists.llvm.org
Tue Aug 20 01:38:02 PDT 2024
================
@@ -3123,6 +3120,9 @@ as follows:
as :ref:`Non-Integral Pointer Type <nointptrtype>` s. The ``0``
address space cannot be specified as non-integral.
+Unless explicitly stated otherwise, on every specification that specifies
+an alignment, the value of the alignment must be in the range [1,2^16)
+and must be a power of two times the width of a byte.
----------------
nikic wrote:
```suggestion
and must be a power of two greater than the width of a byte.
```
Would be slightly clearer imho -- but preclude non-power-of-two bytes. Was potentially allowing those in the future the motivation for the chosen wording?
https://github.com/llvm/llvm-project/pull/104705
More information about the llvm-commits
mailing list