[Bug middle-end/20396] TRULY_NOOP_TRUNCATION ignored
--- Additional Comments From cvs-commit at gcc dot gnu dot org 2005-08-16 11:57 --- Subject: Bug 20396 CVSROOT:/cvs/gcc Module name:gcc Changes by: [EMAIL PROTECTED] 2005-08-16 11:57:08 Modified files: gcc: ChangeLog optabs.c Log message: 2005-08-16 Jorn Rennecke [EMAIL PROTECTED] Richard Shann [EMAIL PROTECTED] PR middle-end/20396: * optabs.c (expand_binop): Take TRULY_NOOP_TRUNCATION into account. Patches: http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/ChangeLog.diff?cvsroot=gccr1=2.9742r2=2.9743 http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/optabs.c.diff?cvsroot=gccr1=1.288r2=1.289 -- http://gcc.gnu.org/bugzilla/show_bug.cgi?id=20396
[Bug middle-end/20396] TRULY_NOOP_TRUNCATION ignored
--- Additional Comments From pinskia at gcc dot gnu dot org 2005-08-16 12:09 --- Fixed. -- What|Removed |Added Status|NEW |RESOLVED Resolution||FIXED Target Milestone|--- |4.1.0 http://gcc.gnu.org/bugzilla/show_bug.cgi?id=20396
[Bug middle-end/20396] TRULY_NOOP_TRUNCATION ignored
--- Additional Comments From pinskia at gcc dot gnu dot org 2005-07-31 02:38 --- Confirmed. -- What|Removed |Added URL||http://gcc.gnu.org/ml/gcc- ||patches/2005- ||04/msg00883.html Status|UNCONFIRMED |NEW Ever Confirmed||1 Last reconfirmed|-00-00 00:00:00 |2005-07-31 02:38:26 date|| http://gcc.gnu.org/bugzilla/show_bug.cgi?id=20396
[Bug middle-end/20396] TRULY_NOOP_TRUNCATION ignored
--- Additional Comments From cvs-commit at gcc dot gnu dot org 2005-07-12 13:40 --- Subject: Bug 20396 CVSROOT:/cvs/gcc Module name:gcc Branch: sh-elf-4_1-branch Changes by: [EMAIL PROTECTED] 2005-07-12 13:40:25 Modified files: gcc: ChangeLog Log message: Add patchg URL for PR middle-end/20396. Patches: http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/ChangeLog.diff?cvsroot=gcconly_with_tag=sh-elf-4_1-branchr1=2.8142.2.18r2=2.8142.2.19 -- http://gcc.gnu.org/bugzilla/show_bug.cgi?id=20396
[Bug middle-end/20396] TRULY_NOOP_TRUNCATION ignored
-- What|Removed |Added OtherBugsDependingO||20695 nThis|| http://gcc.gnu.org/bugzilla/show_bug.cgi?id=20396
[Bug middle-end/20396] TRULY_NOOP_TRUNCATION ignored
-- What|Removed |Added OtherBugsDependingO|17652 | nThis|| http://gcc.gnu.org/bugzilla/show_bug.cgi?id=20396
[Bug middle-end/20396] TRULY_NOOP_TRUNCATION ignored
--- Additional Comments From joern dot rennecke at st dot com 2005-04-11 12:36 --- Subject: Re: TRULY_NOOP_TRUNCATION ignored echristo at redhat dot com wrote: --- Additional Comments From echristo at redhat dot com 2005-04-10 19:02 --- I think I'm ok with this, but I'd like a bit more info. What changes to the backend do you forsee this needing? The one patch that you applied to the 4.1 sh branch was too big to just get that particular set of changes. [assuming you are talking about generating TRUNCATE in gen_lowpart_common] First. some source operands will have a TRUNCATE, and if your expander tries to make all operands fit, or thinks it knows all the codes that can occur in some position, it will have to be updated to cope with the TRUNCATE. This is unfortunately also true for destination operands. Also, when you use gen_lowpart for a non-TRULY_NOOP_TRUNCATION mode pair, in a splitter or a peephole, for a destination, or for an operand where due to the nature of the operation or the register class being used a SUBREG is desired, you will still get a TRUNCATE; you have to use simplyfy_gen_subreg to explicitly get a SUBREG. The splitter with the for_each_rtx application of shmedia_cleanup_truncate cleans up such stuff after reload. -- http://gcc.gnu.org/bugzilla/show_bug.cgi?id=20396
[Bug middle-end/20396] TRULY_NOOP_TRUNCATION ignored
--- Additional Comments From echristo at redhat dot com 2005-04-11 19:54 --- OK. I'm willing to fix up the mips backend for this if you hand me the patch ahead of time (and it's accepted as a good idea by the middle-end maintainers). -- http://gcc.gnu.org/bugzilla/show_bug.cgi?id=20396
[Bug middle-end/20396] TRULY_NOOP_TRUNCATION ignored
--- Additional Comments From echristo at redhat dot com 2005-04-10 19:02 --- I think I'm ok with this, but I'd like a bit more info. What changes to the backend do you forsee this needing? The one patch that you applied to the 4.1 sh branch was too big to just get that particular set of changes. -- http://gcc.gnu.org/bugzilla/show_bug.cgi?id=20396
[Bug middle-end/20396] TRULY_NOOP_TRUNCATION ignored
--- Additional Comments From amylaar at gcc dot gnu dot org 2005-04-08 17:04 --- (In reply to comment #1) :2005-03-09 Jorn Rennecke [EMAIL PROTECTED] :Richard Shann [EMAIL PROTECTED] : :* emit-rtl.c (gen_lowpart_common): Handle TRUNCATE. Generate :TRUNCATE for non-noop truncations. :* expr.c (force_operand): Handle TRUNCATE. :* rtlanal.c (reg_overlap_mentioned_p): Likewise. :* loop.c (combine_movables): Take TRULY_NOOP_TRUNCATION into account. :* optabs.c (expand_binop): Likewise. :* expmed.c (extract_fixed_bit_field): Check before assuming that :op is a MEM. Note that this a rather radical approach, in that it changes the behaviour of gen_lowpart_common to generate TRUNCATE instead of an unsuitable no-op truncation. This is efficient to safeguard against wrong code from the numerous places that call gen_lowpart, but the downside is that then TRUNCATE appears in interesting new places. This requires handling both in machine-independent code and in every port that doesn't set TRULY_NOOP_TRUNCATION to be always true. As far as I can see, this affects exactly two ports: SH64 and mips. I will pursue this patch further if the mips maintainers agree that this is a sensible approach to pursue, but not otherwise. In the meantime, I'll post a patch to gcc-patches that follows the more 'traditional' approach of fixing the callers of gen_lowpart, where these problems have been detected. This has very little risk of breaking an existing port, but a high probability to be incomplete. -- What|Removed |Added CC||rsandifo at redhat dot com, ||echristo at redhat dot com http://gcc.gnu.org/bugzilla/show_bug.cgi?id=20396
[Bug middle-end/20396] TRULY_NOOP_TRUNCATION ignored
--- Additional Comments From cvs-commit at gcc dot gnu dot org 2005-04-08 17:43 --- Subject: Bug 20396 CVSROOT:/cvs/gcc Module name:gcc Branch: sh-elf-4_1-branch Changes by: [EMAIL PROTECTED] 2005-04-08 17:41:35 Modified files: gcc/config/sh : crt1.asm elf.h lib1funcs.asm libgcc-excl.ver linux.h sh-protos.h sh.c sh.h sh.md shmedia.md sshmedia.h t-sh64 ushmedia.h Added files: gcc/config/sh : divtab.c newlib.h superh.h superh64.h t-superh Log message: 2005-04-06 Jorn Rennecke [EMAIL PROTECTED] PR middle-end/20793: * integrate.c (allocate_initial_values): Update register liveness information. PR rtl-optimization/20769: * bt-load.c (compute_defs_uses_and_gen): Check for the blockage pattern emitted by expand_nl_goto_receiver. PR rtl-optimization/20756: * basic-block.h (PROP_DEAD_INSN): Define. * flow.c (propagate_one_insn): Set during mark_set_regs call for a dead insn. PR middle-end/20714 * optabs.c (no_conflict_data): New struct. (no_conflict_move_test): New function. (emit_no_conflict_block): Use it. Workaround for PR rtl-optimization/20413: * sh.md (blt_media_i32, blt_media_i32+1): New splitters. Merge of SuperH / STM SH specific patches, including fix for PR target/20695: * config.gcc (sh*-superh-elf, sh*elf (newlib)): Use newlib.h when building with libgloss. (sh*elf): Implement --without-fp option. (sh64-superh-linux*): Don't multilib. (sh*-*-linux): Use sh3 as basic multilib. * config/sh/crt1.asm (SHmedia start): Add code to enable the MMU, and to set up vbr. Enable FPU before calling set_fpscr. Load atexit address just before use. Use __SH_FPU_ANY__. (SH3*/SH4* start): Add code to set up vbr. Use __SH_FPU_ANY__. Set DN bit in fpscr. * config/sh/elf.h (SUBTARGET_ASM_ISA_SPEC): Merge into: config/sh/sh.h (SH_ASM_SPEC, SUBTARGET_ASM_ISA_SPEC): Here. * config/sh/lib1funcs.asm (HIDDEN_FUNC, HIDDEN_ALIAS): Define. (FMOVD_WORKS): Don't define for __SH5__. (ashiftrt_r4_0, ashiftrt_r4_1, ashiftrt_r4_2, ashiftrt_r4_3): Hide. (ashiftrt_r4_4, ashiftrt_r4_5, ashiftrt_r4_6, ashiftrt_r4_7): Hide. (ashiftrt_r4_8, ashiftrt_r4_9, ashiftrt_r4_10, ashiftrt_r4_11): Hide. (ashiftrt_r4_12, ashiftrt_r4_13, ashiftrt_r4_14, ashiftrt_r4_15): Hide. (ashiftrt_r4_16, ashiftrt_r4_17, ashiftrt_r4_18, ashiftrt_r4_19): Hide. (ashiftrt_r4_20, ashiftrt_r4_21, ashiftrt_r4_22, ashiftrt_r4_23): Hide. (ashiftrt_r4_24, ashiftrt_r4_25, ashiftrt_r4_26, ashiftrt_r4_27): Hide. (ashiftrt_r4_28, ashiftrt_r4_29, ashiftrt_r4_30, ashiftrt_r4_31): Hide. (ashiftrt_r4_32, ashrsi3, ashlsi3, lshrsi3, movmem, movstr): Hide. (movstrSI64, movmemSI64, movstrSI60, movmemSI60): Hide. (movstrSI56, movmemSI56, movstrSI52, movmemSI52): Hide. (movstrSI48, movmemSI48, movstrSI44, movmemSI44): Hide. (movstrSI40, movmemSI40, movstrSI36, movmemSI36): Hide. (movstrSI32, movmemSI32, movstrSI28, movmemSI28): Hide. (movstrSI24, movmemSI24, movstrSI20, movmemSI20): Hide. (movstrSI16,movmemSI16, movstrSI12,movmemSI12): Hide. (movstrSI8,movmemSI8, movstrSI4,movmemSI4): Hide. (movmemSI0, movstrSI0): Remove. (movmemSI4): Schedule last store into rts delay slot. (movmem): Shorten code. Provide ENDFUNC. (movmem_i4_even, movmem_i4_odd, movmemSI12_i4, mulsi3): Hide. (mulsi3): Provide ENDFUNC. (sdivsi3_i4, sdivsi3_i4, udivsi3_i4, udivsi3, set_fpscr): Hide. (SH5 sdivsi3): Reimplement, using: (div_table): New, linear approximation table lookup for division seed. (sdivsi3_2): New SH5 entry point. (divdi3): Use hidden alias for udivdi3. (moddi3): Use hidden alias for umoddi3. (init_trampoline): Hide. Provide exact ENDFUNC. (ic_invalidate): Hide. Re-implement SH4 version, using (ic_invalidate_array): New global. (GCC_shcompact_return_trampoline, GCC_nested_trampoline): Hide. (GCC_push_shmedia_regs_nofpu): Only provide for __SH4_NOFPU__. (GCC_pop_shmedia_regs_nofpu): Likewise. * config/sh/libgcc-excl.ver (__mulsi3): Add. * config/sh/linux.h (TARGET_DEFAULT): Include TARGET_OPT_DEFAULT. * config/sh/sh-protos.h (sh_function_kind): New enum. (sh_gen_truncate, replace_n_hard_rtx): Declare. (function_symbol): Update declaration. (shmedia_cleanup_truncate, sh_contains_memref_p): Declare. * sh.c (cfgloop.h): Include. (TARGET_ADJUST_UNROLL_MAX): Redefine. (print_operand): Add '' and 'U' support. Handle TRUNCATE and
[Bug middle-end/20396] TRULY_NOOP_TRUNCATION ignored
--- Additional Comments From amylaar at gcc dot gnu dot org 2005-04-08 18:23 --- Patch is here: http://gcc.gnu.org/ml/gcc-patches/2005-04/msg00883.html -- What|Removed |Added Keywords||patch http://gcc.gnu.org/bugzilla/show_bug.cgi?id=20396
[Bug middle-end/20396] TRULY_NOOP_TRUNCATION ignored
--- Additional Comments From cvs-commit at gcc dot gnu dot org 2005-04-08 18:28 --- Subject: Bug 20396 CVSROOT:/cvs/gcc Module name:gcc Branch: sh-elf-4_1-branch Changes by: [EMAIL PROTECTED] 2005-04-08 18:28:02 Modified files: gcc: ChangeLog basic-block.h bt-load.c config.gcc flow.c integrate.c loop.c optabs.c Log message: 2005-04-06 Jorn Rennecke [EMAIL PROTECTED] PR middle-end/20793: * integrate.c (allocate_initial_values): Update register liveness information. PR rtl-optimization/20769: * bt-load.c (compute_defs_uses_and_gen): Check for the blockage pattern emitted by expand_nl_goto_receiver. PR rtl-optimization/20756: * basic-block.h (PROP_DEAD_INSN): Define. * flow.c (propagate_one_insn): Set during mark_set_regs call for a dead insn. PR middle-end/20714 * optabs.c (no_conflict_data): New struct. (no_conflict_move_test): New function. (emit_no_conflict_block): Use it. Workaround for PR rtl-optimization/20413: * sh.md (blt_media_i32, blt_media_i32+1): New splitters. Merge of SuperH / STM SH specific patches, including fix for PR target/20695: * config.gcc (sh*-superh-elf, sh*elf (newlib)): Use newlib.h when building with libgloss. (sh*elf): Implement --without-fp option. (sh64-superh-linux*): Don't multilib. (sh*-*-linux): Use sh3 as basic multilib. [config/sh/* changes elided] 2005-04-06 Andrew Stubbs [EMAIL PROTECTED] Jorn Rennecke [EMAIL PROTECTED] * config/sh/superh64.h, config/sh/superh.h: New files. * config/sh/newlib.h, config/sh/t-superh: Likewise. * config.gcc: Add support for sh*-superh-elf* and sh64-superh-linux*. 2005-04-06 Jorn Rennecke [EMAIL PROTECTED] Richard Shann [EMAIL PROTECTED] PR middle-end/20396: * loop.c (combine_movables): Take TRULY_NOOP_TRUNCATION into account. * optabs.c (expand_binop): Likewise. Patches: http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/ChangeLog.diff?cvsroot=gcconly_with_tag=sh-elf-4_1-branchr1=2.8142r2=2.8142.2.1 http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/basic-block.h.diff?cvsroot=gcconly_with_tag=sh-elf-4_1-branchr1=1.246r2=1.246.2.1 http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/bt-load.c.diff?cvsroot=gcconly_with_tag=sh-elf-4_1-branchr1=2.32r2=2.32.10.1 http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/config.gcc.diff?cvsroot=gcconly_with_tag=sh-elf-4_1-branchr1=1.530r2=1.530.2.1 http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/flow.c.diff?cvsroot=gcconly_with_tag=sh-elf-4_1-branchr1=1.623r2=1.623.2.1 http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/integrate.c.diff?cvsroot=gcconly_with_tag=sh-elf-4_1-branchr1=1.273r2=1.273.20.1 http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/loop.c.diff?cvsroot=gcconly_with_tag=sh-elf-4_1-branchr1=1.525r2=1.525.2.1 http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/gcc/optabs.c.diff?cvsroot=gcconly_with_tag=sh-elf-4_1-branchr1=1.268r2=1.268.2.1 -- http://gcc.gnu.org/bugzilla/show_bug.cgi?id=20396
[Bug middle-end/20396] TRULY_NOOP_TRUNCATION ignored
--- Additional Comments From amylaar at gcc dot gnu dot org 2005-03-09 21:17 --- Created an attachment (id=8370) -- (http://gcc.gnu.org/bugzilla/attachment.cgi?id=8370action=view) proposed fix (of known problems) -- http://gcc.gnu.org/bugzilla/show_bug.cgi?id=20396