..., reimplement DenseMapInfo<mlir::Identifier>::getHashValue in terms of mlir::hash_value(Identifier).
Both of these improvements were suggested by River, thanks!
Paths
| Differential D77999
Reimplement mlir::Identifier to be a wrapper around 'StringMapEntry*' instead of a wrapper around a 'const char*'. This makes it so strref() can be computed without calling strlen, which is more efficient and less error-prone. While here... ClosedPublic Authored by lattner on Apr 12 2020, 10:15 PM.
Details Summary ..., reimplement DenseMapInfo<mlir::Identifier>::getHashValue in terms of mlir::hash_value(Identifier). Both of these improvements were suggested by River, thanks!
Diff Detail
Event TimelineComment Actions Thanks, looks much better now.
This revision is now accepted and ready to land.Apr 12 2020, 10:41 PM lattner added inline comments.
Closed by commit rGd63036c0efd2: Reimplement mlir::Identifier to be a wrapper around 'StringMapEntry*' instead… (authored by lattner). · Explain WhyApr 13 2020, 10:47 AM This revision was automatically updated to reflect the committed changes.
Revision Contents
Diff 256995 mlir/include/mlir/IR/Identifier.h
mlir/lib/IR/MLIRContext.cpp
|
Can you also fix these while you are at it? These should really just be inline operators that compare the entry.