diff options
author | Jiufu Guo <guojiufu@linux.ibm.com> | 2022-12-19 16:40:01 +0800 |
---|---|---|
committer | Jiufu Guo <guojiufu@linux.ibm.com> | 2022-12-19 17:11:36 +0800 |
commit | 97a8e88cd7d22562c0ea4f73687d3c93c21e12fb (patch) | |
tree | 16e87c8c821f73f1d3d8c49c3452694f879b4e45 /contrib/gcc-changelog/git_commit.py | |
parent | 17b41a28396b748c1824d92ef431a7d39f48a051 (diff) | |
download | gcc-97a8e88cd7d22562c0ea4f73687d3c93c21e12fb.zip gcc-97a8e88cd7d22562c0ea4f73687d3c93c21e12fb.tar.gz gcc-97a8e88cd7d22562c0ea4f73687d3c93c21e12fb.tar.bz2 |
rs6000: use li;x?oris to build constant
For constant C:
If '(c & 0xFFFFFFFF00008000ULL) == 0xFFFFFFFF00008000ULL' or say:
32(1) || 16(x) || 1(1) || 15(x), using "li; xoris" would be ok.
If '(c & 0xFFFFFFFF80008000ULL) == 0x80000000ULL' or say:
32(0) || 1(1) || 15(x) || 1(0) || 15(x), we could use "li; oris" to
build constant 'C'.
Here N(M) means N continuous bit M, x for M means it is ok for either
1 or 0; '||' means concatenation.
This patch update rs6000_emit_set_long_const to support those constants.
PR target/106708
gcc/ChangeLog:
* config/rs6000/rs6000.cc (rs6000_emit_set_long_const): Add using
"li; x?oris" to build constant.
gcc/testsuite/ChangeLog:
* gcc.target/powerpc/pr106708.c: New test.
Diffstat (limited to 'contrib/gcc-changelog/git_commit.py')
0 files changed, 0 insertions, 0 deletions