From: Vineet Gupta <vineetg@rivosinc.com>
To: Jeff Law <jeffreyalaw@gmail.com>,
Palmer Dabbelt <palmer@rivosinc.com>,
gcc-patches@gcc.gnu.org, Patrick O'Neill <patrick@rivosinc.com>
Subject: Re: [committed][RISC-V] Remove errant hunk of code
Date: Thu, 3 Aug 2023 16:38:43 -0700 [thread overview]
Message-ID: <940aabf0-6d96-505a-69ea-7ead5eb792f1@rivosinc.com> (raw)
In-Reply-To: <d32a4fb7-691f-e304-453a-fe79b0f2c49c@gmail.com>
On 8/3/23 16:15, Jeff Law wrote:
>
>
> On 8/3/23 16:26, Vineet Gupta wrote:
>>
>> As discussed in Tue call, I definitely have 1 fix to riscv_rtx_costs
>> (), which is worth pondering. It adjusts the cost of consts and helps
>> Hoist GCSE constants (which granted kicks in only at -Os). However it
>> does affect codegen in subtle ways since CSE1 now for some cases
>> generates additional REG_EQUAL note.
> Yea, we'll definitely want to take a look. It's not likely affecting
> my work, but definitely want to evaluate as part of the overall
> costing question.
OK, I'll spin it and post to the list after a testsuite run.
>
>
>>
>> On a different but slightly related note, I was playing with Zicond
>> this morning (enabling by default in toolchain build and qemu) and I
>> was surprised to see that glibc build currently doesn't have a single
>> czero* insn - although gcc has bene configured with
> Probably costing ;-) That little hunk that snuck through is part of
> how I arrange to get more czero instructions when running the GCC
> testsuite.
>
> Also note that if you're disassembling with binutils, I think it just
> dumps it out as a .word or something similar.
Yeah something was off, I was building /using the latest binutils but
then my fancy over-engineered objdump helper was pointing to an a
non-zicond binutils :-)
>
>>
>> Point being, I can help with riscv_rtx_costs and friends, if you have
>> something specific, but seems like you are in the thick of it and
>> have that handled so I'll stay out of the way and refrain from zicond
>> work/testing for the time being.
> ;-) Actually if you wanted to poke at zicond, the most interesting
> unexplored area I've come across is the COND_EXPR handling in gimple.
> When we expand a COND_EXPR into RTL the first approach we take is to
> try mov<mode>cc in RTL.
>
> Unfortunately we don't create COND_EXPRs all that often in gimple.
> Some simple match.pd patterns would likely really help here.
>
> The problem is RTL expansion when mov<mode>cc FAILs is usually poor at
> best. So if we're going to add those match.pd patterns, we probably
> need to beef up the RTL expansion code to do a better job when the
> target doesn't have a mov<mode>cc RTL pattern.
Ok, I'll add that to my todo list.
Thx,
-Vineet
next prev parent reply other threads:[~2023-08-03 23:38 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-08-03 15:05 Jeff Law
2023-08-03 17:41 ` Palmer Dabbelt
2023-08-03 18:12 ` Jeff Law
2023-08-03 22:26 ` Vineet Gupta
2023-08-03 23:15 ` Jeff Law
2023-08-03 23:38 ` Vineet Gupta [this message]
2023-08-04 5:31 ` Jeff Law
2023-08-04 19:08 ` Andrew Pinski
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=940aabf0-6d96-505a-69ea-7ead5eb792f1@rivosinc.com \
--to=vineetg@rivosinc.com \
--cc=gcc-patches@gcc.gnu.org \
--cc=jeffreyalaw@gmail.com \
--cc=palmer@rivosinc.com \
--cc=patrick@rivosinc.com \
/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: link
Be 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).