summaryrefslogtreecommitdiff
path: root/llvm/lib/Bitcode/Reader/BitcodeReader.cpp
diff options
context:
space:
mode:
authorSimon Pilgrim <llvm-dev@redking.me.uk>2024-06-09 11:30:05 +0100
committerGitHub <noreply@github.com>2024-06-09 11:30:05 +0100
commit53fecef1ec5cb502900f82b07036b28cb0fb9f0f (patch)
treef78bb32654e9d3cc4ca31481ed6ce34de2e2aef2 /llvm/lib/Bitcode/Reader/BitcodeReader.cpp
parent46d94bd0ad0c22a686ea71f6e7d0494f74c22f1a (diff)
[DAG] FoldConstantArithmetic - allow binop folding to work with differing bitcasted constants (#94863)
We currently only constant fold binop(bitcast(c1),bitcast(c2)) if c1 and c2 are both bitcasted and from the same type. This patch relaxes this assumption to allow the constant build vector to originate from different types (and allow cases where only one operand was bitcasted). We still ensure we bitcast back to one of the original types if both operand were bitcasted (we assume that if we have a non-bitcasted constant then its legal to keep using that type).
Diffstat (limited to 'llvm/lib/Bitcode/Reader/BitcodeReader.cpp')
0 files changed, 0 insertions, 0 deletions