[all-commits] [llvm/llvm-project] d25e91: Support alias.scope and noalias metadata

Tyler Augustine via All-commits all-commits at lists.llvm.org
Tue Aug 24 11:43:15 PDT 2021


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: d25e91d7f61acc9f6fdfa908a45f9127fe4f13a2
      https://github.com/llvm/llvm-project/commit/d25e91d7f61acc9f6fdfa908a45f9127fe4f13a2
  Author: Tyler Augustine <taugustine at google.com>
  Date:   2021-08-24 (Tue, 24 Aug 2021)

  Changed paths:
    M mlir/include/mlir/Dialect/LLVMIR/LLVMOpBase.td
    M mlir/include/mlir/Dialect/LLVMIR/LLVMOps.td
    M mlir/include/mlir/Target/LLVMIR/ModuleTranslation.h
    M mlir/lib/Dialect/LLVMIR/IR/LLVMDialect.cpp
    M mlir/lib/Target/LLVMIR/ModuleTranslation.cpp
    M mlir/test/Dialect/LLVMIR/invalid.mlir
    M mlir/test/Target/LLVMIR/llvmir.mlir

  Log Message:
  -----------
  Support alias.scope and noalias metadata

Introduces new Ops to represent 1. alias.scope metadata in LLVM, and 2. domains for these scopes. These correspond to the metadata described in https://llvm.org/docs/LangRef.html#noalias-and-alias-scope-metadata. Lists of scopes are modeled the same way as access groups - as an ArrayAttr on the Op (added in https://reviews.llvm.org/D97944).

Lowering 'noalias' attributes on function parameters is already supported. However, lowering `noalias` metadata on individual Ops is not, which is added in this change. LLVM uses the same keyword for these, but this change introduces a separate attribute name 'noalias_scopes' to represent this distinct concept.

Reviewed By: mehdi_amini

Differential Revision: https://reviews.llvm.org/D107870




More information about the All-commits mailing list