summaryrefslogtreecommitdiffstats
path: root/lldb/packages/Python/lldbsuite/test/lang/cpp/scope/main.cpp
diff options
context:
space:
mode:
authorUlrich Weigand <ulrich.weigand@de.ibm.com>2019-02-06 15:10:13 +0000
committerUlrich Weigand <ulrich.weigand@de.ibm.com>2019-02-06 15:10:13 +0000
commit17a00126872438ad1d3f9dec09a50895beb011cb (patch)
tree4d42f1bc1ba3d6c4f10599b314545d51458d5d2a /lldb/packages/Python/lldbsuite/test/lang/cpp/scope/main.cpp
parent71025a2f3e113dbc90c8c303277695809c4ae466 (diff)
downloadbcm5719-llvm-17a00126872438ad1d3f9dec09a50895beb011cb.tar.gz
bcm5719-llvm-17a00126872438ad1d3f9dec09a50895beb011cb.zip
[SystemZ] Do not return INT_MIN from strcmp/memcmp
The IPM sequence currently generated to compute the strcmp/memcmp result will return INT_MIN for the "less than zero" case. While this is in compliance with the standard, strictly speaking, it turns out that common applications cannot handle this, e.g. because they negate a comparison result in order to implement reverse compares. This patch changes code to use a different sequence that will result in -2 for the "less than zero" case (same as GCC). However, this requires that the two source operands of the compare instructions are inverted, which breaks the optimization in removeIPMBasedCompare. Therefore, I've removed this (and all of optimizeCompareInstr), and replaced it with a mostly equivalent optimization in combineCCMask at the DAGcombine level. llvm-svn: 353304
Diffstat (limited to 'lldb/packages/Python/lldbsuite/test/lang/cpp/scope/main.cpp')
0 files changed, 0 insertions, 0 deletions
OpenPOWER on IntegriCloud