[mlir] do not emit bitcasts between structs in StandardToLLVM
The convresion of memref cast operaitons from the Standard dialect to the LLVM dialect has been emitting bitcasts from a struct type to itself. Beyond being useless, such casts are invalid as bitcast does not operate on aggregate types. This kept working by accident because LLVM IR bitcast construction API skips the construction if types are equal before it verifies that the types are acceptable in a bitcast. Do not emit such bitcasts, the memref cast that only adds/erases size information is in fact a noop on the current descriptor as it always contains dynamic values for all sizes. Reviewed By: pifon2a Differential Revision: https://reviews.llvm.org/D85899
Loading
Please sign in to comment