[all-commits] [llvm/llvm-project] 3df71e: [mlir][LLVM] Use int32_t to indirectly construct G...
Andrei Golubev via All-commits
all-commits at lists.llvm.org
Mon Jan 29 10:31:54 PST 2024
Branch: refs/heads/release/18.x
Home: https://github.com/llvm/llvm-project
Commit: 3df71e5a3f5d5fb9436c53c298e5426f729288e2
https://github.com/llvm/llvm-project/commit/3df71e5a3f5d5fb9436c53c298e5426f729288e2
Author: Andrei Golubev <andrey.golubev at intel.com>
Date: 2024-01-29 (Mon, 29 Jan 2024)
Changed paths:
M mlir/lib/Conversion/GPUCommon/GPUOpsLowering.cpp
M mlir/lib/Conversion/GPUCommon/GPUToLLVMConversion.cpp
M mlir/lib/Dialect/LLVMIR/Transforms/TypeConsistency.cpp
Log Message:
-----------
[mlir][LLVM] Use int32_t to indirectly construct GEPArg (#79562)
GEPArg can only be constructed from int32_t and mlir::Value. Explicitly
cast other types (e.g. unsigned, size_t) to int32_t to avoid narrowing
conversion warnings on MSVC. Some recent examples of such are:
```
mlir\lib\Dialect\LLVMIR\Transforms\TypeConsistency.cpp: error C2398:
Element '1': conversion from 'size_t' to 'T' requires a narrowing
conversion
with
[
T=mlir::LLVM::GEPArg
]
mlir\lib\Dialect\LLVMIR\Transforms\TypeConsistency.cpp: error C2398:
Element '1': conversion from 'unsigned int' to 'T' requires a narrowing
conversion
with
[
T=mlir::LLVM::GEPArg
]
```
Co-authored-by: Nikita Kudriavtsev <nikita.kudriavtsev at intel.com>
(cherry picked from commit 89cd345667a5f8f4c37c621fd8abe8d84e85c050)
More information about the All-commits
mailing list