Message ID | mptzhjatzfy.fsf@arm.com |
---|---|
State | New |
Headers | show |
Series | Support multiple ABIs in the same translation unit | expand |
On 9/11/19 1:17 PM, Richard Sandiford wrote: > This is a straight replacement of an existing "full or partial" > call-clobber check. > > > 2019-09-11 Richard Sandiford <richard.sandiford@arm.com> > > gcc/ > * sched-deps.c (deps_analyze_insn): Use the ABI of the target > function to test whether a register is fully or partly clobbered. OK jeff
On Mon, 30 Sep 2019 at 00:20, Jeff Law <law@redhat.com> wrote: > On 9/11/19 1:17 PM, Richard Sandiford wrote: > > This is a straight replacement of an existing "full or partial" > > call-clobber check. > > > > > > 2019-09-11 Richard Sandiford <richard.sandiford@arm.com> > > > > gcc/ > > * sched-deps.c (deps_analyze_insn): Use the ABI of the target > > function to test whether a register is fully or partly clobbered. > OK > jeff > Hi Richard, My testing shows regressions on arm after you applied this patch (r276335): For instance on arm-none-linux-gnueabi --with-mode arm --with-cpu cortex-a9 FAIL: gcc.dg/strlenopt-18g.c execution test If you force -march=armv5t via RUNTESTFLAGS, there's an additional failure: FAIL: gcc.dg/strlenopt-19.c execution test In fortran, I see different sets of regressions depending on arm vs thumb mode. target arm-none-linux-gnueabi --with-mode arm --with-cpu cortex-a9 I get these new FAILs: gfortran.dg/char4_iunit_1.f03 -O0 execution test gfortran.dg/char4_iunit_1.f03 -O1 execution test gfortran.dg/char4_iunit_1.f03 -O2 execution test gfortran.dg/char4_iunit_1.f03 -O3 -fomit-frame-pointer -funroll-loops -fpeel-loops -ftracer -finline-functions execution test gfortran.dg/char4_iunit_1.f03 -O3 -g execution test gfortran.dg/char4_iunit_1.f03 -Os execution test gfortran.dg/namelist_16.f90 -O0 execution test gfortran.dg/namelist_16.f90 -O1 execution test gfortran.dg/namelist_16.f90 -O2 execution test gfortran.dg/namelist_16.f90 -O3 -fomit-frame-pointer -funroll-loops -fpeel-loops -ftracer -finline-functions execution test gfortran.dg/namelist_16.f90 -O3 -g execution test gfortran.dg/namelist_16.f90 -Os execution test gfortran.dg/namelist_95.f90 -O0 execution test gfortran.dg/namelist_95.f90 -O1 execution test gfortran.dg/namelist_95.f90 -O2 execution test gfortran.dg/namelist_95.f90 -O3 -fomit-frame-pointer -funroll-loops -fpeel-loops -ftracer -finline-functions execution test gfortran.dg/namelist_95.f90 -O3 -g execution test gfortran.dg/namelist_95.f90 -Os execution test gfortran.dg/real_const_3.f90 -O0 execution test gfortran.dg/real_const_3.f90 -O1 execution test gfortran.dg/real_const_3.f90 -O2 execution test gfortran.dg/real_const_3.f90 -O3 -fomit-frame-pointer -funroll-loops -fpeel-loops -ftracer -finline-functions execution test gfortran.dg/real_const_3.f90 -O3 -g execution test gfortran.dg/real_const_3.f90 -Os execution test When defaulting to thumb: target arm-none-linux-gnueabi --with-mode thumb --with-cpu cortex-a9 I get these new FAILs: gfortran.dg/f2003_io_5.f03 -O0 execution test gfortran.dg/f2003_io_5.f03 -O1 execution test gfortran.dg/f2003_io_5.f03 -O2 execution test gfortran.dg/f2003_io_5.f03 -O3 -fomit-frame-pointer -funroll-loops -fpeel-loops -ftracer -finline-functions execution test gfortran.dg/f2003_io_5.f03 -O3 -g execution test gfortran.dg/f2003_io_5.f03 -Os execution test gfortran.dg/real_const_3.f90 -O0 execution test gfortran.dg/real_const_3.f90 -O1 execution test gfortran.dg/real_const_3.f90 -O2 execution test gfortran.dg/real_const_3.f90 -O3 -fomit-frame-pointer -funroll-loops -fpeel-loops -ftracer -finline-functions execution test gfortran.dg/real_const_3.f90 -O3 -g execution test gfortran.dg/real_const_3.f90 -Os execution test This is the most recent validation result I have so far, so maybe you already fixed the problem? Thanks, Christophe
Christophe Lyon <christophe.lyon@linaro.org> writes: > On Mon, 30 Sep 2019 at 00:20, Jeff Law <law@redhat.com> wrote: > > On 9/11/19 1:17 PM, Richard Sandiford wrote: > > This is a straight replacement of an existing "full or partial" > > call-clobber check. > > > > > > 2019-09-11 Richard Sandiford <richard.sandiford@arm.com> > > > > gcc/ > > * sched-deps.c (deps_analyze_insn): Use the ABI of the target > > function to test whether a register is fully or partly clobbered. > OK > jeff > > > Hi Richard, > > My testing shows regressions on arm after you applied this patch (r276335): > For instance on arm-none-linux-gnueabi > --with-mode arm > --with-cpu cortex-a9 > FAIL: gcc.dg/strlenopt-18g.c execution test > > If you force -march=armv5t via RUNTESTFLAGS, there's an additional failure: > FAIL: gcc.dg/strlenopt-19.c execution test > > In fortran, I see different sets of regressions depending on arm vs thumb mode. > target arm-none-linux-gnueabi > --with-mode arm > --with-cpu cortex-a9 > I get these new FAILs: > gfortran.dg/char4_iunit_1.f03 -O0 execution test > gfortran.dg/char4_iunit_1.f03 -O1 execution test > gfortran.dg/char4_iunit_1.f03 -O2 execution test > gfortran.dg/char4_iunit_1.f03 -O3 -fomit-frame-pointer -funroll-loops > -fpeel-loops -ftracer -finline-functions execution test > gfortran.dg/char4_iunit_1.f03 -O3 -g execution test > gfortran.dg/char4_iunit_1.f03 -Os execution test > gfortran.dg/namelist_16.f90 -O0 execution test > gfortran.dg/namelist_16.f90 -O1 execution test > gfortran.dg/namelist_16.f90 -O2 execution test > gfortran.dg/namelist_16.f90 -O3 -fomit-frame-pointer -funroll-loops > -fpeel-loops -ftracer -finline-functions execution test > gfortran.dg/namelist_16.f90 -O3 -g execution test > gfortran.dg/namelist_16.f90 -Os execution test > gfortran.dg/namelist_95.f90 -O0 execution test > gfortran.dg/namelist_95.f90 -O1 execution test > gfortran.dg/namelist_95.f90 -O2 execution test > gfortran.dg/namelist_95.f90 -O3 -fomit-frame-pointer -funroll-loops > -fpeel-loops -ftracer -finline-functions execution test > gfortran.dg/namelist_95.f90 -O3 -g execution test > gfortran.dg/namelist_95.f90 -Os execution test > gfortran.dg/real_const_3.f90 -O0 execution test > gfortran.dg/real_const_3.f90 -O1 execution test > gfortran.dg/real_const_3.f90 -O2 execution test > gfortran.dg/real_const_3.f90 -O3 -fomit-frame-pointer -funroll-loops > -fpeel-loops -ftracer -finline-functions execution test > gfortran.dg/real_const_3.f90 -O3 -g execution test > gfortran.dg/real_const_3.f90 -Os execution test > > > When defaulting to thumb: > target arm-none-linux-gnueabi > --with-mode thumb > --with-cpu cortex-a9 > I get these new FAILs: > gfortran.dg/f2003_io_5.f03 -O0 execution test > gfortran.dg/f2003_io_5.f03 -O1 execution test > gfortran.dg/f2003_io_5.f03 -O2 execution test > gfortran.dg/f2003_io_5.f03 -O3 -fomit-frame-pointer -funroll-loops > -fpeel-loops -ftracer -finline-functions execution test > gfortran.dg/f2003_io_5.f03 -O3 -g execution test > gfortran.dg/f2003_io_5.f03 -Os execution test > gfortran.dg/real_const_3.f90 -O0 execution test > gfortran.dg/real_const_3.f90 -O1 execution test > gfortran.dg/real_const_3.f90 -O2 execution test > gfortran.dg/real_const_3.f90 -O3 -fomit-frame-pointer -funroll-loops > -fpeel-loops -ftracer -finline-functions execution test > gfortran.dg/real_const_3.f90 -O3 -g execution test > gfortran.dg/real_const_3.f90 -Os execution test > > This is the most recent validation result I have so far, so maybe you already > fixed the problem? This sounds very like https://gcc.gnu.org/ml/gcc-patches/2019-10/msg00170.html Let me know if you see any remaining failures after that though. Thanks, Richard
On Fri, 4 Oct 2019 at 16:35, Richard Sandiford <richard.sandiford@arm.com> wrote: > Christophe Lyon <christophe.lyon@linaro.org> writes: > > On Mon, 30 Sep 2019 at 00:20, Jeff Law <law@redhat.com> wrote: > > > > On 9/11/19 1:17 PM, Richard Sandiford wrote: > > > This is a straight replacement of an existing "full or partial" > > > call-clobber check. > > > > > > > > > 2019-09-11 Richard Sandiford <richard.sandiford@arm.com> > > > > > > gcc/ > > > * sched-deps.c (deps_analyze_insn): Use the ABI of the target > > > function to test whether a register is fully or partly > clobbered. > > OK > > jeff > > > > > > Hi Richard, > > > > My testing shows regressions on arm after you applied this patch > (r276335): > > For instance on arm-none-linux-gnueabi > > --with-mode arm > > --with-cpu cortex-a9 > > FAIL: gcc.dg/strlenopt-18g.c execution test > > > > If you force -march=armv5t via RUNTESTFLAGS, there's an additional > failure: > > FAIL: gcc.dg/strlenopt-19.c execution test > > > > In fortran, I see different sets of regressions depending on arm vs > thumb mode. > > target arm-none-linux-gnueabi > > --with-mode arm > > --with-cpu cortex-a9 > > I get these new FAILs: > > gfortran.dg/char4_iunit_1.f03 -O0 execution test > > gfortran.dg/char4_iunit_1.f03 -O1 execution test > > gfortran.dg/char4_iunit_1.f03 -O2 execution test > > gfortran.dg/char4_iunit_1.f03 -O3 -fomit-frame-pointer > -funroll-loops > > -fpeel-loops -ftracer -finline-functions execution test > > gfortran.dg/char4_iunit_1.f03 -O3 -g execution test > > gfortran.dg/char4_iunit_1.f03 -Os execution test > > gfortran.dg/namelist_16.f90 -O0 execution test > > gfortran.dg/namelist_16.f90 -O1 execution test > > gfortran.dg/namelist_16.f90 -O2 execution test > > gfortran.dg/namelist_16.f90 -O3 -fomit-frame-pointer -funroll-loops > > -fpeel-loops -ftracer -finline-functions execution test > > gfortran.dg/namelist_16.f90 -O3 -g execution test > > gfortran.dg/namelist_16.f90 -Os execution test > > gfortran.dg/namelist_95.f90 -O0 execution test > > gfortran.dg/namelist_95.f90 -O1 execution test > > gfortran.dg/namelist_95.f90 -O2 execution test > > gfortran.dg/namelist_95.f90 -O3 -fomit-frame-pointer -funroll-loops > > -fpeel-loops -ftracer -finline-functions execution test > > gfortran.dg/namelist_95.f90 -O3 -g execution test > > gfortran.dg/namelist_95.f90 -Os execution test > > gfortran.dg/real_const_3.f90 -O0 execution test > > gfortran.dg/real_const_3.f90 -O1 execution test > > gfortran.dg/real_const_3.f90 -O2 execution test > > gfortran.dg/real_const_3.f90 -O3 -fomit-frame-pointer > -funroll-loops > > -fpeel-loops -ftracer -finline-functions execution test > > gfortran.dg/real_const_3.f90 -O3 -g execution test > > gfortran.dg/real_const_3.f90 -Os execution test > > > > > > When defaulting to thumb: > > target arm-none-linux-gnueabi > > --with-mode thumb > > --with-cpu cortex-a9 > > I get these new FAILs: > > gfortran.dg/f2003_io_5.f03 -O0 execution test > > gfortran.dg/f2003_io_5.f03 -O1 execution test > > gfortran.dg/f2003_io_5.f03 -O2 execution test > > gfortran.dg/f2003_io_5.f03 -O3 -fomit-frame-pointer -funroll-loops > > -fpeel-loops -ftracer -finline-functions execution test > > gfortran.dg/f2003_io_5.f03 -O3 -g execution test > > gfortran.dg/f2003_io_5.f03 -Os execution test > > gfortran.dg/real_const_3.f90 -O0 execution test > > gfortran.dg/real_const_3.f90 -O1 execution test > > gfortran.dg/real_const_3.f90 -O2 execution test > > gfortran.dg/real_const_3.f90 -O3 -fomit-frame-pointer > -funroll-loops > > -fpeel-loops -ftracer -finline-functions execution test > > gfortran.dg/real_const_3.f90 -O3 -g execution test > > gfortran.dg/real_const_3.f90 -Os execution test > > > > This is the most recent validation result I have so far, so maybe you > already > > fixed the problem? > > This sounds very like > https://gcc.gnu.org/ml/gcc-patches/2019-10/msg00170.html > Let me know if you see any remaining failures after that though. > > Sure, thanks for the quick reply! > Thanks, > Richard >
On Fri, 4 Oct 2019 at 16:35, Richard Sandiford <richard.sandiford@arm.com> wrote: > Christophe Lyon <christophe.lyon@linaro.org> writes: > > On Mon, 30 Sep 2019 at 00:20, Jeff Law <law@redhat.com> wrote: > > > > On 9/11/19 1:17 PM, Richard Sandiford wrote: > > > This is a straight replacement of an existing "full or partial" > > > call-clobber check. > > > > > > > > > 2019-09-11 Richard Sandiford <richard.sandiford@arm.com> > > > > > > gcc/ > > > * sched-deps.c (deps_analyze_insn): Use the ABI of the target > > > function to test whether a register is fully or partly > clobbered. > > OK > > jeff > > > > > > Hi Richard, > > > > My testing shows regressions on arm after you applied this patch > (r276335): > > For instance on arm-none-linux-gnueabi > > --with-mode arm > > --with-cpu cortex-a9 > > FAIL: gcc.dg/strlenopt-18g.c execution test > > > > If you force -march=armv5t via RUNTESTFLAGS, there's an additional > failure: > > FAIL: gcc.dg/strlenopt-19.c execution test > > > > In fortran, I see different sets of regressions depending on arm vs > thumb mode. > > target arm-none-linux-gnueabi > > --with-mode arm > > --with-cpu cortex-a9 > > I get these new FAILs: > > gfortran.dg/char4_iunit_1.f03 -O0 execution test > > gfortran.dg/char4_iunit_1.f03 -O1 execution test > > gfortran.dg/char4_iunit_1.f03 -O2 execution test > > gfortran.dg/char4_iunit_1.f03 -O3 -fomit-frame-pointer > -funroll-loops > > -fpeel-loops -ftracer -finline-functions execution test > > gfortran.dg/char4_iunit_1.f03 -O3 -g execution test > > gfortran.dg/char4_iunit_1.f03 -Os execution test > > gfortran.dg/namelist_16.f90 -O0 execution test > > gfortran.dg/namelist_16.f90 -O1 execution test > > gfortran.dg/namelist_16.f90 -O2 execution test > > gfortran.dg/namelist_16.f90 -O3 -fomit-frame-pointer -funroll-loops > > -fpeel-loops -ftracer -finline-functions execution test > > gfortran.dg/namelist_16.f90 -O3 -g execution test > > gfortran.dg/namelist_16.f90 -Os execution test > > gfortran.dg/namelist_95.f90 -O0 execution test > > gfortran.dg/namelist_95.f90 -O1 execution test > > gfortran.dg/namelist_95.f90 -O2 execution test > > gfortran.dg/namelist_95.f90 -O3 -fomit-frame-pointer -funroll-loops > > -fpeel-loops -ftracer -finline-functions execution test > > gfortran.dg/namelist_95.f90 -O3 -g execution test > > gfortran.dg/namelist_95.f90 -Os execution test > > gfortran.dg/real_const_3.f90 -O0 execution test > > gfortran.dg/real_const_3.f90 -O1 execution test > > gfortran.dg/real_const_3.f90 -O2 execution test > > gfortran.dg/real_const_3.f90 -O3 -fomit-frame-pointer > -funroll-loops > > -fpeel-loops -ftracer -finline-functions execution test > > gfortran.dg/real_const_3.f90 -O3 -g execution test > > gfortran.dg/real_const_3.f90 -Os execution test > > > > > > When defaulting to thumb: > > target arm-none-linux-gnueabi > > --with-mode thumb > > --with-cpu cortex-a9 > > I get these new FAILs: > > gfortran.dg/f2003_io_5.f03 -O0 execution test > > gfortran.dg/f2003_io_5.f03 -O1 execution test > > gfortran.dg/f2003_io_5.f03 -O2 execution test > > gfortran.dg/f2003_io_5.f03 -O3 -fomit-frame-pointer -funroll-loops > > -fpeel-loops -ftracer -finline-functions execution test > > gfortran.dg/f2003_io_5.f03 -O3 -g execution test > > gfortran.dg/f2003_io_5.f03 -Os execution test > > gfortran.dg/real_const_3.f90 -O0 execution test > > gfortran.dg/real_const_3.f90 -O1 execution test > > gfortran.dg/real_const_3.f90 -O2 execution test > > gfortran.dg/real_const_3.f90 -O3 -fomit-frame-pointer > -funroll-loops > > -fpeel-loops -ftracer -finline-functions execution test > > gfortran.dg/real_const_3.f90 -O3 -g execution test > > gfortran.dg/real_const_3.f90 -Os execution test > > > > This is the most recent validation result I have so far, so maybe you > already > > fixed the problem? > > This sounds very like > https://gcc.gnu.org/ml/gcc-patches/2019-10/msg00170.html > Let me know if you see any remaining failures after that though. > > I looks OK, now. Note that r276489 fixed the strlenopt regressions, while the fortran regressions seem to have been fixed between r276457 and r276488 (that is, just before the above patch). Thanks, Christophe Thanks, > Richard >
Index: gcc/sched-deps.c =================================================================== --- gcc/sched-deps.c 2019-09-11 19:47:32.902202887 +0100 +++ gcc/sched-deps.c 2019-09-11 19:49:08.517529131 +0100 @@ -3736,9 +3736,7 @@ deps_analyze_insn (class deps_desc *deps Since we only have a choice between 'might be clobbered' and 'definitely not clobbered', we must include all partly call-clobbered registers here. */ - else if (targetm.hard_regno_call_part_clobbered (abi.id (), i, - reg_raw_mode[i]) - || TEST_HARD_REG_BIT (regs_invalidated_by_call, i)) + else if (abi.clobbers_at_least_part_of_reg_p (i)) SET_REGNO_REG_SET (reg_pending_clobbers, i); /* We don't know what set of fixed registers might be used by the function, but it is certain that the stack pointer