This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug target/79799] New: Improve vec_insert of float on Power9
- From: "meissner at gcc dot gnu.org" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: Thu, 02 Mar 2017 00:41:16 +0000
- Subject: [Bug target/79799] New: Improve vec_insert of float on Power9
- Auto-submitted: auto-generated
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=79799
Bug ID: 79799
Summary: Improve vec_insert of float on Power9
Product: gcc
Version: 7.0.1
Status: UNCONFIRMED
Severity: normal
Priority: P3
Component: target
Assignee: unassigned at gcc dot gnu.org
Reporter: meissner at gcc dot gnu.org
Target Milestone: ---
At the moment, we do not have special code on power9 to have vec_insert of
single precision floating point.
So for:
vector float insert_0 (vector float vf, float f) { return vec_insert (f, vf,
0); }
we currently generate:
insert_0:
.LCF2:
0: addis 2,12,.TOC.-.LCF2@ha
addi 2,2,.TOC.-.LCF2@l
.localentry insert_0,.-insert_0
addis 9,2,.LC0@toc@ha
addi 10,1,-16
stfs 1,-16(1)
addi 9,9,.LC0@toc@l
lvewx 0,0,10
lxv 33,0(9)
vpermr 2,0,2,1
blr
.section .rodata.cst16,"aM",@progbits,16
.align 4
.LC0:
.byte 16
.byte 17
.byte 18
.byte 19
.byte 4
.byte 5
.byte 6
.byte 7
.byte 8
.byte 9
.byte 10
.byte 11
.byte 12
.byte 13
.byte 14
.byte 15
Instead we should generate a convert to XSCVDPSPN, right shift 32-bits, and
XXINSERTW.