diff options
author | Martin Liska <mliska@suse.cz> | 2022-01-14 16:56:44 +0100 |
---|---|---|
committer | Martin Liska <mliska@suse.cz> | 2022-01-17 22:12:04 +0100 |
commit | 5c69acb32329d49e58c26fa41ae74229a52b9106 (patch) | |
tree | ddb05f9d73afb6f998457d2ac4b720e3b3b60483 /gcc/postreload.c | |
parent | 490e23032baaece71f2ec09fa1805064b150fbc2 (diff) | |
download | gcc-5c69acb32329d49e58c26fa41ae74229a52b9106.zip gcc-5c69acb32329d49e58c26fa41ae74229a52b9106.tar.gz gcc-5c69acb32329d49e58c26fa41ae74229a52b9106.tar.bz2 |
Rename .c files to .cc files.
gcc/ada/ChangeLog:
* adadecode.c: Moved to...
* adadecode.cc: ...here.
* affinity.c: Moved to...
* affinity.cc: ...here.
* argv-lynxos178-raven-cert.c: Moved to...
* argv-lynxos178-raven-cert.cc: ...here.
* argv.c: Moved to...
* argv.cc: ...here.
* aux-io.c: Moved to...
* aux-io.cc: ...here.
* cio.c: Moved to...
* cio.cc: ...here.
* cstreams.c: Moved to...
* cstreams.cc: ...here.
* env.c: Moved to...
* env.cc: ...here.
* exit.c: Moved to...
* exit.cc: ...here.
* expect.c: Moved to...
* expect.cc: ...here.
* final.c: Moved to...
* final.cc: ...here.
* gcc-interface/cuintp.c: Moved to...
* gcc-interface/cuintp.cc: ...here.
* gcc-interface/decl.c: Moved to...
* gcc-interface/decl.cc: ...here.
* gcc-interface/misc.c: Moved to...
* gcc-interface/misc.cc: ...here.
* gcc-interface/targtyps.c: Moved to...
* gcc-interface/targtyps.cc: ...here.
* gcc-interface/trans.c: Moved to...
* gcc-interface/trans.cc: ...here.
* gcc-interface/utils.c: Moved to...
* gcc-interface/utils.cc: ...here.
* gcc-interface/utils2.c: Moved to...
* gcc-interface/utils2.cc: ...here.
* init.c: Moved to...
* init.cc: ...here.
* initialize.c: Moved to...
* initialize.cc: ...here.
* libgnarl/thread.c: Moved to...
* libgnarl/thread.cc: ...here.
* link.c: Moved to...
* link.cc: ...here.
* locales.c: Moved to...
* locales.cc: ...here.
* mkdir.c: Moved to...
* mkdir.cc: ...here.
* raise.c: Moved to...
* raise.cc: ...here.
* rtfinal.c: Moved to...
* rtfinal.cc: ...here.
* rtinit.c: Moved to...
* rtinit.cc: ...here.
* seh_init.c: Moved to...
* seh_init.cc: ...here.
* sigtramp-armdroid.c: Moved to...
* sigtramp-armdroid.cc: ...here.
* sigtramp-ios.c: Moved to...
* sigtramp-ios.cc: ...here.
* sigtramp-qnx.c: Moved to...
* sigtramp-qnx.cc: ...here.
* sigtramp-vxworks.c: Moved to...
* sigtramp-vxworks.cc: ...here.
* socket.c: Moved to...
* socket.cc: ...here.
* tracebak.c: Moved to...
* tracebak.cc: ...here.
* version.c: Moved to...
* version.cc: ...here.
* vx_stack_info.c: Moved to...
* vx_stack_info.cc: ...here.
gcc/ChangeLog:
* adjust-alignment.c: Moved to...
* adjust-alignment.cc: ...here.
* alias.c: Moved to...
* alias.cc: ...here.
* alloc-pool.c: Moved to...
* alloc-pool.cc: ...here.
* asan.c: Moved to...
* asan.cc: ...here.
* attribs.c: Moved to...
* attribs.cc: ...here.
* auto-inc-dec.c: Moved to...
* auto-inc-dec.cc: ...here.
* auto-profile.c: Moved to...
* auto-profile.cc: ...here.
* bb-reorder.c: Moved to...
* bb-reorder.cc: ...here.
* bitmap.c: Moved to...
* bitmap.cc: ...here.
* btfout.c: Moved to...
* btfout.cc: ...here.
* builtins.c: Moved to...
* builtins.cc: ...here.
* caller-save.c: Moved to...
* caller-save.cc: ...here.
* calls.c: Moved to...
* calls.cc: ...here.
* ccmp.c: Moved to...
* ccmp.cc: ...here.
* cfg.c: Moved to...
* cfg.cc: ...here.
* cfganal.c: Moved to...
* cfganal.cc: ...here.
* cfgbuild.c: Moved to...
* cfgbuild.cc: ...here.
* cfgcleanup.c: Moved to...
* cfgcleanup.cc: ...here.
* cfgexpand.c: Moved to...
* cfgexpand.cc: ...here.
* cfghooks.c: Moved to...
* cfghooks.cc: ...here.
* cfgloop.c: Moved to...
* cfgloop.cc: ...here.
* cfgloopanal.c: Moved to...
* cfgloopanal.cc: ...here.
* cfgloopmanip.c: Moved to...
* cfgloopmanip.cc: ...here.
* cfgrtl.c: Moved to...
* cfgrtl.cc: ...here.
* cgraph.c: Moved to...
* cgraph.cc: ...here.
* cgraphbuild.c: Moved to...
* cgraphbuild.cc: ...here.
* cgraphclones.c: Moved to...
* cgraphclones.cc: ...here.
* cgraphunit.c: Moved to...
* cgraphunit.cc: ...here.
* collect-utils.c: Moved to...
* collect-utils.cc: ...here.
* collect2-aix.c: Moved to...
* collect2-aix.cc: ...here.
* collect2.c: Moved to...
* collect2.cc: ...here.
* combine-stack-adj.c: Moved to...
* combine-stack-adj.cc: ...here.
* combine.c: Moved to...
* combine.cc: ...here.
* common/common-targhooks.c: Moved to...
* common/common-targhooks.cc: ...here.
* common/config/aarch64/aarch64-common.c: Moved to...
* common/config/aarch64/aarch64-common.cc: ...here.
* common/config/alpha/alpha-common.c: Moved to...
* common/config/alpha/alpha-common.cc: ...here.
* common/config/arc/arc-common.c: Moved to...
* common/config/arc/arc-common.cc: ...here.
* common/config/arm/arm-common.c: Moved to...
* common/config/arm/arm-common.cc: ...here.
* common/config/avr/avr-common.c: Moved to...
* common/config/avr/avr-common.cc: ...here.
* common/config/bfin/bfin-common.c: Moved to...
* common/config/bfin/bfin-common.cc: ...here.
* common/config/bpf/bpf-common.c: Moved to...
* common/config/bpf/bpf-common.cc: ...here.
* common/config/c6x/c6x-common.c: Moved to...
* common/config/c6x/c6x-common.cc: ...here.
* common/config/cr16/cr16-common.c: Moved to...
* common/config/cr16/cr16-common.cc: ...here.
* common/config/cris/cris-common.c: Moved to...
* common/config/cris/cris-common.cc: ...here.
* common/config/csky/csky-common.c: Moved to...
* common/config/csky/csky-common.cc: ...here.
* common/config/default-common.c: Moved to...
* common/config/default-common.cc: ...here.
* common/config/epiphany/epiphany-common.c: Moved to...
* common/config/epiphany/epiphany-common.cc: ...here.
* common/config/fr30/fr30-common.c: Moved to...
* common/config/fr30/fr30-common.cc: ...here.
* common/config/frv/frv-common.c: Moved to...
* common/config/frv/frv-common.cc: ...here.
* common/config/gcn/gcn-common.c: Moved to...
* common/config/gcn/gcn-common.cc: ...here.
* common/config/h8300/h8300-common.c: Moved to...
* common/config/h8300/h8300-common.cc: ...here.
* common/config/i386/i386-common.c: Moved to...
* common/config/i386/i386-common.cc: ...here.
* common/config/ia64/ia64-common.c: Moved to...
* common/config/ia64/ia64-common.cc: ...here.
* common/config/iq2000/iq2000-common.c: Moved to...
* common/config/iq2000/iq2000-common.cc: ...here.
* common/config/lm32/lm32-common.c: Moved to...
* common/config/lm32/lm32-common.cc: ...here.
* common/config/m32r/m32r-common.c: Moved to...
* common/config/m32r/m32r-common.cc: ...here.
* common/config/m68k/m68k-common.c: Moved to...
* common/config/m68k/m68k-common.cc: ...here.
* common/config/mcore/mcore-common.c: Moved to...
* common/config/mcore/mcore-common.cc: ...here.
* common/config/microblaze/microblaze-common.c: Moved to...
* common/config/microblaze/microblaze-common.cc: ...here.
* common/config/mips/mips-common.c: Moved to...
* common/config/mips/mips-common.cc: ...here.
* common/config/mmix/mmix-common.c: Moved to...
* common/config/mmix/mmix-common.cc: ...here.
* common/config/mn10300/mn10300-common.c: Moved to...
* common/config/mn10300/mn10300-common.cc: ...here.
* common/config/msp430/msp430-common.c: Moved to...
* common/config/msp430/msp430-common.cc: ...here.
* common/config/nds32/nds32-common.c: Moved to...
* common/config/nds32/nds32-common.cc: ...here.
* common/config/nios2/nios2-common.c: Moved to...
* common/config/nios2/nios2-common.cc: ...here.
* common/config/nvptx/nvptx-common.c: Moved to...
* common/config/nvptx/nvptx-common.cc: ...here.
* common/config/or1k/or1k-common.c: Moved to...
* common/config/or1k/or1k-common.cc: ...here.
* common/config/pa/pa-common.c: Moved to...
* common/config/pa/pa-common.cc: ...here.
* common/config/pdp11/pdp11-common.c: Moved to...
* common/config/pdp11/pdp11-common.cc: ...here.
* common/config/pru/pru-common.c: Moved to...
* common/config/pru/pru-common.cc: ...here.
* common/config/riscv/riscv-common.c: Moved to...
* common/config/riscv/riscv-common.cc: ...here.
* common/config/rs6000/rs6000-common.c: Moved to...
* common/config/rs6000/rs6000-common.cc: ...here.
* common/config/rx/rx-common.c: Moved to...
* common/config/rx/rx-common.cc: ...here.
* common/config/s390/s390-common.c: Moved to...
* common/config/s390/s390-common.cc: ...here.
* common/config/sh/sh-common.c: Moved to...
* common/config/sh/sh-common.cc: ...here.
* common/config/sparc/sparc-common.c: Moved to...
* common/config/sparc/sparc-common.cc: ...here.
* common/config/tilegx/tilegx-common.c: Moved to...
* common/config/tilegx/tilegx-common.cc: ...here.
* common/config/tilepro/tilepro-common.c: Moved to...
* common/config/tilepro/tilepro-common.cc: ...here.
* common/config/v850/v850-common.c: Moved to...
* common/config/v850/v850-common.cc: ...here.
* common/config/vax/vax-common.c: Moved to...
* common/config/vax/vax-common.cc: ...here.
* common/config/visium/visium-common.c: Moved to...
* common/config/visium/visium-common.cc: ...here.
* common/config/xstormy16/xstormy16-common.c: Moved to...
* common/config/xstormy16/xstormy16-common.cc: ...here.
* common/config/xtensa/xtensa-common.c: Moved to...
* common/config/xtensa/xtensa-common.cc: ...here.
* compare-elim.c: Moved to...
* compare-elim.cc: ...here.
* config/aarch64/aarch64-bti-insert.c: Moved to...
* config/aarch64/aarch64-bti-insert.cc: ...here.
* config/aarch64/aarch64-builtins.c: Moved to...
* config/aarch64/aarch64-builtins.cc: ...here.
* config/aarch64/aarch64-c.c: Moved to...
* config/aarch64/aarch64-c.cc: ...here.
* config/aarch64/aarch64-d.c: Moved to...
* config/aarch64/aarch64-d.cc: ...here.
* config/aarch64/aarch64.c: Moved to...
* config/aarch64/aarch64.cc: ...here.
* config/aarch64/cortex-a57-fma-steering.c: Moved to...
* config/aarch64/cortex-a57-fma-steering.cc: ...here.
* config/aarch64/driver-aarch64.c: Moved to...
* config/aarch64/driver-aarch64.cc: ...here.
* config/aarch64/falkor-tag-collision-avoidance.c: Moved to...
* config/aarch64/falkor-tag-collision-avoidance.cc: ...here.
* config/aarch64/host-aarch64-darwin.c: Moved to...
* config/aarch64/host-aarch64-darwin.cc: ...here.
* config/alpha/alpha.c: Moved to...
* config/alpha/alpha.cc: ...here.
* config/alpha/driver-alpha.c: Moved to...
* config/alpha/driver-alpha.cc: ...here.
* config/arc/arc-c.c: Moved to...
* config/arc/arc-c.cc: ...here.
* config/arc/arc.c: Moved to...
* config/arc/arc.cc: ...here.
* config/arc/driver-arc.c: Moved to...
* config/arc/driver-arc.cc: ...here.
* config/arm/aarch-common.c: Moved to...
* config/arm/aarch-common.cc: ...here.
* config/arm/arm-builtins.c: Moved to...
* config/arm/arm-builtins.cc: ...here.
* config/arm/arm-c.c: Moved to...
* config/arm/arm-c.cc: ...here.
* config/arm/arm-d.c: Moved to...
* config/arm/arm-d.cc: ...here.
* config/arm/arm.c: Moved to...
* config/arm/arm.cc: ...here.
* config/arm/driver-arm.c: Moved to...
* config/arm/driver-arm.cc: ...here.
* config/avr/avr-c.c: Moved to...
* config/avr/avr-c.cc: ...here.
* config/avr/avr-devices.c: Moved to...
* config/avr/avr-devices.cc: ...here.
* config/avr/avr-log.c: Moved to...
* config/avr/avr-log.cc: ...here.
* config/avr/avr.c: Moved to...
* config/avr/avr.cc: ...here.
* config/avr/driver-avr.c: Moved to...
* config/avr/driver-avr.cc: ...here.
* config/avr/gen-avr-mmcu-specs.c: Moved to...
* config/avr/gen-avr-mmcu-specs.cc: ...here.
* config/avr/gen-avr-mmcu-texi.c: Moved to...
* config/avr/gen-avr-mmcu-texi.cc: ...here.
* config/bfin/bfin.c: Moved to...
* config/bfin/bfin.cc: ...here.
* config/bpf/bpf.c: Moved to...
* config/bpf/bpf.cc: ...here.
* config/bpf/coreout.c: Moved to...
* config/bpf/coreout.cc: ...here.
* config/c6x/c6x.c: Moved to...
* config/c6x/c6x.cc: ...here.
* config/cr16/cr16.c: Moved to...
* config/cr16/cr16.cc: ...here.
* config/cris/cris.c: Moved to...
* config/cris/cris.cc: ...here.
* config/csky/csky.c: Moved to...
* config/csky/csky.cc: ...here.
* config/darwin-c.c: Moved to...
* config/darwin-c.cc: ...here.
* config/darwin-d.c: Moved to...
* config/darwin-d.cc: ...here.
* config/darwin-driver.c: Moved to...
* config/darwin-driver.cc: ...here.
* config/darwin-f.c: Moved to...
* config/darwin-f.cc: ...here.
* config/darwin.c: Moved to...
* config/darwin.cc: ...here.
* config/default-c.c: Moved to...
* config/default-c.cc: ...here.
* config/default-d.c: Moved to...
* config/default-d.cc: ...here.
* config/dragonfly-d.c: Moved to...
* config/dragonfly-d.cc: ...here.
* config/epiphany/epiphany.c: Moved to...
* config/epiphany/epiphany.cc: ...here.
* config/epiphany/mode-switch-use.c: Moved to...
* config/epiphany/mode-switch-use.cc: ...here.
* config/epiphany/resolve-sw-modes.c: Moved to...
* config/epiphany/resolve-sw-modes.cc: ...here.
* config/fr30/fr30.c: Moved to...
* config/fr30/fr30.cc: ...here.
* config/freebsd-d.c: Moved to...
* config/freebsd-d.cc: ...here.
* config/frv/frv.c: Moved to...
* config/frv/frv.cc: ...here.
* config/ft32/ft32.c: Moved to...
* config/ft32/ft32.cc: ...here.
* config/gcn/driver-gcn.c: Moved to...
* config/gcn/driver-gcn.cc: ...here.
* config/gcn/gcn-run.c: Moved to...
* config/gcn/gcn-run.cc: ...here.
* config/gcn/gcn-tree.c: Moved to...
* config/gcn/gcn-tree.cc: ...here.
* config/gcn/gcn.c: Moved to...
* config/gcn/gcn.cc: ...here.
* config/gcn/mkoffload.c: Moved to...
* config/gcn/mkoffload.cc: ...here.
* config/glibc-c.c: Moved to...
* config/glibc-c.cc: ...here.
* config/glibc-d.c: Moved to...
* config/glibc-d.cc: ...here.
* config/h8300/h8300.c: Moved to...
* config/h8300/h8300.cc: ...here.
* config/host-darwin.c: Moved to...
* config/host-darwin.cc: ...here.
* config/host-hpux.c: Moved to...
* config/host-hpux.cc: ...here.
* config/host-linux.c: Moved to...
* config/host-linux.cc: ...here.
* config/host-netbsd.c: Moved to...
* config/host-netbsd.cc: ...here.
* config/host-openbsd.c: Moved to...
* config/host-openbsd.cc: ...here.
* config/host-solaris.c: Moved to...
* config/host-solaris.cc: ...here.
* config/i386/djgpp.c: Moved to...
* config/i386/djgpp.cc: ...here.
* config/i386/driver-i386.c: Moved to...
* config/i386/driver-i386.cc: ...here.
* config/i386/driver-mingw32.c: Moved to...
* config/i386/driver-mingw32.cc: ...here.
* config/i386/gnu-property.c: Moved to...
* config/i386/gnu-property.cc: ...here.
* config/i386/host-cygwin.c: Moved to...
* config/i386/host-cygwin.cc: ...here.
* config/i386/host-i386-darwin.c: Moved to...
* config/i386/host-i386-darwin.cc: ...here.
* config/i386/host-mingw32.c: Moved to...
* config/i386/host-mingw32.cc: ...here.
* config/i386/i386-builtins.c: Moved to...
* config/i386/i386-builtins.cc: ...here.
* config/i386/i386-c.c: Moved to...
* config/i386/i386-c.cc: ...here.
* config/i386/i386-d.c: Moved to...
* config/i386/i386-d.cc: ...here.
* config/i386/i386-expand.c: Moved to...
* config/i386/i386-expand.cc: ...here.
* config/i386/i386-features.c: Moved to...
* config/i386/i386-features.cc: ...here.
* config/i386/i386-options.c: Moved to...
* config/i386/i386-options.cc: ...here.
* config/i386/i386.c: Moved to...
* config/i386/i386.cc: ...here.
* config/i386/intelmic-mkoffload.c: Moved to...
* config/i386/intelmic-mkoffload.cc: ...here.
* config/i386/msformat-c.c: Moved to...
* config/i386/msformat-c.cc: ...here.
* config/i386/winnt-cxx.c: Moved to...
* config/i386/winnt-cxx.cc: ...here.
* config/i386/winnt-d.c: Moved to...
* config/i386/winnt-d.cc: ...here.
* config/i386/winnt-stubs.c: Moved to...
* config/i386/winnt-stubs.cc: ...here.
* config/i386/winnt.c: Moved to...
* config/i386/winnt.cc: ...here.
* config/i386/x86-tune-sched-atom.c: Moved to...
* config/i386/x86-tune-sched-atom.cc: ...here.
* config/i386/x86-tune-sched-bd.c: Moved to...
* config/i386/x86-tune-sched-bd.cc: ...here.
* config/i386/x86-tune-sched-core.c: Moved to...
* config/i386/x86-tune-sched-core.cc: ...here.
* config/i386/x86-tune-sched.c: Moved to...
* config/i386/x86-tune-sched.cc: ...here.
* config/ia64/ia64-c.c: Moved to...
* config/ia64/ia64-c.cc: ...here.
* config/ia64/ia64.c: Moved to...
* config/ia64/ia64.cc: ...here.
* config/iq2000/iq2000.c: Moved to...
* config/iq2000/iq2000.cc: ...here.
* config/linux.c: Moved to...
* config/linux.cc: ...here.
* config/lm32/lm32.c: Moved to...
* config/lm32/lm32.cc: ...here.
* config/m32c/m32c-pragma.c: Moved to...
* config/m32c/m32c-pragma.cc: ...here.
* config/m32c/m32c.c: Moved to...
* config/m32c/m32c.cc: ...here.
* config/m32r/m32r.c: Moved to...
* config/m32r/m32r.cc: ...here.
* config/m68k/m68k.c: Moved to...
* config/m68k/m68k.cc: ...here.
* config/mcore/mcore.c: Moved to...
* config/mcore/mcore.cc: ...here.
* config/microblaze/microblaze-c.c: Moved to...
* config/microblaze/microblaze-c.cc: ...here.
* config/microblaze/microblaze.c: Moved to...
* config/microblaze/microblaze.cc: ...here.
* config/mips/driver-native.c: Moved to...
* config/mips/driver-native.cc: ...here.
* config/mips/frame-header-opt.c: Moved to...
* config/mips/frame-header-opt.cc: ...here.
* config/mips/mips-d.c: Moved to...
* config/mips/mips-d.cc: ...here.
* config/mips/mips.c: Moved to...
* config/mips/mips.cc: ...here.
* config/mmix/mmix.c: Moved to...
* config/mmix/mmix.cc: ...here.
* config/mn10300/mn10300.c: Moved to...
* config/mn10300/mn10300.cc: ...here.
* config/moxie/moxie.c: Moved to...
* config/moxie/moxie.cc: ...here.
* config/msp430/driver-msp430.c: Moved to...
* config/msp430/driver-msp430.cc: ...here.
* config/msp430/msp430-c.c: Moved to...
* config/msp430/msp430-c.cc: ...here.
* config/msp430/msp430-devices.c: Moved to...
* config/msp430/msp430-devices.cc: ...here.
* config/msp430/msp430.c: Moved to...
* config/msp430/msp430.cc: ...here.
* config/nds32/nds32-cost.c: Moved to...
* config/nds32/nds32-cost.cc: ...here.
* config/nds32/nds32-fp-as-gp.c: Moved to...
* config/nds32/nds32-fp-as-gp.cc: ...here.
* config/nds32/nds32-intrinsic.c: Moved to...
* config/nds32/nds32-intrinsic.cc: ...here.
* config/nds32/nds32-isr.c: Moved to...
* config/nds32/nds32-isr.cc: ...here.
* config/nds32/nds32-md-auxiliary.c: Moved to...
* config/nds32/nds32-md-auxiliary.cc: ...here.
* config/nds32/nds32-memory-manipulation.c: Moved to...
* config/nds32/nds32-memory-manipulation.cc: ...here.
* config/nds32/nds32-pipelines-auxiliary.c: Moved to...
* config/nds32/nds32-pipelines-auxiliary.cc: ...here.
* config/nds32/nds32-predicates.c: Moved to...
* config/nds32/nds32-predicates.cc: ...here.
* config/nds32/nds32-relax-opt.c: Moved to...
* config/nds32/nds32-relax-opt.cc: ...here.
* config/nds32/nds32-utils.c: Moved to...
* config/nds32/nds32-utils.cc: ...here.
* config/nds32/nds32.c: Moved to...
* config/nds32/nds32.cc: ...here.
* config/netbsd-d.c: Moved to...
* config/netbsd-d.cc: ...here.
* config/netbsd.c: Moved to...
* config/netbsd.cc: ...here.
* config/nios2/nios2.c: Moved to...
* config/nios2/nios2.cc: ...here.
* config/nvptx/mkoffload.c: Moved to...
* config/nvptx/mkoffload.cc: ...here.
* config/nvptx/nvptx-c.c: Moved to...
* config/nvptx/nvptx-c.cc: ...here.
* config/nvptx/nvptx.c: Moved to...
* config/nvptx/nvptx.cc: ...here.
* config/openbsd-d.c: Moved to...
* config/openbsd-d.cc: ...here.
* config/or1k/or1k.c: Moved to...
* config/or1k/or1k.cc: ...here.
* config/pa/pa-d.c: Moved to...
* config/pa/pa-d.cc: ...here.
* config/pa/pa.c: Moved to...
* config/pa/pa.cc: ...here.
* config/pdp11/pdp11.c: Moved to...
* config/pdp11/pdp11.cc: ...here.
* config/pru/pru-passes.c: Moved to...
* config/pru/pru-passes.cc: ...here.
* config/pru/pru-pragma.c: Moved to...
* config/pru/pru-pragma.cc: ...here.
* config/pru/pru.c: Moved to...
* config/pru/pru.cc: ...here.
* config/riscv/riscv-builtins.c: Moved to...
* config/riscv/riscv-builtins.cc: ...here.
* config/riscv/riscv-c.c: Moved to...
* config/riscv/riscv-c.cc: ...here.
* config/riscv/riscv-d.c: Moved to...
* config/riscv/riscv-d.cc: ...here.
* config/riscv/riscv-shorten-memrefs.c: Moved to...
* config/riscv/riscv-shorten-memrefs.cc: ...here.
* config/riscv/riscv-sr.c: Moved to...
* config/riscv/riscv-sr.cc: ...here.
* config/riscv/riscv.c: Moved to...
* config/riscv/riscv.cc: ...here.
* config/rl78/rl78-c.c: Moved to...
* config/rl78/rl78-c.cc: ...here.
* config/rl78/rl78.c: Moved to...
* config/rl78/rl78.cc: ...here.
* config/rs6000/driver-rs6000.c: Moved to...
* config/rs6000/driver-rs6000.cc: ...here.
* config/rs6000/host-darwin.c: Moved to...
* config/rs6000/host-darwin.cc: ...here.
* config/rs6000/host-ppc64-darwin.c: Moved to...
* config/rs6000/host-ppc64-darwin.cc: ...here.
* config/rs6000/rbtree.c: Moved to...
* config/rs6000/rbtree.cc: ...here.
* config/rs6000/rs6000-c.c: Moved to...
* config/rs6000/rs6000-c.cc: ...here.
* config/rs6000/rs6000-call.c: Moved to...
* config/rs6000/rs6000-call.cc: ...here.
* config/rs6000/rs6000-d.c: Moved to...
* config/rs6000/rs6000-d.cc: ...here.
* config/rs6000/rs6000-gen-builtins.c: Moved to...
* config/rs6000/rs6000-gen-builtins.cc: ...here.
* config/rs6000/rs6000-linux.c: Moved to...
* config/rs6000/rs6000-linux.cc: ...here.
* config/rs6000/rs6000-logue.c: Moved to...
* config/rs6000/rs6000-logue.cc: ...here.
* config/rs6000/rs6000-p8swap.c: Moved to...
* config/rs6000/rs6000-p8swap.cc: ...here.
* config/rs6000/rs6000-pcrel-opt.c: Moved to...
* config/rs6000/rs6000-pcrel-opt.cc: ...here.
* config/rs6000/rs6000-string.c: Moved to...
* config/rs6000/rs6000-string.cc: ...here.
* config/rs6000/rs6000.c: Moved to...
* config/rs6000/rs6000.cc: ...here.
* config/rx/rx.c: Moved to...
* config/rx/rx.cc: ...here.
* config/s390/driver-native.c: Moved to...
* config/s390/driver-native.cc: ...here.
* config/s390/s390-c.c: Moved to...
* config/s390/s390-c.cc: ...here.
* config/s390/s390-d.c: Moved to...
* config/s390/s390-d.cc: ...here.
* config/s390/s390.c: Moved to...
* config/s390/s390.cc: ...here.
* config/sh/divtab-sh4-300.c: Moved to...
* config/sh/divtab-sh4-300.cc: ...here.
* config/sh/divtab-sh4.c: Moved to...
* config/sh/divtab-sh4.cc: ...here.
* config/sh/divtab.c: Moved to...
* config/sh/divtab.cc: ...here.
* config/sh/sh-c.c: Moved to...
* config/sh/sh-c.cc: ...here.
* config/sh/sh.c: Moved to...
* config/sh/sh.cc: ...here.
* config/sol2-c.c: Moved to...
* config/sol2-c.cc: ...here.
* config/sol2-cxx.c: Moved to...
* config/sol2-cxx.cc: ...here.
* config/sol2-d.c: Moved to...
* config/sol2-d.cc: ...here.
* config/sol2-stubs.c: Moved to...
* config/sol2-stubs.cc: ...here.
* config/sol2.c: Moved to...
* config/sol2.cc: ...here.
* config/sparc/driver-sparc.c: Moved to...
* config/sparc/driver-sparc.cc: ...here.
* config/sparc/sparc-c.c: Moved to...
* config/sparc/sparc-c.cc: ...here.
* config/sparc/sparc-d.c: Moved to...
* config/sparc/sparc-d.cc: ...here.
* config/sparc/sparc.c: Moved to...
* config/sparc/sparc.cc: ...here.
* config/stormy16/stormy16.c: Moved to...
* config/stormy16/stormy16.cc: ...here.
* config/tilegx/mul-tables.c: Moved to...
* config/tilegx/mul-tables.cc: ...here.
* config/tilegx/tilegx-c.c: Moved to...
* config/tilegx/tilegx-c.cc: ...here.
* config/tilegx/tilegx.c: Moved to...
* config/tilegx/tilegx.cc: ...here.
* config/tilepro/mul-tables.c: Moved to...
* config/tilepro/mul-tables.cc: ...here.
* config/tilepro/tilepro-c.c: Moved to...
* config/tilepro/tilepro-c.cc: ...here.
* config/tilepro/tilepro.c: Moved to...
* config/tilepro/tilepro.cc: ...here.
* config/v850/v850-c.c: Moved to...
* config/v850/v850-c.cc: ...here.
* config/v850/v850.c: Moved to...
* config/v850/v850.cc: ...here.
* config/vax/vax.c: Moved to...
* config/vax/vax.cc: ...here.
* config/visium/visium.c: Moved to...
* config/visium/visium.cc: ...here.
* config/vms/vms-c.c: Moved to...
* config/vms/vms-c.cc: ...here.
* config/vms/vms-f.c: Moved to...
* config/vms/vms-f.cc: ...here.
* config/vms/vms.c: Moved to...
* config/vms/vms.cc: ...here.
* config/vxworks-c.c: Moved to...
* config/vxworks-c.cc: ...here.
* config/vxworks.c: Moved to...
* config/vxworks.cc: ...here.
* config/winnt-c.c: Moved to...
* config/winnt-c.cc: ...here.
* config/xtensa/xtensa.c: Moved to...
* config/xtensa/xtensa.cc: ...here.
* context.c: Moved to...
* context.cc: ...here.
* convert.c: Moved to...
* convert.cc: ...here.
* coverage.c: Moved to...
* coverage.cc: ...here.
* cppbuiltin.c: Moved to...
* cppbuiltin.cc: ...here.
* cppdefault.c: Moved to...
* cppdefault.cc: ...here.
* cprop.c: Moved to...
* cprop.cc: ...here.
* cse.c: Moved to...
* cse.cc: ...here.
* cselib.c: Moved to...
* cselib.cc: ...here.
* ctfc.c: Moved to...
* ctfc.cc: ...here.
* ctfout.c: Moved to...
* ctfout.cc: ...here.
* data-streamer-in.c: Moved to...
* data-streamer-in.cc: ...here.
* data-streamer-out.c: Moved to...
* data-streamer-out.cc: ...here.
* data-streamer.c: Moved to...
* data-streamer.cc: ...here.
* dbgcnt.c: Moved to...
* dbgcnt.cc: ...here.
* dbxout.c: Moved to...
* dbxout.cc: ...here.
* dce.c: Moved to...
* dce.cc: ...here.
* ddg.c: Moved to...
* ddg.cc: ...here.
* debug.c: Moved to...
* debug.cc: ...here.
* df-core.c: Moved to...
* df-core.cc: ...here.
* df-problems.c: Moved to...
* df-problems.cc: ...here.
* df-scan.c: Moved to...
* df-scan.cc: ...here.
* dfp.c: Moved to...
* dfp.cc: ...here.
* diagnostic-color.c: Moved to...
* diagnostic-color.cc: ...here.
* diagnostic-show-locus.c: Moved to...
* diagnostic-show-locus.cc: ...here.
* diagnostic-spec.c: Moved to...
* diagnostic-spec.cc: ...here.
* diagnostic.c: Moved to...
* diagnostic.cc: ...here.
* dojump.c: Moved to...
* dojump.cc: ...here.
* dominance.c: Moved to...
* dominance.cc: ...here.
* domwalk.c: Moved to...
* domwalk.cc: ...here.
* double-int.c: Moved to...
* double-int.cc: ...here.
* dse.c: Moved to...
* dse.cc: ...here.
* dumpfile.c: Moved to...
* dumpfile.cc: ...here.
* dwarf2asm.c: Moved to...
* dwarf2asm.cc: ...here.
* dwarf2cfi.c: Moved to...
* dwarf2cfi.cc: ...here.
* dwarf2ctf.c: Moved to...
* dwarf2ctf.cc: ...here.
* dwarf2out.c: Moved to...
* dwarf2out.cc: ...here.
* early-remat.c: Moved to...
* early-remat.cc: ...here.
* edit-context.c: Moved to...
* edit-context.cc: ...here.
* emit-rtl.c: Moved to...
* emit-rtl.cc: ...here.
* errors.c: Moved to...
* errors.cc: ...here.
* et-forest.c: Moved to...
* et-forest.cc: ...here.
* except.c: Moved to...
* except.cc: ...here.
* explow.c: Moved to...
* explow.cc: ...here.
* expmed.c: Moved to...
* expmed.cc: ...here.
* expr.c: Moved to...
* expr.cc: ...here.
* fibonacci_heap.c: Moved to...
* fibonacci_heap.cc: ...here.
* file-find.c: Moved to...
* file-find.cc: ...here.
* file-prefix-map.c: Moved to...
* file-prefix-map.cc: ...here.
* final.c: Moved to...
* final.cc: ...here.
* fixed-value.c: Moved to...
* fixed-value.cc: ...here.
* fold-const-call.c: Moved to...
* fold-const-call.cc: ...here.
* fold-const.c: Moved to...
* fold-const.cc: ...here.
* fp-test.c: Moved to...
* fp-test.cc: ...here.
* function-tests.c: Moved to...
* function-tests.cc: ...here.
* function.c: Moved to...
* function.cc: ...here.
* fwprop.c: Moved to...
* fwprop.cc: ...here.
* gcc-ar.c: Moved to...
* gcc-ar.cc: ...here.
* gcc-main.c: Moved to...
* gcc-main.cc: ...here.
* gcc-rich-location.c: Moved to...
* gcc-rich-location.cc: ...here.
* gcc.c: Moved to...
* gcc.cc: ...here.
* gcov-dump.c: Moved to...
* gcov-dump.cc: ...here.
* gcov-io.c: Moved to...
* gcov-io.cc: ...here.
* gcov-tool.c: Moved to...
* gcov-tool.cc: ...here.
* gcov.c: Moved to...
* gcov.cc: ...here.
* gcse-common.c: Moved to...
* gcse-common.cc: ...here.
* gcse.c: Moved to...
* gcse.cc: ...here.
* genattr-common.c: Moved to...
* genattr-common.cc: ...here.
* genattr.c: Moved to...
* genattr.cc: ...here.
* genattrtab.c: Moved to...
* genattrtab.cc: ...here.
* genautomata.c: Moved to...
* genautomata.cc: ...here.
* gencfn-macros.c: Moved to...
* gencfn-macros.cc: ...here.
* gencheck.c: Moved to...
* gencheck.cc: ...here.
* genchecksum.c: Moved to...
* genchecksum.cc: ...here.
* gencodes.c: Moved to...
* gencodes.cc: ...here.
* genconditions.c: Moved to...
* genconditions.cc: ...here.
* genconfig.c: Moved to...
* genconfig.cc: ...here.
* genconstants.c: Moved to...
* genconstants.cc: ...here.
* genemit.c: Moved to...
* genemit.cc: ...here.
* genenums.c: Moved to...
* genenums.cc: ...here.
* generic-match-head.c: Moved to...
* generic-match-head.cc: ...here.
* genextract.c: Moved to...
* genextract.cc: ...here.
* genflags.c: Moved to...
* genflags.cc: ...here.
* gengenrtl.c: Moved to...
* gengenrtl.cc: ...here.
* gengtype-parse.c: Moved to...
* gengtype-parse.cc: ...here.
* gengtype-state.c: Moved to...
* gengtype-state.cc: ...here.
* gengtype.c: Moved to...
* gengtype.cc: ...here.
* genhooks.c: Moved to...
* genhooks.cc: ...here.
* genmatch.c: Moved to...
* genmatch.cc: ...here.
* genmddeps.c: Moved to...
* genmddeps.cc: ...here.
* genmddump.c: Moved to...
* genmddump.cc: ...here.
* genmodes.c: Moved to...
* genmodes.cc: ...here.
* genopinit.c: Moved to...
* genopinit.cc: ...here.
* genoutput.c: Moved to...
* genoutput.cc: ...here.
* genpeep.c: Moved to...
* genpeep.cc: ...here.
* genpreds.c: Moved to...
* genpreds.cc: ...here.
* genrecog.c: Moved to...
* genrecog.cc: ...here.
* gensupport.c: Moved to...
* gensupport.cc: ...here.
* gentarget-def.c: Moved to...
* gentarget-def.cc: ...here.
* genversion.c: Moved to...
* genversion.cc: ...here.
* ggc-common.c: Moved to...
* ggc-common.cc: ...here.
* ggc-none.c: Moved to...
* ggc-none.cc: ...here.
* ggc-page.c: Moved to...
* ggc-page.cc: ...here.
* ggc-tests.c: Moved to...
* ggc-tests.cc: ...here.
* gimple-builder.c: Moved to...
* gimple-builder.cc: ...here.
* gimple-expr.c: Moved to...
* gimple-expr.cc: ...here.
* gimple-fold.c: Moved to...
* gimple-fold.cc: ...here.
* gimple-iterator.c: Moved to...
* gimple-iterator.cc: ...here.
* gimple-laddress.c: Moved to...
* gimple-laddress.cc: ...here.
* gimple-loop-jam.c: Moved to...
* gimple-loop-jam.cc: ...here.
* gimple-low.c: Moved to...
* gimple-low.cc: ...here.
* gimple-match-head.c: Moved to...
* gimple-match-head.cc: ...here.
* gimple-pretty-print.c: Moved to...
* gimple-pretty-print.cc: ...here.
* gimple-ssa-backprop.c: Moved to...
* gimple-ssa-backprop.cc: ...here.
* gimple-ssa-evrp-analyze.c: Moved to...
* gimple-ssa-evrp-analyze.cc: ...here.
* gimple-ssa-evrp.c: Moved to...
* gimple-ssa-evrp.cc: ...here.
* gimple-ssa-isolate-paths.c: Moved to...
* gimple-ssa-isolate-paths.cc: ...here.
* gimple-ssa-nonnull-compare.c: Moved to...
* gimple-ssa-nonnull-compare.cc: ...here.
* gimple-ssa-split-paths.c: Moved to...
* gimple-ssa-split-paths.cc: ...here.
* gimple-ssa-sprintf.c: Moved to...
* gimple-ssa-sprintf.cc: ...here.
* gimple-ssa-store-merging.c: Moved to...
* gimple-ssa-store-merging.cc: ...here.
* gimple-ssa-strength-reduction.c: Moved to...
* gimple-ssa-strength-reduction.cc: ...here.
* gimple-ssa-warn-alloca.c: Moved to...
* gimple-ssa-warn-alloca.cc: ...here.
* gimple-ssa-warn-restrict.c: Moved to...
* gimple-ssa-warn-restrict.cc: ...here.
* gimple-streamer-in.c: Moved to...
* gimple-streamer-in.cc: ...here.
* gimple-streamer-out.c: Moved to...
* gimple-streamer-out.cc: ...here.
* gimple-walk.c: Moved to...
* gimple-walk.cc: ...here.
* gimple-warn-recursion.c: Moved to...
* gimple-warn-recursion.cc: ...here.
* gimple.c: Moved to...
* gimple.cc: ...here.
* gimplify-me.c: Moved to...
* gimplify-me.cc: ...here.
* gimplify.c: Moved to...
* gimplify.cc: ...here.
* godump.c: Moved to...
* godump.cc: ...here.
* graph.c: Moved to...
* graph.cc: ...here.
* graphds.c: Moved to...
* graphds.cc: ...here.
* graphite-dependences.c: Moved to...
* graphite-dependences.cc: ...here.
* graphite-isl-ast-to-gimple.c: Moved to...
* graphite-isl-ast-to-gimple.cc: ...here.
* graphite-optimize-isl.c: Moved to...
* graphite-optimize-isl.cc: ...here.
* graphite-poly.c: Moved to...
* graphite-poly.cc: ...here.
* graphite-scop-detection.c: Moved to...
* graphite-scop-detection.cc: ...here.
* graphite-sese-to-poly.c: Moved to...
* graphite-sese-to-poly.cc: ...here.
* graphite.c: Moved to...
* graphite.cc: ...here.
* haifa-sched.c: Moved to...
* haifa-sched.cc: ...here.
* hash-map-tests.c: Moved to...
* hash-map-tests.cc: ...here.
* hash-set-tests.c: Moved to...
* hash-set-tests.cc: ...here.
* hash-table.c: Moved to...
* hash-table.cc: ...here.
* hooks.c: Moved to...
* hooks.cc: ...here.
* host-default.c: Moved to...
* host-default.cc: ...here.
* hw-doloop.c: Moved to...
* hw-doloop.cc: ...here.
* hwint.c: Moved to...
* hwint.cc: ...here.
* ifcvt.c: Moved to...
* ifcvt.cc: ...here.
* inchash.c: Moved to...
* inchash.cc: ...here.
* incpath.c: Moved to...
* incpath.cc: ...here.
* init-regs.c: Moved to...
* init-regs.cc: ...here.
* input.c: Moved to...
* input.cc: ...here.
* internal-fn.c: Moved to...
* internal-fn.cc: ...here.
* intl.c: Moved to...
* intl.cc: ...here.
* ipa-comdats.c: Moved to...
* ipa-comdats.cc: ...here.
* ipa-cp.c: Moved to...
* ipa-cp.cc: ...here.
* ipa-devirt.c: Moved to...
* ipa-devirt.cc: ...here.
* ipa-fnsummary.c: Moved to...
* ipa-fnsummary.cc: ...here.
* ipa-icf-gimple.c: Moved to...
* ipa-icf-gimple.cc: ...here.
* ipa-icf.c: Moved to...
* ipa-icf.cc: ...here.
* ipa-inline-analysis.c: Moved to...
* ipa-inline-analysis.cc: ...here.
* ipa-inline-transform.c: Moved to...
* ipa-inline-transform.cc: ...here.
* ipa-inline.c: Moved to...
* ipa-inline.cc: ...here.
* ipa-modref-tree.c: Moved to...
* ipa-modref-tree.cc: ...here.
* ipa-modref.c: Moved to...
* ipa-modref.cc: ...here.
* ipa-param-manipulation.c: Moved to...
* ipa-param-manipulation.cc: ...here.
* ipa-polymorphic-call.c: Moved to...
* ipa-polymorphic-call.cc: ...here.
* ipa-predicate.c: Moved to...
* ipa-predicate.cc: ...here.
* ipa-profile.c: Moved to...
* ipa-profile.cc: ...here.
* ipa-prop.c: Moved to...
* ipa-prop.cc: ...here.
* ipa-pure-const.c: Moved to...
* ipa-pure-const.cc: ...here.
* ipa-ref.c: Moved to...
* ipa-ref.cc: ...here.
* ipa-reference.c: Moved to...
* ipa-reference.cc: ...here.
* ipa-split.c: Moved to...
* ipa-split.cc: ...here.
* ipa-sra.c: Moved to...
* ipa-sra.cc: ...here.
* ipa-utils.c: Moved to...
* ipa-utils.cc: ...here.
* ipa-visibility.c: Moved to...
* ipa-visibility.cc: ...here.
* ipa.c: Moved to...
* ipa.cc: ...here.
* ira-build.c: Moved to...
* ira-build.cc: ...here.
* ira-color.c: Moved to...
* ira-color.cc: ...here.
* ira-conflicts.c: Moved to...
* ira-conflicts.cc: ...here.
* ira-costs.c: Moved to...
* ira-costs.cc: ...here.
* ira-emit.c: Moved to...
* ira-emit.cc: ...here.
* ira-lives.c: Moved to...
* ira-lives.cc: ...here.
* ira.c: Moved to...
* ira.cc: ...here.
* jump.c: Moved to...
* jump.cc: ...here.
* langhooks.c: Moved to...
* langhooks.cc: ...here.
* lcm.c: Moved to...
* lcm.cc: ...here.
* lists.c: Moved to...
* lists.cc: ...here.
* loop-doloop.c: Moved to...
* loop-doloop.cc: ...here.
* loop-init.c: Moved to...
* loop-init.cc: ...here.
* loop-invariant.c: Moved to...
* loop-invariant.cc: ...here.
* loop-iv.c: Moved to...
* loop-iv.cc: ...here.
* loop-unroll.c: Moved to...
* loop-unroll.cc: ...here.
* lower-subreg.c: Moved to...
* lower-subreg.cc: ...here.
* lra-assigns.c: Moved to...
* lra-assigns.cc: ...here.
* lra-coalesce.c: Moved to...
* lra-coalesce.cc: ...here.
* lra-constraints.c: Moved to...
* lra-constraints.cc: ...here.
* lra-eliminations.c: Moved to...
* lra-eliminations.cc: ...here.
* lra-lives.c: Moved to...
* lra-lives.cc: ...here.
* lra-remat.c: Moved to...
* lra-remat.cc: ...here.
* lra-spills.c: Moved to...
* lra-spills.cc: ...here.
* lra.c: Moved to...
* lra.cc: ...here.
* lto-cgraph.c: Moved to...
* lto-cgraph.cc: ...here.
* lto-compress.c: Moved to...
* lto-compress.cc: ...here.
* lto-opts.c: Moved to...
* lto-opts.cc: ...here.
* lto-section-in.c: Moved to...
* lto-section-in.cc: ...here.
* lto-section-out.c: Moved to...
* lto-section-out.cc: ...here.
* lto-streamer-in.c: Moved to...
* lto-streamer-in.cc: ...here.
* lto-streamer-out.c: Moved to...
* lto-streamer-out.cc: ...here.
* lto-streamer.c: Moved to...
* lto-streamer.cc: ...here.
* lto-wrapper.c: Moved to...
* lto-wrapper.cc: ...here.
* main.c: Moved to...
* main.cc: ...here.
* mcf.c: Moved to...
* mcf.cc: ...here.
* mode-switching.c: Moved to...
* mode-switching.cc: ...here.
* modulo-sched.c: Moved to...
* modulo-sched.cc: ...here.
* multiple_target.c: Moved to...
* multiple_target.cc: ...here.
* omp-expand.c: Moved to...
* omp-expand.cc: ...here.
* omp-general.c: Moved to...
* omp-general.cc: ...here.
* omp-low.c: Moved to...
* omp-low.cc: ...here.
* omp-offload.c: Moved to...
* omp-offload.cc: ...here.
* omp-simd-clone.c: Moved to...
* omp-simd-clone.cc: ...here.
* opt-suggestions.c: Moved to...
* opt-suggestions.cc: ...here.
* optabs-libfuncs.c: Moved to...
* optabs-libfuncs.cc: ...here.
* optabs-query.c: Moved to...
* optabs-query.cc: ...here.
* optabs-tree.c: Moved to...
* optabs-tree.cc: ...here.
* optabs.c: Moved to...
* optabs.cc: ...here.
* opts-common.c: Moved to...
* opts-common.cc: ...here.
* opts-global.c: Moved to...
* opts-global.cc: ...here.
* opts.c: Moved to...
* opts.cc: ...here.
* passes.c: Moved to...
* passes.cc: ...here.
* plugin.c: Moved to...
* plugin.cc: ...here.
* postreload-gcse.c: Moved to...
* postreload-gcse.cc: ...here.
* postreload.c: Moved to...
* postreload.cc: ...here.
* predict.c: Moved to...
* predict.cc: ...here.
* prefix.c: Moved to...
* prefix.cc: ...here.
* pretty-print.c: Moved to...
* pretty-print.cc: ...here.
* print-rtl-function.c: Moved to...
* print-rtl-function.cc: ...here.
* print-rtl.c: Moved to...
* print-rtl.cc: ...here.
* print-tree.c: Moved to...
* print-tree.cc: ...here.
* profile-count.c: Moved to...
* profile-count.cc: ...here.
* profile.c: Moved to...
* profile.cc: ...here.
* read-md.c: Moved to...
* read-md.cc: ...here.
* read-rtl-function.c: Moved to...
* read-rtl-function.cc: ...here.
* read-rtl.c: Moved to...
* read-rtl.cc: ...here.
* real.c: Moved to...
* real.cc: ...here.
* realmpfr.c: Moved to...
* realmpfr.cc: ...here.
* recog.c: Moved to...
* recog.cc: ...here.
* ree.c: Moved to...
* ree.cc: ...here.
* reg-stack.c: Moved to...
* reg-stack.cc: ...here.
* regcprop.c: Moved to...
* regcprop.cc: ...here.
* reginfo.c: Moved to...
* reginfo.cc: ...here.
* regrename.c: Moved to...
* regrename.cc: ...here.
* regstat.c: Moved to...
* regstat.cc: ...here.
* reload.c: Moved to...
* reload.cc: ...here.
* reload1.c: Moved to...
* reload1.cc: ...here.
* reorg.c: Moved to...
* reorg.cc: ...here.
* resource.c: Moved to...
* resource.cc: ...here.
* rtl-error.c: Moved to...
* rtl-error.cc: ...here.
* rtl-tests.c: Moved to...
* rtl-tests.cc: ...here.
* rtl.c: Moved to...
* rtl.cc: ...here.
* rtlanal.c: Moved to...
* rtlanal.cc: ...here.
* rtlhash.c: Moved to...
* rtlhash.cc: ...here.
* rtlhooks.c: Moved to...
* rtlhooks.cc: ...here.
* rtx-vector-builder.c: Moved to...
* rtx-vector-builder.cc: ...here.
* run-rtl-passes.c: Moved to...
* run-rtl-passes.cc: ...here.
* sancov.c: Moved to...
* sancov.cc: ...here.
* sanopt.c: Moved to...
* sanopt.cc: ...here.
* sbitmap.c: Moved to...
* sbitmap.cc: ...here.
* sched-deps.c: Moved to...
* sched-deps.cc: ...here.
* sched-ebb.c: Moved to...
* sched-ebb.cc: ...here.
* sched-rgn.c: Moved to...
* sched-rgn.cc: ...here.
* sel-sched-dump.c: Moved to...
* sel-sched-dump.cc: ...here.
* sel-sched-ir.c: Moved to...
* sel-sched-ir.cc: ...here.
* sel-sched.c: Moved to...
* sel-sched.cc: ...here.
* selftest-diagnostic.c: Moved to...
* selftest-diagnostic.cc: ...here.
* selftest-rtl.c: Moved to...
* selftest-rtl.cc: ...here.
* selftest-run-tests.c: Moved to...
* selftest-run-tests.cc: ...here.
* selftest.c: Moved to...
* selftest.cc: ...here.
* sese.c: Moved to...
* sese.cc: ...here.
* shrink-wrap.c: Moved to...
* shrink-wrap.cc: ...here.
* simplify-rtx.c: Moved to...
* simplify-rtx.cc: ...here.
* sparseset.c: Moved to...
* sparseset.cc: ...here.
* spellcheck-tree.c: Moved to...
* spellcheck-tree.cc: ...here.
* spellcheck.c: Moved to...
* spellcheck.cc: ...here.
* sreal.c: Moved to...
* sreal.cc: ...here.
* stack-ptr-mod.c: Moved to...
* stack-ptr-mod.cc: ...here.
* statistics.c: Moved to...
* statistics.cc: ...here.
* stmt.c: Moved to...
* stmt.cc: ...here.
* stor-layout.c: Moved to...
* stor-layout.cc: ...here.
* store-motion.c: Moved to...
* store-motion.cc: ...here.
* streamer-hooks.c: Moved to...
* streamer-hooks.cc: ...here.
* stringpool.c: Moved to...
* stringpool.cc: ...here.
* substring-locations.c: Moved to...
* substring-locations.cc: ...here.
* symtab.c: Moved to...
* symtab.cc: ...here.
* target-globals.c: Moved to...
* target-globals.cc: ...here.
* targhooks.c: Moved to...
* targhooks.cc: ...here.
* timevar.c: Moved to...
* timevar.cc: ...here.
* toplev.c: Moved to...
* toplev.cc: ...here.
* tracer.c: Moved to...
* tracer.cc: ...here.
* trans-mem.c: Moved to...
* trans-mem.cc: ...here.
* tree-affine.c: Moved to...
* tree-affine.cc: ...here.
* tree-call-cdce.c: Moved to...
* tree-call-cdce.cc: ...here.
* tree-cfg.c: Moved to...
* tree-cfg.cc: ...here.
* tree-cfgcleanup.c: Moved to...
* tree-cfgcleanup.cc: ...here.
* tree-chrec.c: Moved to...
* tree-chrec.cc: ...here.
* tree-complex.c: Moved to...
* tree-complex.cc: ...here.
* tree-data-ref.c: Moved to...
* tree-data-ref.cc: ...here.
* tree-dfa.c: Moved to...
* tree-dfa.cc: ...here.
* tree-diagnostic.c: Moved to...
* tree-diagnostic.cc: ...here.
* tree-dump.c: Moved to...
* tree-dump.cc: ...here.
* tree-eh.c: Moved to...
* tree-eh.cc: ...here.
* tree-emutls.c: Moved to...
* tree-emutls.cc: ...here.
* tree-if-conv.c: Moved to...
* tree-if-conv.cc: ...here.
* tree-inline.c: Moved to...
* tree-inline.cc: ...here.
* tree-into-ssa.c: Moved to...
* tree-into-ssa.cc: ...here.
* tree-iterator.c: Moved to...
* tree-iterator.cc: ...here.
* tree-loop-distribution.c: Moved to...
* tree-loop-distribution.cc: ...here.
* tree-nested.c: Moved to...
* tree-nested.cc: ...here.
* tree-nrv.c: Moved to...
* tree-nrv.cc: ...here.
* tree-object-size.c: Moved to...
* tree-object-size.cc: ...here.
* tree-outof-ssa.c: Moved to...
* tree-outof-ssa.cc: ...here.
* tree-parloops.c: Moved to...
* tree-parloops.cc: ...here.
* tree-phinodes.c: Moved to...
* tree-phinodes.cc: ...here.
* tree-predcom.c: Moved to...
* tree-predcom.cc: ...here.
* tree-pretty-print.c: Moved to...
* tree-pretty-print.cc: ...here.
* tree-profile.c: Moved to...
* tree-profile.cc: ...here.
* tree-scalar-evolution.c: Moved to...
* tree-scalar-evolution.cc: ...here.
* tree-sra.c: Moved to...
* tree-sra.cc: ...here.
* tree-ssa-address.c: Moved to...
* tree-ssa-address.cc: ...here.
* tree-ssa-alias.c: Moved to...
* tree-ssa-alias.cc: ...here.
* tree-ssa-ccp.c: Moved to...
* tree-ssa-ccp.cc: ...here.
* tree-ssa-coalesce.c: Moved to...
* tree-ssa-coalesce.cc: ...here.
* tree-ssa-copy.c: Moved to...
* tree-ssa-copy.cc: ...here.
* tree-ssa-dce.c: Moved to...
* tree-ssa-dce.cc: ...here.
* tree-ssa-dom.c: Moved to...
* tree-ssa-dom.cc: ...here.
* tree-ssa-dse.c: Moved to...
* tree-ssa-dse.cc: ...here.
* tree-ssa-forwprop.c: Moved to...
* tree-ssa-forwprop.cc: ...here.
* tree-ssa-ifcombine.c: Moved to...
* tree-ssa-ifcombine.cc: ...here.
* tree-ssa-live.c: Moved to...
* tree-ssa-live.cc: ...here.
* tree-ssa-loop-ch.c: Moved to...
* tree-ssa-loop-ch.cc: ...here.
* tree-ssa-loop-im.c: Moved to...
* tree-ssa-loop-im.cc: ...here.
* tree-ssa-loop-ivcanon.c: Moved to...
* tree-ssa-loop-ivcanon.cc: ...here.
* tree-ssa-loop-ivopts.c: Moved to...
* tree-ssa-loop-ivopts.cc: ...here.
* tree-ssa-loop-manip.c: Moved to...
* tree-ssa-loop-manip.cc: ...here.
* tree-ssa-loop-niter.c: Moved to...
* tree-ssa-loop-niter.cc: ...here.
* tree-ssa-loop-prefetch.c: Moved to...
* tree-ssa-loop-prefetch.cc: ...here.
* tree-ssa-loop-split.c: Moved to...
* tree-ssa-loop-split.cc: ...here.
* tree-ssa-loop-unswitch.c: Moved to...
* tree-ssa-loop-unswitch.cc: ...here.
* tree-ssa-loop.c: Moved to...
* tree-ssa-loop.cc: ...here.
* tree-ssa-math-opts.c: Moved to...
* tree-ssa-math-opts.cc: ...here.
* tree-ssa-operands.c: Moved to...
* tree-ssa-operands.cc: ...here.
* tree-ssa-phiopt.c: Moved to...
* tree-ssa-phiopt.cc: ...here.
* tree-ssa-phiprop.c: Moved to...
* tree-ssa-phiprop.cc: ...here.
* tree-ssa-pre.c: Moved to...
* tree-ssa-pre.cc: ...here.
* tree-ssa-propagate.c: Moved to...
* tree-ssa-propagate.cc: ...here.
* tree-ssa-reassoc.c: Moved to...
* tree-ssa-reassoc.cc: ...here.
* tree-ssa-sccvn.c: Moved to...
* tree-ssa-sccvn.cc: ...here.
* tree-ssa-scopedtables.c: Moved to...
* tree-ssa-scopedtables.cc: ...here.
* tree-ssa-sink.c: Moved to...
* tree-ssa-sink.cc: ...here.
* tree-ssa-strlen.c: Moved to...
* tree-ssa-strlen.cc: ...here.
* tree-ssa-structalias.c: Moved to...
* tree-ssa-structalias.cc: ...here.
* tree-ssa-tail-merge.c: Moved to...
* tree-ssa-tail-merge.cc: ...here.
* tree-ssa-ter.c: Moved to...
* tree-ssa-ter.cc: ...here.
* tree-ssa-threadbackward.c: Moved to...
* tree-ssa-threadbackward.cc: ...here.
* tree-ssa-threadedge.c: Moved to...
* tree-ssa-threadedge.cc: ...here.
* tree-ssa-threadupdate.c: Moved to...
* tree-ssa-threadupdate.cc: ...here.
* tree-ssa-uncprop.c: Moved to...
* tree-ssa-uncprop.cc: ...here.
* tree-ssa-uninit.c: Moved to...
* tree-ssa-uninit.cc: ...here.
* tree-ssa.c: Moved to...
* tree-ssa.cc: ...here.
* tree-ssanames.c: Moved to...
* tree-ssanames.cc: ...here.
* tree-stdarg.c: Moved to...
* tree-stdarg.cc: ...here.
* tree-streamer-in.c: Moved to...
* tree-streamer-in.cc: ...here.
* tree-streamer-out.c: Moved to...
* tree-streamer-out.cc: ...here.
* tree-streamer.c: Moved to...
* tree-streamer.cc: ...here.
* tree-switch-conversion.c: Moved to...
* tree-switch-conversion.cc: ...here.
* tree-tailcall.c: Moved to...
* tree-tailcall.cc: ...here.
* tree-vect-data-refs.c: Moved to...
* tree-vect-data-refs.cc: ...here.
* tree-vect-generic.c: Moved to...
* tree-vect-generic.cc: ...here.
* tree-vect-loop-manip.c: Moved to...
* tree-vect-loop-manip.cc: ...here.
* tree-vect-loop.c: Moved to...
* tree-vect-loop.cc: ...here.
* tree-vect-patterns.c: Moved to...
* tree-vect-patterns.cc: ...here.
* tree-vect-slp-patterns.c: Moved to...
* tree-vect-slp-patterns.cc: ...here.
* tree-vect-slp.c: Moved to...
* tree-vect-slp.cc: ...here.
* tree-vect-stmts.c: Moved to...
* tree-vect-stmts.cc: ...here.
* tree-vector-builder.c: Moved to...
* tree-vector-builder.cc: ...here.
* tree-vectorizer.c: Moved to...
* tree-vectorizer.cc: ...here.
* tree-vrp.c: Moved to...
* tree-vrp.cc: ...here.
* tree.c: Moved to...
* tree.cc: ...here.
* tsan.c: Moved to...
* tsan.cc: ...here.
* typed-splay-tree.c: Moved to...
* typed-splay-tree.cc: ...here.
* ubsan.c: Moved to...
* ubsan.cc: ...here.
* valtrack.c: Moved to...
* valtrack.cc: ...here.
* value-prof.c: Moved to...
* value-prof.cc: ...here.
* var-tracking.c: Moved to...
* var-tracking.cc: ...here.
* varasm.c: Moved to...
* varasm.cc: ...here.
* varpool.c: Moved to...
* varpool.cc: ...here.
* vec-perm-indices.c: Moved to...
* vec-perm-indices.cc: ...here.
* vec.c: Moved to...
* vec.cc: ...here.
* vmsdbgout.c: Moved to...
* vmsdbgout.cc: ...here.
* vr-values.c: Moved to...
* vr-values.cc: ...here.
* vtable-verify.c: Moved to...
* vtable-verify.cc: ...here.
* web.c: Moved to...
* web.cc: ...here.
* xcoffout.c: Moved to...
* xcoffout.cc: ...here.
gcc/c-family/ChangeLog:
* c-ada-spec.c: Moved to...
* c-ada-spec.cc: ...here.
* c-attribs.c: Moved to...
* c-attribs.cc: ...here.
* c-common.c: Moved to...
* c-common.cc: ...here.
* c-cppbuiltin.c: Moved to...
* c-cppbuiltin.cc: ...here.
* c-dump.c: Moved to...
* c-dump.cc: ...here.
* c-format.c: Moved to...
* c-format.cc: ...here.
* c-gimplify.c: Moved to...
* c-gimplify.cc: ...here.
* c-indentation.c: Moved to...
* c-indentation.cc: ...here.
* c-lex.c: Moved to...
* c-lex.cc: ...here.
* c-omp.c: Moved to...
* c-omp.cc: ...here.
* c-opts.c: Moved to...
* c-opts.cc: ...here.
* c-pch.c: Moved to...
* c-pch.cc: ...here.
* c-ppoutput.c: Moved to...
* c-ppoutput.cc: ...here.
* c-pragma.c: Moved to...
* c-pragma.cc: ...here.
* c-pretty-print.c: Moved to...
* c-pretty-print.cc: ...here.
* c-semantics.c: Moved to...
* c-semantics.cc: ...here.
* c-ubsan.c: Moved to...
* c-ubsan.cc: ...here.
* c-warn.c: Moved to...
* c-warn.cc: ...here.
* cppspec.c: Moved to...
* cppspec.cc: ...here.
* stub-objc.c: Moved to...
* stub-objc.cc: ...here.
gcc/c/ChangeLog:
* c-aux-info.c: Moved to...
* c-aux-info.cc: ...here.
* c-convert.c: Moved to...
* c-convert.cc: ...here.
* c-decl.c: Moved to...
* c-decl.cc: ...here.
* c-errors.c: Moved to...
* c-errors.cc: ...here.
* c-fold.c: Moved to...
* c-fold.cc: ...here.
* c-lang.c: Moved to...
* c-lang.cc: ...here.
* c-objc-common.c: Moved to...
* c-objc-common.cc: ...here.
* c-parser.c: Moved to...
* c-parser.cc: ...here.
* c-typeck.c: Moved to...
* c-typeck.cc: ...here.
* gccspec.c: Moved to...
* gccspec.cc: ...here.
* gimple-parser.c: Moved to...
* gimple-parser.cc: ...here.
gcc/cp/ChangeLog:
* call.c: Moved to...
* call.cc: ...here.
* class.c: Moved to...
* class.cc: ...here.
* constexpr.c: Moved to...
* constexpr.cc: ...here.
* cp-gimplify.c: Moved to...
* cp-gimplify.cc: ...here.
* cp-lang.c: Moved to...
* cp-lang.cc: ...here.
* cp-objcp-common.c: Moved to...
* cp-objcp-common.cc: ...here.
* cp-ubsan.c: Moved to...
* cp-ubsan.cc: ...here.
* cvt.c: Moved to...
* cvt.cc: ...here.
* cxx-pretty-print.c: Moved to...
* cxx-pretty-print.cc: ...here.
* decl.c: Moved to...
* decl.cc: ...here.
* decl2.c: Moved to...
* decl2.cc: ...here.
* dump.c: Moved to...
* dump.cc: ...here.
* error.c: Moved to...
* error.cc: ...here.
* except.c: Moved to...
* except.cc: ...here.
* expr.c: Moved to...
* expr.cc: ...here.
* friend.c: Moved to...
* friend.cc: ...here.
* g++spec.c: Moved to...
* g++spec.cc: ...here.
* init.c: Moved to...
* init.cc: ...here.
* lambda.c: Moved to...
* lambda.cc: ...here.
* lex.c: Moved to...
* lex.cc: ...here.
* mangle.c: Moved to...
* mangle.cc: ...here.
* method.c: Moved to...
* method.cc: ...here.
* name-lookup.c: Moved to...
* name-lookup.cc: ...here.
* optimize.c: Moved to...
* optimize.cc: ...here.
* parser.c: Moved to...
* parser.cc: ...here.
* pt.c: Moved to...
* pt.cc: ...here.
* ptree.c: Moved to...
* ptree.cc: ...here.
* rtti.c: Moved to...
* rtti.cc: ...here.
* search.c: Moved to...
* search.cc: ...here.
* semantics.c: Moved to...
* semantics.cc: ...here.
* tree.c: Moved to...
* tree.cc: ...here.
* typeck.c: Moved to...
* typeck.cc: ...here.
* typeck2.c: Moved to...
* typeck2.cc: ...here.
* vtable-class-hierarchy.c: Moved to...
* vtable-class-hierarchy.cc: ...here.
gcc/fortran/ChangeLog:
* arith.c: Moved to...
* arith.cc: ...here.
* array.c: Moved to...
* array.cc: ...here.
* bbt.c: Moved to...
* bbt.cc: ...here.
* check.c: Moved to...
* check.cc: ...here.
* class.c: Moved to...
* class.cc: ...here.
* constructor.c: Moved to...
* constructor.cc: ...here.
* convert.c: Moved to...
* convert.cc: ...here.
* cpp.c: Moved to...
* cpp.cc: ...here.
* data.c: Moved to...
* data.cc: ...here.
* decl.c: Moved to...
* decl.cc: ...here.
* dependency.c: Moved to...
* dependency.cc: ...here.
* dump-parse-tree.c: Moved to...
* dump-parse-tree.cc: ...here.
* error.c: Moved to...
* error.cc: ...here.
* expr.c: Moved to...
* expr.cc: ...here.
* f95-lang.c: Moved to...
* f95-lang.cc: ...here.
* frontend-passes.c: Moved to...
* frontend-passes.cc: ...here.
* gfortranspec.c: Moved to...
* gfortranspec.cc: ...here.
* interface.c: Moved to...
* interface.cc: ...here.
* intrinsic.c: Moved to...
* intrinsic.cc: ...here.
* io.c: Moved to...
* io.cc: ...here.
* iresolve.c: Moved to...
* iresolve.cc: ...here.
* match.c: Moved to...
* match.cc: ...here.
* matchexp.c: Moved to...
* matchexp.cc: ...here.
* misc.c: Moved to...
* misc.cc: ...here.
* module.c: Moved to...
* module.cc: ...here.
* openmp.c: Moved to...
* openmp.cc: ...here.
* options.c: Moved to...
* options.cc: ...here.
* parse.c: Moved to...
* parse.cc: ...here.
* primary.c: Moved to...
* primary.cc: ...here.
* resolve.c: Moved to...
* resolve.cc: ...here.
* scanner.c: Moved to...
* scanner.cc: ...here.
* simplify.c: Moved to...
* simplify.cc: ...here.
* st.c: Moved to...
* st.cc: ...here.
* symbol.c: Moved to...
* symbol.cc: ...here.
* target-memory.c: Moved to...
* target-memory.cc: ...here.
* trans-array.c: Moved to...
* trans-array.cc: ...here.
* trans-common.c: Moved to...
* trans-common.cc: ...here.
* trans-const.c: Moved to...
* trans-const.cc: ...here.
* trans-decl.c: Moved to...
* trans-decl.cc: ...here.
* trans-expr.c: Moved to...
* trans-expr.cc: ...here.
* trans-intrinsic.c: Moved to...
* trans-intrinsic.cc: ...here.
* trans-io.c: Moved to...
* trans-io.cc: ...here.
* trans-openmp.c: Moved to...
* trans-openmp.cc: ...here.
* trans-stmt.c: Moved to...
* trans-stmt.cc: ...here.
* trans-types.c: Moved to...
* trans-types.cc: ...here.
* trans.c: Moved to...
* trans.cc: ...here.
gcc/go/ChangeLog:
* go-backend.c: Moved to...
* go-backend.cc: ...here.
* go-lang.c: Moved to...
* go-lang.cc: ...here.
* gospec.c: Moved to...
* gospec.cc: ...here.
gcc/jit/ChangeLog:
* dummy-frontend.c: Moved to...
* dummy-frontend.cc: ...here.
* jit-builtins.c: Moved to...
* jit-builtins.cc: ...here.
* jit-logging.c: Moved to...
* jit-logging.cc: ...here.
* jit-playback.c: Moved to...
* jit-playback.cc: ...here.
* jit-recording.c: Moved to...
* jit-recording.cc: ...here.
* jit-result.c: Moved to...
* jit-result.cc: ...here.
* jit-spec.c: Moved to...
* jit-spec.cc: ...here.
* jit-tempdir.c: Moved to...
* jit-tempdir.cc: ...here.
* jit-w32.c: Moved to...
* jit-w32.cc: ...here.
* libgccjit.c: Moved to...
* libgccjit.cc: ...here.
gcc/lto/ChangeLog:
* common.c: Moved to...
* common.cc: ...here.
* lto-common.c: Moved to...
* lto-common.cc: ...here.
* lto-dump.c: Moved to...
* lto-dump.cc: ...here.
* lto-lang.c: Moved to...
* lto-lang.cc: ...here.
* lto-object.c: Moved to...
* lto-object.cc: ...here.
* lto-partition.c: Moved to...
* lto-partition.cc: ...here.
* lto-symtab.c: Moved to...
* lto-symtab.cc: ...here.
* lto.c: Moved to...
* lto.cc: ...here.
gcc/objc/ChangeLog:
* objc-act.c: Moved to...
* objc-act.cc: ...here.
* objc-encoding.c: Moved to...
* objc-encoding.cc: ...here.
* objc-gnu-runtime-abi-01.c: Moved to...
* objc-gnu-runtime-abi-01.cc: ...here.
* objc-lang.c: Moved to...
* objc-lang.cc: ...here.
* objc-map.c: Moved to...
* objc-map.cc: ...here.
* objc-next-runtime-abi-01.c: Moved to...
* objc-next-runtime-abi-01.cc: ...here.
* objc-next-runtime-abi-02.c: Moved to...
* objc-next-runtime-abi-02.cc: ...here.
* objc-runtime-shared-support.c: Moved to...
* objc-runtime-shared-support.cc: ...here.
gcc/objcp/ChangeLog:
* objcp-decl.c: Moved to...
* objcp-decl.cc: ...here.
* objcp-lang.c: Moved to...
* objcp-lang.cc: ...here.
libcpp/ChangeLog:
* charset.c: Moved to...
* charset.cc: ...here.
* directives.c: Moved to...
* directives.cc: ...here.
* errors.c: Moved to...
* errors.cc: ...here.
* expr.c: Moved to...
* expr.cc: ...here.
* files.c: Moved to...
* files.cc: ...here.
* identifiers.c: Moved to...
* identifiers.cc: ...here.
* init.c: Moved to...
* init.cc: ...here.
* lex.c: Moved to...
* lex.cc: ...here.
* line-map.c: Moved to...
* line-map.cc: ...here.
* macro.c: Moved to...
* macro.cc: ...here.
* makeucnid.c: Moved to...
* makeucnid.cc: ...here.
* mkdeps.c: Moved to...
* mkdeps.cc: ...here.
* pch.c: Moved to...
* pch.cc: ...here.
* symtab.c: Moved to...
* symtab.cc: ...here.
* traditional.c: Moved to...
* traditional.cc: ...here.
Diffstat (limited to 'gcc/postreload.c')
-rw-r--r-- | gcc/postreload.c | 2371 |
1 files changed, 0 insertions, 2371 deletions
diff --git a/gcc/postreload.c b/gcc/postreload.c deleted file mode 100644 index 4a67d0d..0000000 --- a/gcc/postreload.c +++ /dev/null @@ -1,2371 +0,0 @@ -/* Perform simple optimizations to clean up the result of reload. - Copyright (C) 1987-2022 Free Software Foundation, Inc. - -This file is part of GCC. - -GCC is free software; you can redistribute it and/or modify it under -the terms of the GNU General Public License as published by the Free -Software Foundation; either version 3, or (at your option) any later -version. - -GCC is distributed in the hope that it will be useful, but WITHOUT ANY -WARRANTY; without even the implied warranty of MERCHANTABILITY or -FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License -for more details. - -You should have received a copy of the GNU General Public License -along with GCC; see the file COPYING3. If not see -<http://www.gnu.org/licenses/>. */ - -#include "config.h" -#include "system.h" -#include "coretypes.h" -#include "backend.h" -#include "target.h" -#include "rtl.h" -#include "tree.h" -#include "predict.h" -#include "df.h" -#include "memmodel.h" -#include "tm_p.h" -#include "optabs.h" -#include "regs.h" -#include "emit-rtl.h" -#include "recog.h" - -#include "cfgrtl.h" -#include "cfgbuild.h" -#include "cfgcleanup.h" -#include "reload.h" -#include "cselib.h" -#include "tree-pass.h" -#include "dbgcnt.h" -#include "function-abi.h" -#include "rtl-iter.h" - -static int reload_cse_noop_set_p (rtx); -static bool reload_cse_simplify (rtx_insn *, rtx); -static void reload_cse_regs_1 (void); -static int reload_cse_simplify_set (rtx, rtx_insn *); -static int reload_cse_simplify_operands (rtx_insn *, rtx); - -static void reload_combine (void); -static void reload_combine_note_use (rtx *, rtx_insn *, int, rtx); -static void reload_combine_note_store (rtx, const_rtx, void *); - -static bool reload_cse_move2add (rtx_insn *); -static void move2add_note_store (rtx, const_rtx, void *); - -/* Call cse / combine like post-reload optimization phases. - FIRST is the first instruction. */ - -static void -reload_cse_regs (rtx_insn *first ATTRIBUTE_UNUSED) -{ - bool moves_converted; - reload_cse_regs_1 (); - reload_combine (); - moves_converted = reload_cse_move2add (first); - if (flag_expensive_optimizations) - { - if (moves_converted) - reload_combine (); - reload_cse_regs_1 (); - } -} - -/* See whether a single set SET is a noop. */ -static int -reload_cse_noop_set_p (rtx set) -{ - if (cselib_reg_set_mode (SET_DEST (set)) != GET_MODE (SET_DEST (set))) - return 0; - - return rtx_equal_for_cselib_p (SET_DEST (set), SET_SRC (set)); -} - -/* Try to simplify INSN. Return true if the CFG may have changed. */ -static bool -reload_cse_simplify (rtx_insn *insn, rtx testreg) -{ - rtx body = PATTERN (insn); - basic_block insn_bb = BLOCK_FOR_INSN (insn); - unsigned insn_bb_succs = EDGE_COUNT (insn_bb->succs); - - /* If NO_FUNCTION_CSE has been set by the target, then we should not try - to cse function calls. */ - if (NO_FUNCTION_CSE && CALL_P (insn)) - return false; - - /* Remember if this insn has been sp += const_int. */ - rtx sp_set = set_for_reg_notes (insn); - rtx sp_addend = NULL_RTX; - if (sp_set - && SET_DEST (sp_set) == stack_pointer_rtx - && GET_CODE (SET_SRC (sp_set)) == PLUS - && XEXP (SET_SRC (sp_set), 0) == stack_pointer_rtx - && CONST_INT_P (XEXP (SET_SRC (sp_set), 1))) - sp_addend = XEXP (SET_SRC (sp_set), 1); - - if (GET_CODE (body) == SET) - { - int count = 0; - - /* Simplify even if we may think it is a no-op. - We may think a memory load of a value smaller than WORD_SIZE - is redundant because we haven't taken into account possible - implicit extension. reload_cse_simplify_set() will bring - this out, so it's safer to simplify before we delete. */ - count += reload_cse_simplify_set (body, insn); - - if (!count && reload_cse_noop_set_p (body)) - { - if (check_for_inc_dec (insn)) - delete_insn_and_edges (insn); - /* We're done with this insn. */ - goto done; - } - - if (count > 0) - apply_change_group (); - else - reload_cse_simplify_operands (insn, testreg); - } - else if (GET_CODE (body) == PARALLEL) - { - int i; - int count = 0; - rtx value = NULL_RTX; - - /* Registers mentioned in the clobber list for an asm cannot be reused - within the body of the asm. Invalidate those registers now so that - we don't try to substitute values for them. */ - if (asm_noperands (body) >= 0) - { - for (i = XVECLEN (body, 0) - 1; i >= 0; --i) - { - rtx part = XVECEXP (body, 0, i); - if (GET_CODE (part) == CLOBBER && REG_P (XEXP (part, 0))) - cselib_invalidate_rtx (XEXP (part, 0)); - } - } - - /* If every action in a PARALLEL is a noop, we can delete - the entire PARALLEL. */ - for (i = XVECLEN (body, 0) - 1; i >= 0; --i) - { - rtx part = XVECEXP (body, 0, i); - if (GET_CODE (part) == SET) - { - if (! reload_cse_noop_set_p (part)) - break; - if (REG_P (SET_DEST (part)) - && REG_FUNCTION_VALUE_P (SET_DEST (part))) - { - if (value) - break; - value = SET_DEST (part); - } - } - else if (GET_CODE (part) != CLOBBER && GET_CODE (part) != USE) - break; - } - - if (i < 0) - { - if (check_for_inc_dec (insn)) - delete_insn_and_edges (insn); - /* We're done with this insn. */ - goto done; - } - - /* It's not a no-op, but we can try to simplify it. */ - for (i = XVECLEN (body, 0) - 1; i >= 0; --i) - if (GET_CODE (XVECEXP (body, 0, i)) == SET) - count += reload_cse_simplify_set (XVECEXP (body, 0, i), insn); - - if (count > 0) - apply_change_group (); - else - reload_cse_simplify_operands (insn, testreg); - } - - /* If sp += const_int insn is changed into sp = reg;, add REG_EQUAL - note so that the stack_adjustments pass can undo it if beneficial. */ - if (sp_addend - && SET_DEST (sp_set) == stack_pointer_rtx - && REG_P (SET_SRC (sp_set))) - set_dst_reg_note (insn, REG_EQUAL, - gen_rtx_PLUS (Pmode, stack_pointer_rtx, - sp_addend), stack_pointer_rtx); - -done: - return (EDGE_COUNT (insn_bb->succs) != insn_bb_succs); -} - -/* Do a very simple CSE pass over the hard registers. - - This function detects no-op moves where we happened to assign two - different pseudo-registers to the same hard register, and then - copied one to the other. Reload will generate a useless - instruction copying a register to itself. - - This function also detects cases where we load a value from memory - into two different registers, and (if memory is more expensive than - registers) changes it to simply copy the first register into the - second register. - - Another optimization is performed that scans the operands of each - instruction to see whether the value is already available in a - hard register. It then replaces the operand with the hard register - if possible, much like an optional reload would. */ - -static void -reload_cse_regs_1 (void) -{ - bool cfg_changed = false; - basic_block bb; - rtx_insn *insn; - rtx testreg = gen_rtx_REG (word_mode, LAST_VIRTUAL_REGISTER + 1); - - cselib_init (CSELIB_RECORD_MEMORY); - init_alias_analysis (); - - FOR_EACH_BB_FN (bb, cfun) - FOR_BB_INSNS (bb, insn) - { - if (INSN_P (insn)) - cfg_changed |= reload_cse_simplify (insn, testreg); - - cselib_process_insn (insn); - } - - /* Clean up. */ - end_alias_analysis (); - cselib_finish (); - if (cfg_changed) - cleanup_cfg (0); -} - -/* Try to simplify a single SET instruction. SET is the set pattern. - INSN is the instruction it came from. - This function only handles one case: if we set a register to a value - which is not a register, we try to find that value in some other register - and change the set into a register copy. */ - -static int -reload_cse_simplify_set (rtx set, rtx_insn *insn) -{ - int did_change = 0; - int dreg; - rtx src; - reg_class_t dclass; - int old_cost; - cselib_val *val; - struct elt_loc_list *l; - enum rtx_code extend_op = UNKNOWN; - bool speed = optimize_bb_for_speed_p (BLOCK_FOR_INSN (insn)); - - dreg = true_regnum (SET_DEST (set)); - if (dreg < 0) - return 0; - - src = SET_SRC (set); - if (side_effects_p (src) || true_regnum (src) >= 0) - return 0; - - dclass = REGNO_REG_CLASS (dreg); - - /* When replacing a memory with a register, we need to honor assumptions - that combine made wrt the contents of sign bits. We'll do this by - generating an extend instruction instead of a reg->reg copy. Thus - the destination must be a register that we can widen. */ - if (MEM_P (src) - && (extend_op = load_extend_op (GET_MODE (src))) != UNKNOWN - && !REG_P (SET_DEST (set))) - return 0; - - val = cselib_lookup (src, GET_MODE (SET_DEST (set)), 0, VOIDmode); - if (! val) - return 0; - - /* If memory loads are cheaper than register copies, don't change them. */ - if (MEM_P (src)) - old_cost = memory_move_cost (GET_MODE (src), dclass, true); - else if (REG_P (src)) - old_cost = register_move_cost (GET_MODE (src), - REGNO_REG_CLASS (REGNO (src)), dclass); - else - old_cost = set_src_cost (src, GET_MODE (SET_DEST (set)), speed); - - for (l = val->locs; l; l = l->next) - { - rtx this_rtx = l->loc; - int this_cost; - - if (CONSTANT_P (this_rtx) && ! references_value_p (this_rtx, 0)) - { - if (extend_op != UNKNOWN) - { - wide_int result; - - if (!CONST_SCALAR_INT_P (this_rtx)) - continue; - - switch (extend_op) - { - case ZERO_EXTEND: - result = wide_int::from (rtx_mode_t (this_rtx, - GET_MODE (src)), - BITS_PER_WORD, UNSIGNED); - break; - case SIGN_EXTEND: - result = wide_int::from (rtx_mode_t (this_rtx, - GET_MODE (src)), - BITS_PER_WORD, SIGNED); - break; - default: - gcc_unreachable (); - } - this_rtx = immed_wide_int_const (result, word_mode); - } - - this_cost = set_src_cost (this_rtx, GET_MODE (SET_DEST (set)), speed); - } - else if (REG_P (this_rtx)) - { - if (extend_op != UNKNOWN) - { - this_rtx = gen_rtx_fmt_e (extend_op, word_mode, this_rtx); - this_cost = set_src_cost (this_rtx, word_mode, speed); - } - else - this_cost = register_move_cost (GET_MODE (this_rtx), - REGNO_REG_CLASS (REGNO (this_rtx)), - dclass); - } - else - continue; - - /* If equal costs, prefer registers over anything else. That - tends to lead to smaller instructions on some machines. */ - if (this_cost < old_cost - || (this_cost == old_cost - && REG_P (this_rtx) - && !REG_P (SET_SRC (set)))) - { - if (extend_op != UNKNOWN - && REG_CAN_CHANGE_MODE_P (REGNO (SET_DEST (set)), - GET_MODE (SET_DEST (set)), word_mode)) - { - rtx wide_dest = gen_rtx_REG (word_mode, REGNO (SET_DEST (set))); - ORIGINAL_REGNO (wide_dest) = ORIGINAL_REGNO (SET_DEST (set)); - validate_change (insn, &SET_DEST (set), wide_dest, 1); - } - - validate_unshare_change (insn, &SET_SRC (set), this_rtx, 1); - old_cost = this_cost, did_change = 1; - } - } - - return did_change; -} - -/* Try to replace operands in INSN with equivalent values that are already - in registers. This can be viewed as optional reloading. - - For each non-register operand in the insn, see if any hard regs are - known to be equivalent to that operand. Record the alternatives which - can accept these hard registers. Among all alternatives, select the - ones which are better or equal to the one currently matching, where - "better" is in terms of '?' and '!' constraints. Among the remaining - alternatives, select the one which replaces most operands with - hard registers. */ - -static int -reload_cse_simplify_operands (rtx_insn *insn, rtx testreg) -{ - int i, j; - - /* For each operand, all registers that are equivalent to it. */ - HARD_REG_SET equiv_regs[MAX_RECOG_OPERANDS]; - - const char *constraints[MAX_RECOG_OPERANDS]; - - /* Vector recording how bad an alternative is. */ - int *alternative_reject; - /* Vector recording how many registers can be introduced by choosing - this alternative. */ - int *alternative_nregs; - /* Array of vectors recording, for each operand and each alternative, - which hard register to substitute, or -1 if the operand should be - left as it is. */ - int *op_alt_regno[MAX_RECOG_OPERANDS]; - /* Array of alternatives, sorted in order of decreasing desirability. */ - int *alternative_order; - - extract_constrain_insn (insn); - - if (recog_data.n_alternatives == 0 || recog_data.n_operands == 0) - return 0; - - alternative_reject = XALLOCAVEC (int, recog_data.n_alternatives); - alternative_nregs = XALLOCAVEC (int, recog_data.n_alternatives); - alternative_order = XALLOCAVEC (int, recog_data.n_alternatives); - memset (alternative_reject, 0, recog_data.n_alternatives * sizeof (int)); - memset (alternative_nregs, 0, recog_data.n_alternatives * sizeof (int)); - - /* For each operand, find out which regs are equivalent. */ - for (i = 0; i < recog_data.n_operands; i++) - { - cselib_val *v; - struct elt_loc_list *l; - rtx op; - - CLEAR_HARD_REG_SET (equiv_regs[i]); - - /* cselib blows up on CODE_LABELs. Trying to fix that doesn't seem - right, so avoid the problem here. Similarly NOTE_INSN_DELETED_LABEL. - Likewise if we have a constant and the insn pattern doesn't tell us - the mode we need. */ - if (LABEL_P (recog_data.operand[i]) - || (NOTE_P (recog_data.operand[i]) - && NOTE_KIND (recog_data.operand[i]) == NOTE_INSN_DELETED_LABEL) - || (CONSTANT_P (recog_data.operand[i]) - && recog_data.operand_mode[i] == VOIDmode)) - continue; - - op = recog_data.operand[i]; - if (MEM_P (op) && load_extend_op (GET_MODE (op)) != UNKNOWN) - { - rtx set = single_set (insn); - - /* We might have multiple sets, some of which do implicit - extension. Punt on this for now. */ - if (! set) - continue; - /* If the destination is also a MEM or a STRICT_LOW_PART, no - extension applies. - Also, if there is an explicit extension, we don't have to - worry about an implicit one. */ - else if (MEM_P (SET_DEST (set)) - || GET_CODE (SET_DEST (set)) == STRICT_LOW_PART - || GET_CODE (SET_SRC (set)) == ZERO_EXTEND - || GET_CODE (SET_SRC (set)) == SIGN_EXTEND) - ; /* Continue ordinary processing. */ - /* If the register cannot change mode to word_mode, it follows that - it cannot have been used in word_mode. */ - else if (REG_P (SET_DEST (set)) - && !REG_CAN_CHANGE_MODE_P (REGNO (SET_DEST (set)), - GET_MODE (SET_DEST (set)), - word_mode)) - ; /* Continue ordinary processing. */ - /* If this is a straight load, make the extension explicit. */ - else if (REG_P (SET_DEST (set)) - && recog_data.n_operands == 2 - && SET_SRC (set) == op - && SET_DEST (set) == recog_data.operand[1-i]) - { - validate_change (insn, recog_data.operand_loc[i], - gen_rtx_fmt_e (load_extend_op (GET_MODE (op)), - word_mode, op), - 1); - validate_change (insn, recog_data.operand_loc[1-i], - gen_rtx_REG (word_mode, REGNO (SET_DEST (set))), - 1); - if (! apply_change_group ()) - return 0; - return reload_cse_simplify_operands (insn, testreg); - } - else - /* ??? There might be arithmetic operations with memory that are - safe to optimize, but is it worth the trouble? */ - continue; - } - - if (side_effects_p (op)) - continue; - v = cselib_lookup (op, recog_data.operand_mode[i], 0, VOIDmode); - if (! v) - continue; - - for (l = v->locs; l; l = l->next) - if (REG_P (l->loc)) - SET_HARD_REG_BIT (equiv_regs[i], REGNO (l->loc)); - } - - alternative_mask preferred = get_preferred_alternatives (insn); - for (i = 0; i < recog_data.n_operands; i++) - { - machine_mode mode; - int regno; - const char *p; - - op_alt_regno[i] = XALLOCAVEC (int, recog_data.n_alternatives); - for (j = 0; j < recog_data.n_alternatives; j++) - op_alt_regno[i][j] = -1; - - p = constraints[i] = recog_data.constraints[i]; - mode = recog_data.operand_mode[i]; - - /* Add the reject values for each alternative given by the constraints - for this operand. */ - j = 0; - while (*p != '\0') - { - char c = *p++; - if (c == ',') - j++; - else if (c == '?') - alternative_reject[j] += 3; - else if (c == '!') - alternative_reject[j] += 300; - } - - /* We won't change operands which are already registers. We - also don't want to modify output operands. */ - regno = true_regnum (recog_data.operand[i]); - if (regno >= 0 - || constraints[i][0] == '=' - || constraints[i][0] == '+') - continue; - - for (regno = 0; regno < FIRST_PSEUDO_REGISTER; regno++) - { - enum reg_class rclass = NO_REGS; - - if (! TEST_HARD_REG_BIT (equiv_regs[i], regno)) - continue; - - set_mode_and_regno (testreg, mode, regno); - - /* We found a register equal to this operand. Now look for all - alternatives that can accept this register and have not been - assigned a register they can use yet. */ - j = 0; - p = constraints[i]; - for (;;) - { - char c = *p; - - switch (c) - { - case 'g': - rclass = reg_class_subunion[rclass][GENERAL_REGS]; - break; - - default: - rclass - = (reg_class_subunion - [rclass] - [reg_class_for_constraint (lookup_constraint (p))]); - break; - - case ',': case '\0': - /* See if REGNO fits this alternative, and set it up as the - replacement register if we don't have one for this - alternative yet and the operand being replaced is not - a cheap CONST_INT. */ - if (op_alt_regno[i][j] == -1 - && TEST_BIT (preferred, j) - && reg_fits_class_p (testreg, rclass, 0, mode) - && (!CONST_INT_P (recog_data.operand[i]) - || (set_src_cost (recog_data.operand[i], mode, - optimize_bb_for_speed_p - (BLOCK_FOR_INSN (insn))) - > set_src_cost (testreg, mode, - optimize_bb_for_speed_p - (BLOCK_FOR_INSN (insn)))))) - { - alternative_nregs[j]++; - op_alt_regno[i][j] = regno; - } - j++; - rclass = NO_REGS; - break; - } - p += CONSTRAINT_LEN (c, p); - - if (c == '\0') - break; - } - } - } - - /* The loop below sets alternative_order[0] but -Wmaybe-uninitialized - can't know that. Clear it here to avoid the warning. */ - alternative_order[0] = 0; - gcc_assert (!recog_data.n_alternatives - || (which_alternative >= 0 - && which_alternative < recog_data.n_alternatives)); - - /* Record all alternatives which are better or equal to the currently - matching one in the alternative_order array. */ - for (i = j = 0; i < recog_data.n_alternatives; i++) - if (alternative_reject[i] <= alternative_reject[which_alternative]) - alternative_order[j++] = i; - recog_data.n_alternatives = j; - - /* Sort it. Given a small number of alternatives, a dumb algorithm - won't hurt too much. */ - for (i = 0; i < recog_data.n_alternatives - 1; i++) - { - int best = i; - int best_reject = alternative_reject[alternative_order[i]]; - int best_nregs = alternative_nregs[alternative_order[i]]; - - for (j = i + 1; j < recog_data.n_alternatives; j++) - { - int this_reject = alternative_reject[alternative_order[j]]; - int this_nregs = alternative_nregs[alternative_order[j]]; - - if (this_reject < best_reject - || (this_reject == best_reject && this_nregs > best_nregs)) - { - best = j; - best_reject = this_reject; - best_nregs = this_nregs; - } - } - - std::swap (alternative_order[best], alternative_order[i]); - } - - /* Substitute the operands as determined by op_alt_regno for the best - alternative. */ - j = alternative_order[0]; - - for (i = 0; i < recog_data.n_operands; i++) - { - machine_mode mode = recog_data.operand_mode[i]; - if (op_alt_regno[i][j] == -1) - continue; - - validate_change (insn, recog_data.operand_loc[i], - gen_rtx_REG (mode, op_alt_regno[i][j]), 1); - } - - for (i = recog_data.n_dups - 1; i >= 0; i--) - { - int op = recog_data.dup_num[i]; - machine_mode mode = recog_data.operand_mode[op]; - - if (op_alt_regno[op][j] == -1) - continue; - - validate_change (insn, recog_data.dup_loc[i], - gen_rtx_REG (mode, op_alt_regno[op][j]), 1); - } - - return apply_change_group (); -} - -/* If reload couldn't use reg+reg+offset addressing, try to use reg+reg - addressing now. - This code might also be useful when reload gave up on reg+reg addressing - because of clashes between the return register and INDEX_REG_CLASS. */ - -/* The maximum number of uses of a register we can keep track of to - replace them with reg+reg addressing. */ -#define RELOAD_COMBINE_MAX_USES 16 - -/* Describes a recorded use of a register. */ -struct reg_use -{ - /* The insn where a register has been used. */ - rtx_insn *insn; - /* Points to the memory reference enclosing the use, if any, NULL_RTX - otherwise. */ - rtx containing_mem; - /* Location of the register within INSN. */ - rtx *usep; - /* The reverse uid of the insn. */ - int ruid; -}; - -/* If the register is used in some unknown fashion, USE_INDEX is negative. - If it is dead, USE_INDEX is RELOAD_COMBINE_MAX_USES, and STORE_RUID - indicates where it is first set or clobbered. - Otherwise, USE_INDEX is the index of the last encountered use of the - register (which is first among these we have seen since we scan backwards). - USE_RUID indicates the first encountered, i.e. last, of these uses. - If ALL_OFFSETS_MATCH is true, all encountered uses were inside a PLUS - with a constant offset; OFFSET contains this constant in that case. - STORE_RUID is always meaningful if we only want to use a value in a - register in a different place: it denotes the next insn in the insn - stream (i.e. the last encountered) that sets or clobbers the register. - REAL_STORE_RUID is similar, but clobbers are ignored when updating it. - EXPR is the expression used when storing the register. */ -static struct - { - struct reg_use reg_use[RELOAD_COMBINE_MAX_USES]; - rtx offset; - int use_index; - int store_ruid; - int real_store_ruid; - int use_ruid; - bool all_offsets_match; - rtx expr; - } reg_state[FIRST_PSEUDO_REGISTER]; - -/* Reverse linear uid. This is increased in reload_combine while scanning - the instructions from last to first. It is used to set last_label_ruid - and the store_ruid / use_ruid fields in reg_state. */ -static int reload_combine_ruid; - -/* The RUID of the last label we encountered in reload_combine. */ -static int last_label_ruid; - -/* The RUID of the last jump we encountered in reload_combine. */ -static int last_jump_ruid; - -/* The register numbers of the first and last index register. A value of - -1 in LAST_INDEX_REG indicates that we've previously computed these - values and found no suitable index registers. */ -static int first_index_reg = -1; -static int last_index_reg; - -#define LABEL_LIVE(LABEL) \ - (label_live[CODE_LABEL_NUMBER (LABEL) - min_labelno]) - -/* Subroutine of reload_combine_split_ruids, called to fix up a single - ruid pointed to by *PRUID if it is higher than SPLIT_RUID. */ - -static inline void -reload_combine_split_one_ruid (int *pruid, int split_ruid) -{ - if (*pruid > split_ruid) - (*pruid)++; -} - -/* Called when we insert a new insn in a position we've already passed in - the scan. Examine all our state, increasing all ruids that are higher - than SPLIT_RUID by one in order to make room for a new insn. */ - -static void -reload_combine_split_ruids (int split_ruid) -{ - unsigned i; - - reload_combine_split_one_ruid (&reload_combine_ruid, split_ruid); - reload_combine_split_one_ruid (&last_label_ruid, split_ruid); - reload_combine_split_one_ruid (&last_jump_ruid, split_ruid); - - for (i = 0; i < FIRST_PSEUDO_REGISTER; i++) - { - int j, idx = reg_state[i].use_index; - reload_combine_split_one_ruid (®_state[i].use_ruid, split_ruid); - reload_combine_split_one_ruid (®_state[i].store_ruid, split_ruid); - reload_combine_split_one_ruid (®_state[i].real_store_ruid, - split_ruid); - if (idx < 0) - continue; - for (j = idx; j < RELOAD_COMBINE_MAX_USES; j++) - { - reload_combine_split_one_ruid (®_state[i].reg_use[j].ruid, - split_ruid); - } - } -} - -/* Called when we are about to rescan a previously encountered insn with - reload_combine_note_use after modifying some part of it. This clears all - information about uses in that particular insn. */ - -static void -reload_combine_purge_insn_uses (rtx_insn *insn) -{ - unsigned i; - - for (i = 0; i < FIRST_PSEUDO_REGISTER; i++) - { - int j, k, idx = reg_state[i].use_index; - if (idx < 0) - continue; - j = k = RELOAD_COMBINE_MAX_USES; - while (j-- > idx) - { - if (reg_state[i].reg_use[j].insn != insn) - { - k--; - if (k != j) - reg_state[i].reg_use[k] = reg_state[i].reg_use[j]; - } - } - reg_state[i].use_index = k; - } -} - -/* Called when we need to forget about all uses of REGNO after an insn - which is identified by RUID. */ - -static void -reload_combine_purge_reg_uses_after_ruid (unsigned regno, int ruid) -{ - int j, k, idx = reg_state[regno].use_index; - if (idx < 0) - return; - j = k = RELOAD_COMBINE_MAX_USES; - while (j-- > idx) - { - if (reg_state[regno].reg_use[j].ruid >= ruid) - { - k--; - if (k != j) - reg_state[regno].reg_use[k] = reg_state[regno].reg_use[j]; - } - } - reg_state[regno].use_index = k; -} - -/* Find the use of REGNO with the ruid that is highest among those - lower than RUID_LIMIT, and return it if it is the only use of this - reg in the insn. Return NULL otherwise. */ - -static struct reg_use * -reload_combine_closest_single_use (unsigned regno, int ruid_limit) -{ - int i, best_ruid = 0; - int use_idx = reg_state[regno].use_index; - struct reg_use *retval; - - if (use_idx < 0) - return NULL; - retval = NULL; - for (i = use_idx; i < RELOAD_COMBINE_MAX_USES; i++) - { - struct reg_use *use = reg_state[regno].reg_use + i; - int this_ruid = use->ruid; - if (this_ruid >= ruid_limit) - continue; - if (this_ruid > best_ruid) - { - best_ruid = this_ruid; - retval = use; - } - else if (this_ruid == best_ruid) - retval = NULL; - } - if (last_label_ruid >= best_ruid) - return NULL; - return retval; -} - -/* After we've moved an add insn, fix up any debug insns that occur - between the old location of the add and the new location. REG is - the destination register of the add insn; REPLACEMENT is the - SET_SRC of the add. FROM and TO specify the range in which we - should make this change on debug insns. */ - -static void -fixup_debug_insns (rtx reg, rtx replacement, rtx_insn *from, rtx_insn *to) -{ - rtx_insn *insn; - for (insn = from; insn != to; insn = NEXT_INSN (insn)) - { - rtx t; - - if (!DEBUG_BIND_INSN_P (insn)) - continue; - - t = INSN_VAR_LOCATION_LOC (insn); - t = simplify_replace_rtx (t, reg, replacement); - validate_change (insn, &INSN_VAR_LOCATION_LOC (insn), t, 0); - } -} - -/* Subroutine of reload_combine_recognize_const_pattern. Try to replace REG - with SRC in the insn described by USE, taking costs into account. Return - true if we made the replacement. */ - -static bool -try_replace_in_use (struct reg_use *use, rtx reg, rtx src) -{ - rtx_insn *use_insn = use->insn; - rtx mem = use->containing_mem; - bool speed = optimize_bb_for_speed_p (BLOCK_FOR_INSN (use_insn)); - - if (mem != NULL_RTX) - { - addr_space_t as = MEM_ADDR_SPACE (mem); - rtx oldaddr = XEXP (mem, 0); - rtx newaddr = NULL_RTX; - int old_cost = address_cost (oldaddr, GET_MODE (mem), as, speed); - int new_cost; - - newaddr = simplify_replace_rtx (oldaddr, reg, src); - if (memory_address_addr_space_p (GET_MODE (mem), newaddr, as)) - { - XEXP (mem, 0) = newaddr; - new_cost = address_cost (newaddr, GET_MODE (mem), as, speed); - XEXP (mem, 0) = oldaddr; - if (new_cost <= old_cost - && validate_change (use_insn, - &XEXP (mem, 0), newaddr, 0)) - return true; - } - } - else - { - rtx new_set = single_set (use_insn); - if (new_set - && REG_P (SET_DEST (new_set)) - && GET_CODE (SET_SRC (new_set)) == PLUS - && REG_P (XEXP (SET_SRC (new_set), 0)) - && CONSTANT_P (XEXP (SET_SRC (new_set), 1))) - { - rtx new_src; - machine_mode mode = GET_MODE (SET_DEST (new_set)); - int old_cost = set_src_cost (SET_SRC (new_set), mode, speed); - - gcc_assert (rtx_equal_p (XEXP (SET_SRC (new_set), 0), reg)); - new_src = simplify_replace_rtx (SET_SRC (new_set), reg, src); - - if (set_src_cost (new_src, mode, speed) <= old_cost - && validate_change (use_insn, &SET_SRC (new_set), - new_src, 0)) - return true; - } - } - return false; -} - -/* Called by reload_combine when scanning INSN. This function tries to detect - patterns where a constant is added to a register, and the result is used - in an address. - Return true if no further processing is needed on INSN; false if it wasn't - recognized and should be handled normally. */ - -static bool -reload_combine_recognize_const_pattern (rtx_insn *insn) -{ - int from_ruid = reload_combine_ruid; - rtx set, pat, reg, src, addreg; - unsigned int regno; - struct reg_use *use; - bool must_move_add; - rtx_insn *add_moved_after_insn = NULL; - int add_moved_after_ruid = 0; - int clobbered_regno = -1; - - set = single_set (insn); - if (set == NULL_RTX) - return false; - - reg = SET_DEST (set); - src = SET_SRC (set); - if (!REG_P (reg) - || REG_NREGS (reg) != 1 - || GET_MODE (reg) != Pmode - || reg == stack_pointer_rtx) - return false; - - regno = REGNO (reg); - - /* We look for a REG1 = REG2 + CONSTANT insn, followed by either - uses of REG1 inside an address, or inside another add insn. If - possible and profitable, merge the addition into subsequent - uses. */ - if (GET_CODE (src) != PLUS - || !REG_P (XEXP (src, 0)) - || !CONSTANT_P (XEXP (src, 1))) - return false; - - addreg = XEXP (src, 0); - must_move_add = rtx_equal_p (reg, addreg); - - pat = PATTERN (insn); - if (must_move_add && set != pat) - { - /* We have to be careful when moving the add; apart from the - single_set there may also be clobbers. Recognize one special - case, that of one clobber alongside the set (likely a clobber - of the CC register). */ - gcc_assert (GET_CODE (PATTERN (insn)) == PARALLEL); - if (XVECLEN (pat, 0) != 2 || XVECEXP (pat, 0, 0) != set - || GET_CODE (XVECEXP (pat, 0, 1)) != CLOBBER - || !REG_P (XEXP (XVECEXP (pat, 0, 1), 0))) - return false; - clobbered_regno = REGNO (XEXP (XVECEXP (pat, 0, 1), 0)); - } - - do - { - use = reload_combine_closest_single_use (regno, from_ruid); - - if (use) - /* Start the search for the next use from here. */ - from_ruid = use->ruid; - - if (use && GET_MODE (*use->usep) == Pmode) - { - bool delete_add = false; - rtx_insn *use_insn = use->insn; - int use_ruid = use->ruid; - - /* Avoid moving the add insn past a jump. */ - if (must_move_add && use_ruid <= last_jump_ruid) - break; - - /* If the add clobbers another hard reg in parallel, don't move - it past a real set of this hard reg. */ - if (must_move_add && clobbered_regno >= 0 - && reg_state[clobbered_regno].real_store_ruid >= use_ruid) - break; - - gcc_assert (reg_state[regno].store_ruid <= use_ruid); - /* Avoid moving a use of ADDREG past a point where it is stored. */ - if (reg_state[REGNO (addreg)].store_ruid > use_ruid) - break; - - /* We also must not move the addition past an insn that sets - the same register, unless we can combine two add insns. */ - if (must_move_add && reg_state[regno].store_ruid == use_ruid) - { - if (use->containing_mem == NULL_RTX) - delete_add = true; - else - break; - } - - if (try_replace_in_use (use, reg, src)) - { - reload_combine_purge_insn_uses (use_insn); - reload_combine_note_use (&PATTERN (use_insn), use_insn, - use_ruid, NULL_RTX); - - if (delete_add) - { - fixup_debug_insns (reg, src, insn, use_insn); - delete_insn (insn); - return true; - } - if (must_move_add) - { - add_moved_after_insn = use_insn; - add_moved_after_ruid = use_ruid; - } - continue; - } - } - /* If we get here, we couldn't handle this use. */ - if (must_move_add) - break; - } - while (use); - - if (!must_move_add || add_moved_after_insn == NULL_RTX) - /* Process the add normally. */ - return false; - - fixup_debug_insns (reg, src, insn, add_moved_after_insn); - - reorder_insns (insn, insn, add_moved_after_insn); - reload_combine_purge_reg_uses_after_ruid (regno, add_moved_after_ruid); - reload_combine_split_ruids (add_moved_after_ruid - 1); - reload_combine_note_use (&PATTERN (insn), insn, - add_moved_after_ruid, NULL_RTX); - reg_state[regno].store_ruid = add_moved_after_ruid; - - return true; -} - -/* Called by reload_combine when scanning INSN. Try to detect a pattern we - can handle and improve. Return true if no further processing is needed on - INSN; false if it wasn't recognized and should be handled normally. */ - -static bool -reload_combine_recognize_pattern (rtx_insn *insn) -{ - rtx set, reg, src; - - set = single_set (insn); - if (set == NULL_RTX) - return false; - - reg = SET_DEST (set); - src = SET_SRC (set); - if (!REG_P (reg) || REG_NREGS (reg) != 1) - return false; - - unsigned int regno = REGNO (reg); - machine_mode mode = GET_MODE (reg); - - if (reg_state[regno].use_index < 0 - || reg_state[regno].use_index >= RELOAD_COMBINE_MAX_USES) - return false; - - for (int i = reg_state[regno].use_index; - i < RELOAD_COMBINE_MAX_USES; i++) - { - struct reg_use *use = reg_state[regno].reg_use + i; - if (GET_MODE (*use->usep) != mode) - return false; - /* Don't try to adjust (use (REGX)). */ - if (GET_CODE (PATTERN (use->insn)) == USE - && &XEXP (PATTERN (use->insn), 0) == use->usep) - return false; - } - - /* Look for (set (REGX) (CONST_INT)) - (set (REGX) (PLUS (REGX) (REGY))) - ... - ... (MEM (REGX)) ... - and convert it to - (set (REGZ) (CONST_INT)) - ... - ... (MEM (PLUS (REGZ) (REGY)))... . - - First, check that we have (set (REGX) (PLUS (REGX) (REGY))) - and that we know all uses of REGX before it dies. - Also, explicitly check that REGX != REGY; our life information - does not yet show whether REGY changes in this insn. */ - - if (GET_CODE (src) == PLUS - && reg_state[regno].all_offsets_match - && last_index_reg != -1 - && REG_P (XEXP (src, 1)) - && rtx_equal_p (XEXP (src, 0), reg) - && !rtx_equal_p (XEXP (src, 1), reg) - && last_label_ruid < reg_state[regno].use_ruid) - { - rtx base = XEXP (src, 1); - rtx_insn *prev = prev_nonnote_nondebug_insn (insn); - rtx prev_set = prev ? single_set (prev) : NULL_RTX; - rtx index_reg = NULL_RTX; - rtx reg_sum = NULL_RTX; - int i; - - /* Now we need to set INDEX_REG to an index register (denoted as - REGZ in the illustration above) and REG_SUM to the expression - register+register that we want to use to substitute uses of REG - (typically in MEMs) with. First check REG and BASE for being - index registers; we can use them even if they are not dead. */ - if (TEST_HARD_REG_BIT (reg_class_contents[INDEX_REG_CLASS], regno) - || TEST_HARD_REG_BIT (reg_class_contents[INDEX_REG_CLASS], - REGNO (base))) - { - index_reg = reg; - reg_sum = src; - } - else - { - /* Otherwise, look for a free index register. Since we have - checked above that neither REG nor BASE are index registers, - if we find anything at all, it will be different from these - two registers. */ - for (i = first_index_reg; i <= last_index_reg; i++) - { - if (TEST_HARD_REG_BIT (reg_class_contents[INDEX_REG_CLASS], i) - && reg_state[i].use_index == RELOAD_COMBINE_MAX_USES - && reg_state[i].store_ruid <= reg_state[regno].use_ruid - && (crtl->abi->clobbers_full_reg_p (i) - || df_regs_ever_live_p (i)) - && (!frame_pointer_needed || i != HARD_FRAME_POINTER_REGNUM) - && !fixed_regs[i] && !global_regs[i] - && hard_regno_nregs (i, GET_MODE (reg)) == 1 - && targetm.hard_regno_scratch_ok (i)) - { - index_reg = gen_rtx_REG (GET_MODE (reg), i); - reg_sum = gen_rtx_PLUS (GET_MODE (reg), index_reg, base); - break; - } - } - } - - /* Check that PREV_SET is indeed (set (REGX) (CONST_INT)) and that - (REGY), i.e. BASE, is not clobbered before the last use we'll - create. */ - if (reg_sum - && prev_set - && CONST_INT_P (SET_SRC (prev_set)) - && rtx_equal_p (SET_DEST (prev_set), reg) - && (reg_state[REGNO (base)].store_ruid - <= reg_state[regno].use_ruid)) - { - /* Change destination register and, if necessary, the constant - value in PREV, the constant loading instruction. */ - validate_change (prev, &SET_DEST (prev_set), index_reg, 1); - if (reg_state[regno].offset != const0_rtx) - { - HOST_WIDE_INT c - = trunc_int_for_mode (UINTVAL (SET_SRC (prev_set)) - + UINTVAL (reg_state[regno].offset), - GET_MODE (index_reg)); - validate_change (prev, &SET_SRC (prev_set), GEN_INT (c), 1); - } - - /* Now for every use of REG that we have recorded, replace REG - with REG_SUM. */ - for (i = reg_state[regno].use_index; - i < RELOAD_COMBINE_MAX_USES; i++) - validate_unshare_change (reg_state[regno].reg_use[i].insn, - reg_state[regno].reg_use[i].usep, - /* Each change must have its own - replacement. */ - reg_sum, 1); - - if (apply_change_group ()) - { - struct reg_use *lowest_ruid = NULL; - - /* For every new use of REG_SUM, we have to record the use - of BASE therein, i.e. operand 1. */ - for (i = reg_state[regno].use_index; - i < RELOAD_COMBINE_MAX_USES; i++) - { - struct reg_use *use = reg_state[regno].reg_use + i; - reload_combine_note_use (&XEXP (*use->usep, 1), use->insn, - use->ruid, use->containing_mem); - if (lowest_ruid == NULL || use->ruid < lowest_ruid->ruid) - lowest_ruid = use; - } - - fixup_debug_insns (reg, reg_sum, insn, lowest_ruid->insn); - - /* Delete the reg-reg addition. */ - delete_insn (insn); - - if (reg_state[regno].offset != const0_rtx) - /* Previous REG_EQUIV / REG_EQUAL notes for PREV - are now invalid. */ - remove_reg_equal_equiv_notes (prev); - - reg_state[regno].use_index = RELOAD_COMBINE_MAX_USES; - return true; - } - } - } - return false; -} - -static void -reload_combine (void) -{ - rtx_insn *insn, *prev; - basic_block bb; - unsigned int r; - int min_labelno, n_labels; - HARD_REG_SET ever_live_at_start, *label_live; - - /* To avoid wasting too much time later searching for an index register, - determine the minimum and maximum index register numbers. */ - if (INDEX_REG_CLASS == NO_REGS) - last_index_reg = -1; - else if (first_index_reg == -1 && last_index_reg == 0) - { - for (r = 0; r < FIRST_PSEUDO_REGISTER; r++) - if (TEST_HARD_REG_BIT (reg_class_contents[INDEX_REG_CLASS], r)) - { - if (first_index_reg == -1) - first_index_reg = r; - - last_index_reg = r; - } - - /* If no index register is available, we can quit now. Set LAST_INDEX_REG - to -1 so we'll know to quit early the next time we get here. */ - if (first_index_reg == -1) - { - last_index_reg = -1; - return; - } - } - - /* Set up LABEL_LIVE and EVER_LIVE_AT_START. The register lifetime - information is a bit fuzzy immediately after reload, but it's - still good enough to determine which registers are live at a jump - destination. */ - min_labelno = get_first_label_num (); - n_labels = max_label_num () - min_labelno; - label_live = XNEWVEC (HARD_REG_SET, n_labels); - CLEAR_HARD_REG_SET (ever_live_at_start); - - FOR_EACH_BB_REVERSE_FN (bb, cfun) - { - insn = BB_HEAD (bb); - if (LABEL_P (insn)) - { - HARD_REG_SET live; - bitmap live_in = df_get_live_in (bb); - - REG_SET_TO_HARD_REG_SET (live, live_in); - compute_use_by_pseudos (&live, live_in); - LABEL_LIVE (insn) = live; - ever_live_at_start |= live; - } - } - - /* Initialize last_label_ruid, reload_combine_ruid and reg_state. */ - last_label_ruid = last_jump_ruid = reload_combine_ruid = 0; - for (r = 0; r < FIRST_PSEUDO_REGISTER; r++) - { - reg_state[r].store_ruid = 0; - reg_state[r].real_store_ruid = 0; - if (fixed_regs[r]) - reg_state[r].use_index = -1; - else - reg_state[r].use_index = RELOAD_COMBINE_MAX_USES; - } - - for (insn = get_last_insn (); insn; insn = prev) - { - bool control_flow_insn; - rtx note; - - prev = PREV_INSN (insn); - - /* We cannot do our optimization across labels. Invalidating all the use - information we have would be costly, so we just note where the label - is and then later disable any optimization that would cross it. */ - if (LABEL_P (insn)) - last_label_ruid = reload_combine_ruid; - else if (BARRIER_P (insn)) - { - /* Crossing a barrier resets all the use information. */ - for (r = 0; r < FIRST_PSEUDO_REGISTER; r++) - if (! fixed_regs[r]) - reg_state[r].use_index = RELOAD_COMBINE_MAX_USES; - } - else if (INSN_P (insn) && volatile_insn_p (PATTERN (insn))) - /* Optimizations across insns being marked as volatile must be - prevented. All the usage information is invalidated - here. */ - for (r = 0; r < FIRST_PSEUDO_REGISTER; r++) - if (! fixed_regs[r] - && reg_state[r].use_index != RELOAD_COMBINE_MAX_USES) - reg_state[r].use_index = -1; - - if (! NONDEBUG_INSN_P (insn)) - continue; - - reload_combine_ruid++; - - control_flow_insn = control_flow_insn_p (insn); - if (control_flow_insn) - last_jump_ruid = reload_combine_ruid; - - if (reload_combine_recognize_const_pattern (insn) - || reload_combine_recognize_pattern (insn)) - continue; - - note_stores (insn, reload_combine_note_store, NULL); - - if (CALL_P (insn)) - { - rtx link; - HARD_REG_SET used_regs = insn_callee_abi (insn).full_reg_clobbers (); - - for (r = 0; r < FIRST_PSEUDO_REGISTER; r++) - if (TEST_HARD_REG_BIT (used_regs, r)) - { - reg_state[r].use_index = RELOAD_COMBINE_MAX_USES; - reg_state[r].store_ruid = reload_combine_ruid; - } - - for (link = CALL_INSN_FUNCTION_USAGE (insn); link; - link = XEXP (link, 1)) - { - rtx setuse = XEXP (link, 0); - rtx usage_rtx = XEXP (setuse, 0); - - if (GET_CODE (setuse) == USE && REG_P (usage_rtx)) - { - unsigned int end_regno = END_REGNO (usage_rtx); - for (unsigned int i = REGNO (usage_rtx); i < end_regno; ++i) - reg_state[i].use_index = -1; - } - } - } - - if (control_flow_insn && !ANY_RETURN_P (PATTERN (insn))) - { - /* Non-spill registers might be used at the call destination in - some unknown fashion, so we have to mark the unknown use. */ - HARD_REG_SET *live; - - if ((condjump_p (insn) || condjump_in_parallel_p (insn)) - && JUMP_LABEL (insn)) - { - if (ANY_RETURN_P (JUMP_LABEL (insn))) - live = NULL; - else - live = &LABEL_LIVE (JUMP_LABEL (insn)); - } - else - live = &ever_live_at_start; - - if (live) - for (r = 0; r < FIRST_PSEUDO_REGISTER; r++) - if (TEST_HARD_REG_BIT (*live, r)) - reg_state[r].use_index = -1; - } - - reload_combine_note_use (&PATTERN (insn), insn, reload_combine_ruid, - NULL_RTX); - - for (note = REG_NOTES (insn); note; note = XEXP (note, 1)) - { - if (REG_NOTE_KIND (note) == REG_INC && REG_P (XEXP (note, 0))) - { - int regno = REGNO (XEXP (note, 0)); - reg_state[regno].store_ruid = reload_combine_ruid; - reg_state[regno].real_store_ruid = reload_combine_ruid; - reg_state[regno].use_index = -1; - } - } - } - - free (label_live); -} - -/* Check if DST is a register or a subreg of a register; if it is, - update store_ruid, real_store_ruid and use_index in the reg_state - structure accordingly. Called via note_stores from reload_combine. */ - -static void -reload_combine_note_store (rtx dst, const_rtx set, void *data ATTRIBUTE_UNUSED) -{ - int regno = 0; - int i; - machine_mode mode = GET_MODE (dst); - - if (GET_CODE (dst) == SUBREG) - { - regno = subreg_regno_offset (REGNO (SUBREG_REG (dst)), - GET_MODE (SUBREG_REG (dst)), - SUBREG_BYTE (dst), - GET_MODE (dst)); - dst = SUBREG_REG (dst); - } - - /* Some targets do argument pushes without adding REG_INC notes. */ - - if (MEM_P (dst)) - { - dst = XEXP (dst, 0); - if (GET_CODE (dst) == PRE_INC || GET_CODE (dst) == POST_INC - || GET_CODE (dst) == PRE_DEC || GET_CODE (dst) == POST_DEC - || GET_CODE (dst) == PRE_MODIFY || GET_CODE (dst) == POST_MODIFY) - { - unsigned int end_regno = END_REGNO (XEXP (dst, 0)); - for (unsigned int i = REGNO (XEXP (dst, 0)); i < end_regno; ++i) - { - /* We could probably do better, but for now mark the register - as used in an unknown fashion and set/clobbered at this - insn. */ - reg_state[i].use_index = -1; - reg_state[i].store_ruid = reload_combine_ruid; - reg_state[i].real_store_ruid = reload_combine_ruid; - } - } - else - return; - } - - if (!REG_P (dst)) - return; - regno += REGNO (dst); - - /* note_stores might have stripped a STRICT_LOW_PART, so we have to be - careful with registers / register parts that are not full words. - Similarly for ZERO_EXTRACT. */ - if (GET_CODE (SET_DEST (set)) == ZERO_EXTRACT - || GET_CODE (SET_DEST (set)) == STRICT_LOW_PART) - { - for (i = end_hard_regno (mode, regno) - 1; i >= regno; i--) - { - reg_state[i].use_index = -1; - reg_state[i].store_ruid = reload_combine_ruid; - reg_state[i].real_store_ruid = reload_combine_ruid; - } - } - else - { - for (i = end_hard_regno (mode, regno) - 1; i >= regno; i--) - { - reg_state[i].store_ruid = reload_combine_ruid; - if (GET_CODE (set) == SET) - reg_state[i].real_store_ruid = reload_combine_ruid; - reg_state[i].use_index = RELOAD_COMBINE_MAX_USES; - } - } -} - -/* XP points to a piece of rtl that has to be checked for any uses of - registers. - *XP is the pattern of INSN, or a part of it. - Called from reload_combine, and recursively by itself. */ -static void -reload_combine_note_use (rtx *xp, rtx_insn *insn, int ruid, rtx containing_mem) -{ - rtx x = *xp; - enum rtx_code code = x->code; - const char *fmt; - int i, j; - rtx offset = const0_rtx; /* For the REG case below. */ - - switch (code) - { - case SET: - if (REG_P (SET_DEST (x))) - { - reload_combine_note_use (&SET_SRC (x), insn, ruid, NULL_RTX); - return; - } - break; - - case USE: - /* If this is the USE of a return value, we can't change it. */ - if (REG_P (XEXP (x, 0)) && REG_FUNCTION_VALUE_P (XEXP (x, 0))) - { - /* Mark the return register as used in an unknown fashion. */ - rtx reg = XEXP (x, 0); - unsigned int end_regno = END_REGNO (reg); - for (unsigned int regno = REGNO (reg); regno < end_regno; ++regno) - reg_state[regno].use_index = -1; - return; - } - break; - - case CLOBBER: - if (REG_P (SET_DEST (x))) - { - /* No spurious CLOBBERs of pseudo registers may remain. */ - gcc_assert (REGNO (SET_DEST (x)) < FIRST_PSEUDO_REGISTER); - return; - } - break; - - case PLUS: - /* We are interested in (plus (reg) (const_int)) . */ - if (!REG_P (XEXP (x, 0)) - || !CONST_INT_P (XEXP (x, 1))) - break; - offset = XEXP (x, 1); - x = XEXP (x, 0); - /* Fall through. */ - case REG: - { - int regno = REGNO (x); - int use_index; - int nregs; - - /* No spurious USEs of pseudo registers may remain. */ - gcc_assert (regno < FIRST_PSEUDO_REGISTER); - - nregs = REG_NREGS (x); - - /* We can't substitute into multi-hard-reg uses. */ - if (nregs > 1) - { - while (--nregs >= 0) - reg_state[regno + nregs].use_index = -1; - return; - } - - /* We may be called to update uses in previously seen insns. - Don't add uses beyond the last store we saw. */ - if (ruid < reg_state[regno].store_ruid) - return; - - /* If this register is already used in some unknown fashion, we - can't do anything. - If we decrement the index from zero to -1, we can't store more - uses, so this register becomes used in an unknown fashion. */ - use_index = --reg_state[regno].use_index; - if (use_index < 0) - return; - - if (use_index == RELOAD_COMBINE_MAX_USES - 1) - { - /* This is the first use of this register we have seen since we - marked it as dead. */ - reg_state[regno].offset = offset; - reg_state[regno].all_offsets_match = true; - reg_state[regno].use_ruid = ruid; - } - else - { - if (reg_state[regno].use_ruid > ruid) - reg_state[regno].use_ruid = ruid; - - if (! rtx_equal_p (offset, reg_state[regno].offset)) - reg_state[regno].all_offsets_match = false; - } - - reg_state[regno].reg_use[use_index].insn = insn; - reg_state[regno].reg_use[use_index].ruid = ruid; - reg_state[regno].reg_use[use_index].containing_mem = containing_mem; - reg_state[regno].reg_use[use_index].usep = xp; - return; - } - - case MEM: - containing_mem = x; - break; - - default: - break; - } - - /* Recursively process the components of X. */ - fmt = GET_RTX_FORMAT (code); - for (i = GET_RTX_LENGTH (code) - 1; i >= 0; i--) - { - if (fmt[i] == 'e') - reload_combine_note_use (&XEXP (x, i), insn, ruid, containing_mem); - else if (fmt[i] == 'E') - { - for (j = XVECLEN (x, i) - 1; j >= 0; j--) - reload_combine_note_use (&XVECEXP (x, i, j), insn, ruid, - containing_mem); - } - } -} - -/* See if we can reduce the cost of a constant by replacing a move - with an add. We track situations in which a register is set to a - constant or to a register plus a constant. */ -/* We cannot do our optimization across labels. Invalidating all the - information about register contents we have would be costly, so we - use move2add_last_label_luid to note where the label is and then - later disable any optimization that would cross it. - reg_offset[n] / reg_base_reg[n] / reg_symbol_ref[n] / reg_mode[n] - are only valid if reg_set_luid[n] is greater than - move2add_last_label_luid. - For a set that established a new (potential) base register with - non-constant value, we use move2add_luid from the place where the - setting insn is encountered; registers based off that base then - get the same reg_set_luid. Constants all get - move2add_last_label_luid + 1 as their reg_set_luid. */ -static int reg_set_luid[FIRST_PSEUDO_REGISTER]; - -/* If reg_base_reg[n] is negative, register n has been set to - reg_offset[n] or reg_symbol_ref[n] + reg_offset[n] in mode reg_mode[n]. - If reg_base_reg[n] is non-negative, register n has been set to the - sum of reg_offset[n] and the value of register reg_base_reg[n] - before reg_set_luid[n], calculated in mode reg_mode[n] . - For multi-hard-register registers, all but the first one are - recorded as BLKmode in reg_mode. Setting reg_mode to VOIDmode - marks it as invalid. */ -static HOST_WIDE_INT reg_offset[FIRST_PSEUDO_REGISTER]; -static int reg_base_reg[FIRST_PSEUDO_REGISTER]; -static rtx reg_symbol_ref[FIRST_PSEUDO_REGISTER]; -static machine_mode reg_mode[FIRST_PSEUDO_REGISTER]; - -/* move2add_luid is linearly increased while scanning the instructions - from first to last. It is used to set reg_set_luid in - reload_cse_move2add and move2add_note_store. */ -static int move2add_luid; - -/* move2add_last_label_luid is set whenever a label is found. Labels - invalidate all previously collected reg_offset data. */ -static int move2add_last_label_luid; - -/* ??? We don't know how zero / sign extension is handled, hence we - can't go from a narrower to a wider mode. */ -#define MODES_OK_FOR_MOVE2ADD(OUTMODE, INMODE) \ - (GET_MODE_SIZE (OUTMODE) == GET_MODE_SIZE (INMODE) \ - || (GET_MODE_SIZE (OUTMODE) <= GET_MODE_SIZE (INMODE) \ - && TRULY_NOOP_TRUNCATION_MODES_P (OUTMODE, INMODE))) - -/* Record that REG is being set to a value with the mode of REG. */ - -static void -move2add_record_mode (rtx reg) -{ - int regno, nregs; - machine_mode mode = GET_MODE (reg); - - if (GET_CODE (reg) == SUBREG) - { - regno = subreg_regno (reg); - nregs = subreg_nregs (reg); - } - else if (REG_P (reg)) - { - regno = REGNO (reg); - nregs = REG_NREGS (reg); - } - else - gcc_unreachable (); - for (int i = nregs - 1; i > 0; i--) - reg_mode[regno + i] = BLKmode; - reg_mode[regno] = mode; -} - -/* Record that REG is being set to the sum of SYM and OFF. */ - -static void -move2add_record_sym_value (rtx reg, rtx sym, rtx off) -{ - int regno = REGNO (reg); - - move2add_record_mode (reg); - reg_set_luid[regno] = move2add_luid; - reg_base_reg[regno] = -1; - reg_symbol_ref[regno] = sym; - reg_offset[regno] = INTVAL (off); -} - -/* Check if REGNO contains a valid value in MODE. */ - -static bool -move2add_valid_value_p (int regno, scalar_int_mode mode) -{ - if (reg_set_luid[regno] <= move2add_last_label_luid) - return false; - - if (mode != reg_mode[regno]) - { - scalar_int_mode old_mode; - if (!is_a <scalar_int_mode> (reg_mode[regno], &old_mode) - || !MODES_OK_FOR_MOVE2ADD (mode, old_mode) - || !REG_CAN_CHANGE_MODE_P (regno, old_mode, mode)) - return false; - /* The value loaded into regno in reg_mode[regno] is also valid in - mode after truncation only if (REG:mode regno) is the lowpart of - (REG:reg_mode[regno] regno). Now, for big endian, the starting - regno of the lowpart might be different. */ - poly_int64 s_off = subreg_lowpart_offset (mode, old_mode); - s_off = subreg_regno_offset (regno, old_mode, s_off, mode); - if (maybe_ne (s_off, 0)) - /* We could in principle adjust regno, check reg_mode[regno] to be - BLKmode, and return s_off to the caller (vs. -1 for failure), - but we currently have no callers that could make use of this - information. */ - return false; - } - - for (int i = end_hard_regno (mode, regno) - 1; i > regno; i--) - if (reg_mode[i] != BLKmode) - return false; - return true; -} - -/* This function is called with INSN that sets REG (of mode MODE) - to (SYM + OFF), while REG is known to already have value (SYM + offset). - This function tries to change INSN into an add instruction - (set (REG) (plus (REG) (OFF - offset))) using the known value. - It also updates the information about REG's known value. - Return true if we made a change. */ - -static bool -move2add_use_add2_insn (scalar_int_mode mode, rtx reg, rtx sym, rtx off, - rtx_insn *insn) -{ - rtx pat = PATTERN (insn); - rtx src = SET_SRC (pat); - int regno = REGNO (reg); - rtx new_src = gen_int_mode (UINTVAL (off) - reg_offset[regno], mode); - bool speed = optimize_bb_for_speed_p (BLOCK_FOR_INSN (insn)); - bool changed = false; - - /* (set (reg) (plus (reg) (const_int 0))) is not canonical; - use (set (reg) (reg)) instead. - We don't delete this insn, nor do we convert it into a - note, to avoid losing register notes or the return - value flag. jump2 already knows how to get rid of - no-op moves. */ - if (new_src == const0_rtx) - { - /* If the constants are different, this is a - truncation, that, if turned into (set (reg) - (reg)), would be discarded. Maybe we should - try a truncMN pattern? */ - if (INTVAL (off) == reg_offset [regno]) - changed = validate_change (insn, &SET_SRC (pat), reg, 0); - } - else - { - struct full_rtx_costs oldcst, newcst; - rtx tem = gen_rtx_PLUS (mode, reg, new_src); - - get_full_set_rtx_cost (pat, &oldcst); - SET_SRC (pat) = tem; - get_full_set_rtx_cost (pat, &newcst); - SET_SRC (pat) = src; - - if (costs_lt_p (&newcst, &oldcst, speed) - && have_add2_insn (reg, new_src)) - changed = validate_change (insn, &SET_SRC (pat), tem, 0); - else if (sym == NULL_RTX && mode != BImode) - { - scalar_int_mode narrow_mode; - FOR_EACH_MODE_UNTIL (narrow_mode, mode) - { - if (have_insn_for (STRICT_LOW_PART, narrow_mode) - && ((reg_offset[regno] & ~GET_MODE_MASK (narrow_mode)) - == (INTVAL (off) & ~GET_MODE_MASK (narrow_mode)))) - { - rtx narrow_reg = gen_lowpart_common (narrow_mode, reg); - rtx narrow_src = gen_int_mode (INTVAL (off), - narrow_mode); - rtx new_set - = gen_rtx_SET (gen_rtx_STRICT_LOW_PART (VOIDmode, - narrow_reg), - narrow_src); - get_full_set_rtx_cost (new_set, &newcst); - if (costs_lt_p (&newcst, &oldcst, speed)) - { - changed = validate_change (insn, &PATTERN (insn), - new_set, 0); - if (changed) - break; - } - } - } - } - } - move2add_record_sym_value (reg, sym, off); - return changed; -} - - -/* This function is called with INSN that sets REG (of mode MODE) to - (SYM + OFF), but REG doesn't have known value (SYM + offset). This - function tries to find another register which is known to already have - value (SYM + offset) and change INSN into an add instruction - (set (REG) (plus (the found register) (OFF - offset))) if such - a register is found. It also updates the information about - REG's known value. - Return true iff we made a change. */ - -static bool -move2add_use_add3_insn (scalar_int_mode mode, rtx reg, rtx sym, rtx off, - rtx_insn *insn) -{ - rtx pat = PATTERN (insn); - rtx src = SET_SRC (pat); - int regno = REGNO (reg); - int min_regno = 0; - bool speed = optimize_bb_for_speed_p (BLOCK_FOR_INSN (insn)); - int i; - bool changed = false; - struct full_rtx_costs oldcst, newcst, mincst; - rtx plus_expr; - - init_costs_to_max (&mincst); - get_full_set_rtx_cost (pat, &oldcst); - - plus_expr = gen_rtx_PLUS (GET_MODE (reg), reg, const0_rtx); - SET_SRC (pat) = plus_expr; - - for (i = 0; i < FIRST_PSEUDO_REGISTER; i++) - if (move2add_valid_value_p (i, mode) - && reg_base_reg[i] < 0 - && reg_symbol_ref[i] != NULL_RTX - && rtx_equal_p (sym, reg_symbol_ref[i])) - { - rtx new_src = gen_int_mode (UINTVAL (off) - reg_offset[i], - GET_MODE (reg)); - /* (set (reg) (plus (reg) (const_int 0))) is not canonical; - use (set (reg) (reg)) instead. - We don't delete this insn, nor do we convert it into a - note, to avoid losing register notes or the return - value flag. jump2 already knows how to get rid of - no-op moves. */ - if (new_src == const0_rtx) - { - init_costs_to_zero (&mincst); - min_regno = i; - break; - } - else - { - XEXP (plus_expr, 1) = new_src; - get_full_set_rtx_cost (pat, &newcst); - - if (costs_lt_p (&newcst, &mincst, speed)) - { - mincst = newcst; - min_regno = i; - } - } - } - SET_SRC (pat) = src; - - if (costs_lt_p (&mincst, &oldcst, speed)) - { - rtx tem; - - tem = gen_rtx_REG (GET_MODE (reg), min_regno); - if (i != min_regno) - { - rtx new_src = gen_int_mode (UINTVAL (off) - reg_offset[min_regno], - GET_MODE (reg)); - tem = gen_rtx_PLUS (GET_MODE (reg), tem, new_src); - } - if (validate_change (insn, &SET_SRC (pat), tem, 0)) - changed = true; - } - reg_set_luid[regno] = move2add_luid; - move2add_record_sym_value (reg, sym, off); - return changed; -} - -/* Convert move insns with constant inputs to additions if they are cheaper. - Return true if any changes were made. */ -static bool -reload_cse_move2add (rtx_insn *first) -{ - int i; - rtx_insn *insn; - bool changed = false; - - for (i = FIRST_PSEUDO_REGISTER - 1; i >= 0; i--) - { - reg_set_luid[i] = 0; - reg_offset[i] = 0; - reg_base_reg[i] = 0; - reg_symbol_ref[i] = NULL_RTX; - reg_mode[i] = VOIDmode; - } - - move2add_last_label_luid = 0; - move2add_luid = 2; - for (insn = first; insn; insn = NEXT_INSN (insn), move2add_luid++) - { - rtx pat, note; - - if (LABEL_P (insn)) - { - move2add_last_label_luid = move2add_luid; - /* We're going to increment move2add_luid twice after a - label, so that we can use move2add_last_label_luid + 1 as - the luid for constants. */ - move2add_luid++; - continue; - } - if (! INSN_P (insn)) - continue; - pat = PATTERN (insn); - /* For simplicity, we only perform this optimization on - straightforward SETs. */ - scalar_int_mode mode; - if (GET_CODE (pat) == SET - && REG_P (SET_DEST (pat)) - && is_a <scalar_int_mode> (GET_MODE (SET_DEST (pat)), &mode)) - { - rtx reg = SET_DEST (pat); - int regno = REGNO (reg); - rtx src = SET_SRC (pat); - - /* Check if we have valid information on the contents of this - register in the mode of REG. */ - if (move2add_valid_value_p (regno, mode) - && dbg_cnt (cse2_move2add)) - { - /* Try to transform (set (REGX) (CONST_INT A)) - ... - (set (REGX) (CONST_INT B)) - to - (set (REGX) (CONST_INT A)) - ... - (set (REGX) (plus (REGX) (CONST_INT B-A))) - or - (set (REGX) (CONST_INT A)) - ... - (set (STRICT_LOW_PART (REGX)) (CONST_INT B)) - */ - - if (CONST_INT_P (src) - && reg_base_reg[regno] < 0 - && reg_symbol_ref[regno] == NULL_RTX) - { - changed |= move2add_use_add2_insn (mode, reg, NULL_RTX, - src, insn); - continue; - } - - /* Try to transform (set (REGX) (REGY)) - (set (REGX) (PLUS (REGX) (CONST_INT A))) - ... - (set (REGX) (REGY)) - (set (REGX) (PLUS (REGX) (CONST_INT B))) - to - (set (REGX) (REGY)) - (set (REGX) (PLUS (REGX) (CONST_INT A))) - ... - (set (REGX) (plus (REGX) (CONST_INT B-A))) */ - else if (REG_P (src) - && reg_set_luid[regno] == reg_set_luid[REGNO (src)] - && reg_base_reg[regno] == reg_base_reg[REGNO (src)] - && move2add_valid_value_p (REGNO (src), mode)) - { - rtx_insn *next = next_nonnote_nondebug_insn (insn); - rtx set = NULL_RTX; - if (next) - set = single_set (next); - if (set - && SET_DEST (set) == reg - && GET_CODE (SET_SRC (set)) == PLUS - && XEXP (SET_SRC (set), 0) == reg - && CONST_INT_P (XEXP (SET_SRC (set), 1))) - { - rtx src3 = XEXP (SET_SRC (set), 1); - unsigned HOST_WIDE_INT added_offset = UINTVAL (src3); - HOST_WIDE_INT base_offset = reg_offset[REGNO (src)]; - HOST_WIDE_INT regno_offset = reg_offset[regno]; - rtx new_src = - gen_int_mode (added_offset - + base_offset - - regno_offset, - mode); - bool success = false; - bool speed = optimize_bb_for_speed_p (BLOCK_FOR_INSN (insn)); - - if (new_src == const0_rtx) - /* See above why we create (set (reg) (reg)) here. */ - success - = validate_change (next, &SET_SRC (set), reg, 0); - else - { - rtx old_src = SET_SRC (set); - struct full_rtx_costs oldcst, newcst; - rtx tem = gen_rtx_PLUS (mode, reg, new_src); - - get_full_set_rtx_cost (set, &oldcst); - SET_SRC (set) = tem; - get_full_set_src_cost (tem, mode, &newcst); - SET_SRC (set) = old_src; - costs_add_n_insns (&oldcst, 1); - - if (costs_lt_p (&newcst, &oldcst, speed) - && have_add2_insn (reg, new_src)) - { - rtx newpat = gen_rtx_SET (reg, tem); - success - = validate_change (next, &PATTERN (next), - newpat, 0); - } - } - if (success) - delete_insn (insn); - changed |= success; - insn = next; - move2add_record_mode (reg); - reg_offset[regno] - = trunc_int_for_mode (added_offset + base_offset, - mode); - continue; - } - } - } - - /* Try to transform - (set (REGX) (CONST (PLUS (SYMBOL_REF) (CONST_INT A)))) - ... - (set (REGY) (CONST (PLUS (SYMBOL_REF) (CONST_INT B)))) - to - (set (REGX) (CONST (PLUS (SYMBOL_REF) (CONST_INT A)))) - ... - (set (REGY) (CONST (PLUS (REGX) (CONST_INT B-A)))) */ - if ((GET_CODE (src) == SYMBOL_REF - || (GET_CODE (src) == CONST - && GET_CODE (XEXP (src, 0)) == PLUS - && GET_CODE (XEXP (XEXP (src, 0), 0)) == SYMBOL_REF - && CONST_INT_P (XEXP (XEXP (src, 0), 1)))) - && dbg_cnt (cse2_move2add)) - { - rtx sym, off; - - if (GET_CODE (src) == SYMBOL_REF) - { - sym = src; - off = const0_rtx; - } - else - { - sym = XEXP (XEXP (src, 0), 0); - off = XEXP (XEXP (src, 0), 1); - } - - /* If the reg already contains the value which is sum of - sym and some constant value, we can use an add2 insn. */ - if (move2add_valid_value_p (regno, mode) - && reg_base_reg[regno] < 0 - && reg_symbol_ref[regno] != NULL_RTX - && rtx_equal_p (sym, reg_symbol_ref[regno])) - changed |= move2add_use_add2_insn (mode, reg, sym, off, insn); - - /* Otherwise, we have to find a register whose value is sum - of sym and some constant value. */ - else - changed |= move2add_use_add3_insn (mode, reg, sym, off, insn); - - continue; - } - } - - for (note = REG_NOTES (insn); note; note = XEXP (note, 1)) - { - if (REG_NOTE_KIND (note) == REG_INC - && REG_P (XEXP (note, 0))) - { - /* Reset the information about this register. */ - int regno = REGNO (XEXP (note, 0)); - if (regno < FIRST_PSEUDO_REGISTER) - { - move2add_record_mode (XEXP (note, 0)); - reg_mode[regno] = VOIDmode; - } - } - } - - /* There are no REG_INC notes for SP autoinc. */ - subrtx_var_iterator::array_type array; - FOR_EACH_SUBRTX_VAR (iter, array, PATTERN (insn), NONCONST) - { - rtx mem = *iter; - if (mem - && MEM_P (mem) - && GET_RTX_CLASS (GET_CODE (XEXP (mem, 0))) == RTX_AUTOINC) - { - if (XEXP (XEXP (mem, 0), 0) == stack_pointer_rtx) - reg_mode[STACK_POINTER_REGNUM] = VOIDmode; - } - } - - note_stores (insn, move2add_note_store, insn); - - /* If INSN is a conditional branch, we try to extract an - implicit set out of it. */ - if (any_condjump_p (insn)) - { - rtx cnd = fis_get_condition (insn); - - if (cnd != NULL_RTX - && GET_CODE (cnd) == NE - && REG_P (XEXP (cnd, 0)) - && !reg_set_p (XEXP (cnd, 0), insn) - /* The following two checks, which are also in - move2add_note_store, are intended to reduce the - number of calls to gen_rtx_SET to avoid memory - allocation if possible. */ - && SCALAR_INT_MODE_P (GET_MODE (XEXP (cnd, 0))) - && REG_NREGS (XEXP (cnd, 0)) == 1 - && CONST_INT_P (XEXP (cnd, 1))) - { - rtx implicit_set = - gen_rtx_SET (XEXP (cnd, 0), XEXP (cnd, 1)); - move2add_note_store (SET_DEST (implicit_set), implicit_set, insn); - } - } - - /* If this is a CALL_INSN, all call used registers are stored with - unknown values. */ - if (CALL_P (insn)) - { - function_abi callee_abi = insn_callee_abi (insn); - for (i = FIRST_PSEUDO_REGISTER - 1; i >= 0; i--) - if (reg_mode[i] != VOIDmode - && reg_mode[i] != BLKmode - && callee_abi.clobbers_reg_p (reg_mode[i], i)) - /* Reset the information about this register. */ - reg_mode[i] = VOIDmode; - } - } - return changed; -} - -/* SET is a SET or CLOBBER that sets DST. DATA is the insn which - contains SET. - Update reg_set_luid, reg_offset and reg_base_reg accordingly. - Called from reload_cse_move2add via note_stores. */ - -static void -move2add_note_store (rtx dst, const_rtx set, void *data) -{ - rtx_insn *insn = (rtx_insn *) data; - unsigned int regno = 0; - scalar_int_mode mode; - - if (GET_CODE (dst) == SUBREG) - regno = subreg_regno (dst); - else if (REG_P (dst)) - regno = REGNO (dst); - else - return; - - if (!is_a <scalar_int_mode> (GET_MODE (dst), &mode)) - goto invalidate; - - if (GET_CODE (set) == SET) - { - rtx note, sym = NULL_RTX; - rtx off; - - note = find_reg_equal_equiv_note (insn); - if (note && GET_CODE (XEXP (note, 0)) == SYMBOL_REF) - { - sym = XEXP (note, 0); - off = const0_rtx; - } - else if (note && GET_CODE (XEXP (note, 0)) == CONST - && GET_CODE (XEXP (XEXP (note, 0), 0)) == PLUS - && GET_CODE (XEXP (XEXP (XEXP (note, 0), 0), 0)) == SYMBOL_REF - && CONST_INT_P (XEXP (XEXP (XEXP (note, 0), 0), 1))) - { - sym = XEXP (XEXP (XEXP (note, 0), 0), 0); - off = XEXP (XEXP (XEXP (note, 0), 0), 1); - } - - if (sym != NULL_RTX) - { - move2add_record_sym_value (dst, sym, off); - return; - } - } - - if (GET_CODE (set) == SET - && GET_CODE (SET_DEST (set)) != ZERO_EXTRACT - && GET_CODE (SET_DEST (set)) != STRICT_LOW_PART) - { - rtx src = SET_SRC (set); - rtx base_reg; - unsigned HOST_WIDE_INT offset; - int base_regno; - - switch (GET_CODE (src)) - { - case PLUS: - if (REG_P (XEXP (src, 0))) - { - base_reg = XEXP (src, 0); - - if (CONST_INT_P (XEXP (src, 1))) - offset = UINTVAL (XEXP (src, 1)); - else if (REG_P (XEXP (src, 1)) - && move2add_valid_value_p (REGNO (XEXP (src, 1)), mode)) - { - if (reg_base_reg[REGNO (XEXP (src, 1))] < 0 - && reg_symbol_ref[REGNO (XEXP (src, 1))] == NULL_RTX) - offset = reg_offset[REGNO (XEXP (src, 1))]; - /* Maybe the first register is known to be a - constant. */ - else if (move2add_valid_value_p (REGNO (base_reg), mode) - && reg_base_reg[REGNO (base_reg)] < 0 - && reg_symbol_ref[REGNO (base_reg)] == NULL_RTX) - { - offset = reg_offset[REGNO (base_reg)]; - base_reg = XEXP (src, 1); - } - else - goto invalidate; - } - else - goto invalidate; - - break; - } - - goto invalidate; - - case REG: - base_reg = src; - offset = 0; - break; - - case CONST_INT: - /* Start tracking the register as a constant. */ - reg_base_reg[regno] = -1; - reg_symbol_ref[regno] = NULL_RTX; - reg_offset[regno] = INTVAL (SET_SRC (set)); - /* We assign the same luid to all registers set to constants. */ - reg_set_luid[regno] = move2add_last_label_luid + 1; - move2add_record_mode (dst); - return; - - default: - goto invalidate; - } - - base_regno = REGNO (base_reg); - /* If information about the base register is not valid, set it - up as a new base register, pretending its value is known - starting from the current insn. */ - if (!move2add_valid_value_p (base_regno, mode)) - { - reg_base_reg[base_regno] = base_regno; - reg_symbol_ref[base_regno] = NULL_RTX; - reg_offset[base_regno] = 0; - reg_set_luid[base_regno] = move2add_luid; - gcc_assert (GET_MODE (base_reg) == mode); - move2add_record_mode (base_reg); - } - - /* Copy base information from our base register. */ - reg_set_luid[regno] = reg_set_luid[base_regno]; - reg_base_reg[regno] = reg_base_reg[base_regno]; - reg_symbol_ref[regno] = reg_symbol_ref[base_regno]; - - /* Compute the sum of the offsets or constants. */ - reg_offset[regno] - = trunc_int_for_mode (offset + reg_offset[base_regno], mode); - - move2add_record_mode (dst); - } - else - { - invalidate: - /* Invalidate the contents of the register. */ - move2add_record_mode (dst); - reg_mode[regno] = VOIDmode; - } -} - -namespace { - -const pass_data pass_data_postreload_cse = -{ - RTL_PASS, /* type */ - "postreload", /* name */ - OPTGROUP_NONE, /* optinfo_flags */ - TV_RELOAD_CSE_REGS, /* tv_id */ - 0, /* properties_required */ - 0, /* properties_provided */ - 0, /* properties_destroyed */ - 0, /* todo_flags_start */ - TODO_df_finish, /* todo_flags_finish */ -}; - -class pass_postreload_cse : public rtl_opt_pass -{ -public: - pass_postreload_cse (gcc::context *ctxt) - : rtl_opt_pass (pass_data_postreload_cse, ctxt) - {} - - /* opt_pass methods: */ - virtual bool gate (function *) { return (optimize > 0 && reload_completed); } - - virtual unsigned int execute (function *); - -}; // class pass_postreload_cse - -unsigned int -pass_postreload_cse::execute (function *fun) -{ - if (!dbg_cnt (postreload_cse)) - return 0; - - /* Do a very simple CSE pass over just the hard registers. */ - reload_cse_regs (get_insns ()); - /* Reload_cse_regs can eliminate potentially-trapping MEMs. - Remove any EH edges associated with them. */ - if (fun->can_throw_non_call_exceptions - && purge_all_dead_edges ()) - cleanup_cfg (0); - - return 0; -} - -} // anon namespace - -rtl_opt_pass * -make_pass_postreload_cse (gcc::context *ctxt) -{ - return new pass_postreload_cse (ctxt); -} |