Do so by extending matchUnaryPredicate to also work for
ConstantFPSDNode types then encapsulate the constant checks in a
lambda and pass it to matchUnaryPredicate.
Details
Diff Detail
- Repository
- rG LLVM Github Monorepo
Event Timeline
llvm/include/llvm/CodeGen/SelectionDAGNodes.h | ||
---|---|---|
3130–3131 | I've never understood why ConstantSDNode isn't a common base to a ConstantInt and ConstantFPNode I think you'd be better off just making this SDNode* and letting the implementation dyn_cast |
llvm/include/llvm/CodeGen/SelectionDAGNodes.h | ||
---|---|---|
3136 | Why not just add a matchUnaryFpPredicate variant? |
llvm/include/llvm/CodeGen/SelectionDAGNodes.h | ||
---|---|---|
3136 | Really? Seems to me to be simpler to do node -> wrapper -> final. At this point adding any new constant type is just adding a new wrapper + adding isa type in anynode. Imo cleaner like this but if you feel strongly Ill change. |
an -> a