[all-commits] [llvm/llvm-project] eb7025: [LangRef/DataLayout] Spell out requirements for al...

Sergei Barannikov via All-commits all-commits at lists.llvm.org
Sun Apr 6 10:09:15 PDT 2025


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: eb70253fcbe57c7cb3c309c06b94b05f2eab314d
      https://github.com/llvm/llvm-project/commit/eb70253fcbe57c7cb3c309c06b94b05f2eab314d
  Author: Sergei Barannikov <barannikov88 at gmail.com>
  Date:   2025-04-06 (Sun, 06 Apr 2025)

  Changed paths:
    M llvm/docs/LangRef.rst

  Log Message:
  -----------
  [LangRef/DataLayout] Spell out requirements for alignment values (#104705)

For 'p' the added wording matches the implementation.

For 'i', 'f', 'v' the implementation also allows 0 for `<pref>`
component, making 'i16:16:0' valid, for example. 'Fi0', 'Fn0' and 'S0'
are also currently accepted. This is likely unintentional. There are no
tests in the codebase that rely on this behavior, so the added wording
prohibits zero alignments for these specifications.

For 'a', the implementation currently allows 0 for both `<abi>` and
`<pref>` components. The added wording prohibits specifying zero for
`<pref>` with the same justification as above. Zero `<abi>` is used in
tests, and the example at the end of the section suggests that this is
valid, so that's left unchanged.

This effectively prohibits zero alignments everywhere except for the
`<abi>` component of aggregate specification.



To unsubscribe from these emails, change your notification settings at https://github.com/llvm/llvm-project/settings/notifications


More information about the All-commits mailing list