[PATCH] D78850: Memory corruption issure for DenseStringElementsAttr
River Riddle via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Sat Apr 25 01:33:26 PDT 2020
This revision was automatically updated to reflect the committed changes.
Closed by commit rG72af0bf17609: Memory corruption issure for DenseStringElementsAttr (authored by rsuderman, committed by rriddle).
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D78850/new/
https://reviews.llvm.org/D78850
Files:
mlir/lib/IR/AttributeDetail.h
Index: mlir/lib/IR/AttributeDetail.h
===================================================================
--- mlir/lib/IR/AttributeDetail.h
+++ mlir/lib/IR/AttributeDetail.h
@@ -610,8 +610,8 @@
if (!firstElt.equals(data[i]))
return KeyTy(ty, data, llvm::hash_combine(hashVal, data.drop_front(i)));
- // Otherwise, this is a splat so just return the hash of the first element.
- return KeyTy(ty, {firstElt}, hashVal, /*isSplat=*/true);
+ // Otherwise, this is a splat.
+ return KeyTy(ty, data, hashVal, /*isSplat=*/true);
}
/// Hash the key for the storage.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D78850.260074.patch
Type: text/x-patch
Size: 594 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20200425/41fdae33/attachment.bin>
More information about the llvm-commits
mailing list