Files
clang-p2996/mlir/lib/Conversion/LLVMCommon/Pattern.cpp
Matthias Springer 6937dbbe51 [mlir][memref] Fix alloca lowering with 0 dimensions (#111119)
The `memref.alloca` lowering computed the allocation size incorrectly
when there were 0 dimensions.

Previously:
```
memref.alloca() : memref<10x0x2xf32>
--> llvm.alloca 20xf32
```

Now:
```
memref.alloca() : memref<10x0x2xf32>
--> llvm.alloca 0xf32
```

From the `llvm.alloca` documentation:
```
Allocating zero bytes is legal, but the returned pointer may not be unique.
```
2024-10-04 17:32:31 +02:00

15 KiB