S/390: arch13: Support new popcount instruction
authorAndreas Krebbel <krebbel@linux.ibm.com>
Tue, 2 Apr 2019 10:55:26 +0000 (10:55 +0000)
committerAndreas Krebbel <krebbel@gcc.gnu.org>
Tue, 2 Apr 2019 10:55:26 +0000 (10:55 +0000)
commit25cb5165c1e49499c8c6e0088d135bd54cb7106f
treee9416f449191262abe6ef419ee0110c2c281f7d9
parent4a9733f3dfbd016103a30151a9656ffb63dce6e4
S/390: arch13: Support new popcount instruction
 variant.

The new arch13 popcount instruction counts bits in the entire 64 bit
register instead of just in 8 bit portions.

gcc/ChangeLog:

2019-04-02  Andreas Krebbel  <krebbel@linux.ibm.com>

* config/s390/s390.md ("*popcountdi_arch13_cc")
("*popcountdi_arch13_cconly", "*popcountdi_arch13"): New insn
definition.
("*popcount<mode>", "popcountdi2", "popcountsi2", "popcounthi2"):
Append _z196 to make it ...
("*popcount<mode>_z196", "popcountdi2_z196", "popcountsi2_z196")
("popcounthi2_z196"): ... this.
("popcountdi2_z196"): Remove TARGET_64BIT from the insn condition.
("popcountdi2", "popcountsi2", "popcounthi2"): New expanders.

gcc/testsuite/ChangeLog:

2019-04-02  Andreas Krebbel  <krebbel@linux.ibm.com>

* gcc.target/s390/arch13/popcount-1.c: New test.

From-SVN: r270079
gcc/ChangeLog
gcc/config/s390/s390.md
gcc/testsuite/ChangeLog
gcc/testsuite/gcc.target/s390/arch13/popcount-1.c [new file with mode: 0644]