[all-commits] [llvm/llvm-project] 40740c: Fix crash when using when using --finalize-memref-...

Siddhesh Deodhar via All-commits all-commits at lists.llvm.org
Fri Nov 8 10:24:12 PST 2024


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: 40740c4494d971ce410e2051b8d3ea7bbe081c76
      https://github.com/llvm/llvm-project/commit/40740c4494d971ce410e2051b8d3ea7bbe081c76
  Author: Siddhesh Deodhar <153800103+siddhesh195 at users.noreply.github.com>
  Date:   2024-11-08 (Fri, 08 Nov 2024)

  Changed paths:
    M mlir/lib/Conversion/LLVMCommon/TypeConverter.cpp
    M mlir/lib/Conversion/MemRefToLLVM/AllocLikeConversion.cpp
    A mlir/test/Conversion/MemRefToLLVM/invalid-uint.mlir

  Log Message:
  -----------
  Fix crash when using when using --finalize-memref-to-llvm (#112433)

This patch fixes crash when attempting to convert uint to int address
space during finalize-memref-to-llvm by doing the following:

1. Add a check to verify that IntegerAttr is signed int before calling
IntegerAttr::getInt()
 2. Emit error when getMemRefAddressSpace returns a failure()

Closes  #111242

---------

Co-authored-by: Christian Ulmann <christianulmann at gmail.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