HomePhabricator

[SystemZ] Bugfix and improve the handling of CC values.

Authored by jonpa on Dec 17 2019, 10:14 AM.

Description

[SystemZ] Bugfix and improve the handling of CC values.

It was recently discovered that the handling of CC values was actually broken
since overflow was not properly handled ('nsw' flag not checked for).

Add and sub instructions now have a new target specific instruction flag
named SystemZII::CCIfNoSignedWrap. It means that the CC result can be used
instead of a compare with 0, but only if the instruction has the 'nsw' flag
set.

This patch also adds the improvements of conversion to logical instructions
and the analyzing of add with immediates, to be able to eliminate more
compares.

Review: Ulrich Weigand
https://reviews.llvm.org/D66868

Details

Committed
jonpaDec 20 2019, 10:20 AM
Parents
rG2ff5a596cbfd: Revert "[ARM] Improve codegen of volatile load/store of i64"
Branches
Unknown
Tags
Unknown