public inbox for gcc-bugs@sourceware.org help / color / mirror / Atom feed
From: "ubizjak at gmail dot com" <gcc-bugzilla@gcc.gnu.org> To: gcc-bugs@gcc.gnu.org Subject: [Bug target/102811] New: vcvtph2ps and vcvtps2ph should be used to convert _Float16 to SFmode with -mf16c Date: Mon, 18 Oct 2021 10:58:52 +0000 [thread overview] Message-ID: <bug-102811-4@http.gcc.gnu.org/bugzilla/> (raw) https://gcc.gnu.org/bugzilla/show_bug.cgi?id=102811 Bug ID: 102811 Summary: vcvtph2ps and vcvtps2ph should be used to convert _Float16 to SFmode with -mf16c Product: gcc Version: 12.0 Status: UNCONFIRMED Severity: normal Priority: P3 Component: target Assignee: unassigned at gcc dot gnu.org Reporter: ubizjak at gmail dot com Target Milestone: --- The following testcase: _Float16 test (_Float16 a, _Float16 b) { return a + b; } compiles with -O2 -mf16c to: --cut here-- subq $24, %rsp pextrw $0, %xmm1, 14(%rsp) call __extendhfsf2 pinsrw $0, 14(%rsp), %xmm1 vmovss %xmm0, 8(%rsp) vmovss %xmm1, %xmm1, %xmm0 call __extendhfsf2 vaddss 8(%rsp), %xmm0, %xmm0 call __truncsfhf2 addq $24, %rsp ret --cut here-- Instead of calling __extendhfsf2 and __truncsfhf2, we should use vcvtph2ps and vcvtps2ph (with zeroed elements 1..3) for -m16c targets.
next reply other threads:[~2021-10-18 10:58 UTC|newest] Thread overview: 28+ messages / expand[flat|nested] mbox.gz Atom feed top 2021-10-18 10:58 ubizjak at gmail dot com [this message] 2021-10-18 11:17 ` [Bug target/102811] " ubizjak at gmail dot com 2021-10-18 11:31 ` ubizjak at gmail dot com 2021-10-18 21:20 ` pinskia at gcc dot gnu.org 2021-11-26 1:30 ` cvs-commit at gcc dot gnu.org 2021-11-26 1:32 ` crazylht at gmail dot com 2021-11-26 1:48 ` pinskia at gcc dot gnu.org 2021-11-26 10:41 ` ubizjak at gmail dot com 2021-11-26 10:48 ` ubizjak at gmail dot com 2021-11-26 11:12 ` ubizjak at gmail dot com 2021-11-26 12:27 ` crazylht at gmail dot com 2021-11-26 13:01 ` ubizjak at gmail dot com 2021-11-26 13:28 ` crazylht at gmail dot com 2021-11-26 13:34 ` crazylht at gmail dot com 2021-11-26 13:46 ` ubizjak at gmail dot com 2021-11-26 15:22 ` crazylht at gmail dot com 2021-11-26 16:00 ` ubizjak at gmail dot com 2021-11-26 16:29 ` crazylht at gmail dot com 2021-11-26 16:49 ` ubizjak at gmail dot com 2021-11-26 16:57 ` ubizjak at gmail dot com 2021-11-29 2:50 ` crazylht at gmail dot com 2021-11-29 3:22 ` crazylht at gmail dot com 2021-11-29 8:03 ` ubizjak at gmail dot com 2021-11-29 9:46 ` cvs-commit at gcc dot gnu.org 2021-11-29 9:46 ` cvs-commit at gcc dot gnu.org 2021-11-29 21:17 ` cvs-commit at gcc dot gnu.org 2021-12-01 22:05 ` cvs-commit at gcc dot gnu.org 2021-12-01 22:15 ` ubizjak at gmail dot com
Reply instructions: You may reply publicly to this message via plain-text email using any one of the following methods: * Save the following mbox file, import it into your mail client, and reply-to-all from there: mbox Avoid top-posting and favor interleaved quoting: https://en.wikipedia.org/wiki/Posting_style#Interleaved_style * Reply using the --to, --cc, and --in-reply-to switches of git-send-email(1): git send-email \ --in-reply-to=bug-102811-4@http.gcc.gnu.org/bugzilla/ \ --to=gcc-bugzilla@gcc.gnu.org \ --cc=gcc-bugs@gcc.gnu.org \ /path/to/YOUR_REPLY https://kernel.org/pub/software/scm/git/docs/git-send-email.html * If your mail client supports setting the In-Reply-To header via mailto: links, try the mailto: linkBe sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox; as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).