On Thu, 2023-11-30 at 08:44 -0700, Jeff Law wrote: > > > On 11/29/23 02:33, Xi Ruoyao wrote: > > On Mon, 2023-11-27 at 23:06 -0700, Jeff Law wrote: > > > This has (of course) been tested on rv64. It's also been bootstrapped > > > and regression tested on x86. Bootstrap and regression tested (C only) > > > for m68k, sh4, sh4eb, alpha. Earlier versions were also bootstrapped > > > and regression tested on ppc, hppa and s390x (C only for those as well). > > > It's also been tested on the various crosses in my tester. So we've > > > got reasonable coverage of 16, 32 and 64 bit targets, big and little > > > endian, with and without SHIFT_COUNT_TRUNCATED and all kinds of other > > > oddities. > > > > > > The included tests are for RISC-V only because not all targets are going > > > to have extraneous extensions. There's tests from coremark, x264 and > > > GCC's bz database. It probably wouldn't be hard to add aarch64 > > > testscases. The BZs listed are improved by this patch for aarch64. > > > > I've successfully bootstrapped this on loongarch64-linux-gnu and tried > > the added test cases. For loongarch64 the redundant extensions are > > removed for core_bench_list.c, core_init_matrix.c, core_list_init.c, > > matrix_add_const.c, and pr111384.c, but not mem-extend.c. > > > > Should I change something in LoongArch backend in order to make ext_dce > > work for mem-extend.c too? If yes then any pointers? > I'd bet it was my goof removing MINUS from the list of supported opcodes > where we can use narrowing life information from the destination to > narrow the lifetime of the sources. > > Try adding MINUS back into safe_for_live_propagation.
I can confirm it works for this this case, and bootstrap & regtest still fine on LoongArch. -- Xi Ruoyao <xry...@xry111.site> School of Aerospace Science and Technology, Xidian University