This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: [PATCH, SH] Add support for inlined builtin-strcmp (2/2)
- From: Kaz Kojima <kkojima at rr dot iij4u dot or dot jp>
- To: christian dot bruel at st dot com
- Cc: oleg dot endo at t-online dot de, gcc-patches at gcc dot gnu dot org
- Date: Mon, 21 Oct 2013 07:31:49 +0900 (JST)
- Subject: Re: [PATCH, SH] Add support for inlined builtin-strcmp (2/2)
- Authentication-results: sourceware.org; auth=none
- References: <5260EA68 dot 9080603 at st dot com> <1382175042 dot 2445 dot 84 dot camel at yam-132-YW-E178-FTW> <5263CB72 dot 1040108 at st dot com>
Christian Bruel <christian.bruel@st.com> wrote:
> thanks for having retested this, The tests are still not complete for
> RTL generated functions, there are cases where no str/cmp wil be
> emitted, because we can predict than the size is less than 4 and so have
> a direct fallthru into the byte at a byte loop copying.
>
> Also I will consider a size optimized implementation, so we don't jump
> to the library
>
> I will post examples for this shortly (and add them as a testcase) with
> a strncmp implementation helper, that pertains to strcmp with constant
> strings by the way. Please allow me some time to complete by benchmarking.
>
> thanks for the hints about removing empty "" is the expanders
>
> Kaz, before proceeding with the next patch, was your approval for 1/2
> only or 2/2 with the expander cleanup ?
Only for 1/2. The revised 2/2 patch is pre-approved if the usual
tests are Ok, though. One minor formatting problem:
>+ if (! optimize_insn_for_size_p () && sh4_expand_cmpstr(operands))
>+ DONE;
A space is needed just before (operands).
Regards,
kaz