This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: PATCH: PR target/64200: CE: in decide_alg, at config/i386/i386.c:24510 with -mmemcpy-strategy=libcall:-1:align -minline-stringops-dynamically fails with -mcmodel=large -fpic
- From: Uros Bizjak <ubizjak at gmail dot com>
- To: "H.J. Lu" <hjl dot tools at gmail dot com>
- Cc: "gcc-patches at gcc dot gnu dot org" <gcc-patches at gcc dot gnu dot org>
- Date: Sat, 6 Dec 2014 09:35:33 +0100
- Subject: Re: PATCH: PR target/64200: CE: in decide_alg, at config/i386/i386.c:24510 with -mmemcpy-strategy=libcall:-1:align -minline-stringops-dynamically fails with -mcmodel=large -fpic
- Authentication-results: sourceware.org; auth=none
- References: <20141205204731 dot GA2656 at intel dot com>
On Fri, Dec 5, 2014 at 9:47 PM, H.J. Lu <hongjiu.lu@intel.com> wrote:
> GCC manual says:
>
> '-minline-stringops-dynamically'
> For string operations of unknown size, use run-time checks with
> inline code for small blocks and a library call for large blocks.
>
> we get
>
> Breakpoint 5, decide_alg (count=0, expected_size=-1, min_size=0,
> max_size=2147483647, memset=false, zero_memset=false,
> dynamic_check=0x7fffffffc924, noalign=0x7fffffffc923)
> at /export/gnu/import/git/gcc/gcc/config/i386/i386.c:24510
> 24510 if (TARGET_INLINE_STRINGOPS_DYNAMICALLY)
> (gdb) p alg
> $1 = libcall
> (gdb)
>
> libcall is a valid choice here for -minline-stringops-dynamically. This
> patch avoids assert "alg != libcall" for
> TARGET_INLINE_STRINGOPS_DYNAMICALLY. OK for trunk and 4.9 branch?
>
> 2014-12-05 H.J. Lu <hongjiu.lu@intel.com>
>
> PR target/64200
> * config/i386/i386.c (decide_alg): Don't assert "alg != libcall"
> for TARGET_INLINE_STRINGOPS_DYNAMICALLY.
>
> gcc/testsuite/
>
> 2014-12-05 H.J. Lu <hongjiu.lu@intel.com>
>
> PR target/64200
> * gcc.target/i386/memcpy-strategy-4.c: New test.
Looking at above option description, looks like a thinko in the code.
Patch is OK everywhere, but should bake a couple of days in the mainline.
Thanks,
Uros.