Skip to content

Commit

Permalink
Actually don't need it?
Browse files Browse the repository at this point in the history
  • Loading branch information
lialan committed Jan 15, 2025
1 parent fe8befc commit 09316fa
Showing 1 changed file with 3 additions and 6 deletions.
9 changes: 3 additions & 6 deletions compiler/src/iree/compiler/Dialect/Stream/IR/StreamOps.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1513,12 +1513,9 @@ LogicalResult TensorCloneOp::verify() {
// information.
auto sourceEncoding = llvm::cast<RankedTensorType>(op.getSourceEncoding());
auto resultEncoding = llvm::cast<RankedTensorType>(op.getResultEncoding());
if (IREE::Encoding::hasPackedStorageAttr(sourceEncoding) !=
IREE::Encoding::hasPackedStorageAttr(resultEncoding)) {
return op.emitOpError()
<< "clones attribute #iree_encoding.packed_storage mismatch";
}
if (sourceEncoding.getEncoding() != resultEncoding.getEncoding()) {
if (sourceEncoding.getEncoding() != resultEncoding.getEncoding() &&
!IREE::Encoding::hasPackedStorageAttr(sourceEncoding) &&
!IREE::Encoding::hasPackedStorageAttr(resultEncoding)) {
return op.emitOpError() << "clones changing tensor encoding from "
<< sourceEncoding.getEncoding() << " to "
<< resultEncoding.getEncoding() << "; not allowed";
Expand Down

0 comments on commit 09316fa

Please sign in to comment.