[all-commits] [llvm/llvm-project] 9a5a9a: [MLIR][Remark] Import LLVM optimization remarks in...

Guray Ozen via All-commits all-commits at lists.llvm.org
Wed Sep 9 05:27:25 PDT 2026


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: 9a5a9a8a59bbfd0253ed005e231509de4436f2e8
      https://github.com/llvm/llvm-project/commit/9a5a9a8a59bbfd0253ed005e231509de4436f2e8
  Author: Guray Ozen <guray.ozen at gmail.com>
  Date:   2026-09-09 (Wed, 09 Sep 2026)

  Changed paths:
    M mlir/docs/Remarks.md
    A mlir/include/mlir/Remark/LLVMRemarkImport.h
    M mlir/include/mlir/Target/LLVM/ModuleToObject.h
    M mlir/lib/Remark/CMakeLists.txt
    A mlir/lib/Remark/LLVMRemarkImport.cpp
    M mlir/lib/Target/LLVM/CMakeLists.txt
    M mlir/lib/Target/LLVM/ModuleToObject.cpp
    A mlir/test/Dialect/GPU/module-to-binary-nvvm-remarks.mlir
    M mlir/unittests/CMakeLists.txt
    A mlir/unittests/Remark/CMakeLists.txt
    A mlir/unittests/Remark/LLVMRemarkImportTest.cpp
    M mlir/unittests/Target/LLVM/SerializeNVVMTarget.cpp

  Log Message:
  -----------
  [MLIR][Remark] Import LLVM optimization remarks into the remark engine (#222300)

Collect LLVM side of remarks with MLIR's remark infra.

LLVM passes emit their own [optimization
remarks](https://llvm.org/docs/Remarks.html) and MLIR has own. This PR
bridges MLIR and LLVM remarks.

`ModuleToObject` installs a `remark::LLVMToMLIRDiagnosticHandler` on the
`llvm::LLVMContext` it compiles with, which imports these remarks into
the remark engine: the category is the LLVM pass name prefixed with
`llvm-`, the LLVM remark name becomes the name, the message is stored
under the `Remark` argument and the structured LLVM arguments are copied
as metrics. The remark filters therefore select LLVM remarks by pass
name, and `llvm-.*` selects all of them.

Assisted by Claude Fable 5.1

---------

Co-authored-by: Claude Fable 5.1 <noreply at anthropic.com>



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