[all-commits] [llvm/llvm-project] 9d0b59: [mlir][tosa] Fix segmentation fault in case of fol...

Kai Sasaki via All-commits all-commits at lists.llvm.org
Mon Feb 13 13:13:57 PST 2023


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: 9d0b596aada6fb2166dd4f6f58e359fbac483154
      https://github.com/llvm/llvm-project/commit/9d0b596aada6fb2166dd4f6f58e359fbac483154
  Author: Kai Sasaki <lewuathe at gmail.com>
  Date:   2023-02-13 (Mon, 13 Feb 2023)

  Changed paths:
    M mlir/lib/Dialect/Tosa/IR/TosaCanonicalizations.cpp
    M mlir/test/Dialect/Tosa/constant_folding.mlir

  Log Message:
  -----------
  [mlir][tosa] Fix segmentation fault in case of folding unranked tensor

Trying to fold the unranked tensor for "tosa.equal" crashes due to null reference.
We need to check the dynamic cast result beforehand. This is reported in
https://github.com/llvm/llvm-project/issues/60192.

Reviewed By: rsuderman

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




More information about the All-commits mailing list