summaryrefslogtreecommitdiffstats
path: root/clang/lib/AST/Decl.cpp
diff options
context:
space:
mode:
authorSanjay Patel <spatel@rotateright.com>2017-12-26 15:09:19 +0000
committerSanjay Patel <spatel@rotateright.com>2017-12-26 15:09:19 +0000
commit9a39979dd2d430a6c964716582abeac597d6b2a3 (patch)
tree7668ac6dc7c7278e0951c3b4630e682a39c99248 /clang/lib/AST/Decl.cpp
parent628f63e5fd2143466c87f88ebbbfadca0ad3b1d9 (diff)
downloadbcm5719-llvm-9a39979dd2d430a6c964716582abeac597d6b2a3.tar.gz
bcm5719-llvm-9a39979dd2d430a6c964716582abeac597d6b2a3.zip
[ValueTracking] ignore FP signed-zero when detecting a casted-to-integer fmin/fmax pattern
This is a preliminary step for the patch discussed in D41136 (and denoted here with the FIXME comment). When we match an FP min/max that is cast to integer, any intermediate difference between +0.0 or -0.0 should be muted in the result by the conversion (either fptosi or fptoui) of the result. Thus, we can enable 'nsz' for the purpose of matching fmin/fmax. Note that there's probably room to generalize this more, possibly by fixing the current calls to the weak version of isKnownNonZero() in matchSelectPattern() to the more powerful recursive version. Differential Revision: https://reviews.llvm.org/D41333 llvm-svn: 321456
Diffstat (limited to 'clang/lib/AST/Decl.cpp')
0 files changed, 0 insertions, 0 deletions
OpenPOWER on IntegriCloud