On Tue, Jun 18, 2019 at 8:58 AM H.J. Lu <hjl.to...@gmail.com> wrote: > > On Tue, Jun 11, 2019 at 8:14 AM H.J. Lu <hjl.to...@gmail.com> wrote: > > > > For op_by_pieces operations between two areas of memory, this patch adds > > -fminimize-op-by-pieces-run to minimize number of operations. When > > operating on LENGTH bytes of memory, it starts with the widest usable > > integer size, MAX_SIZE, for LENGTH bytes and finishes with the smallest > > usable integer size, MIN_SIZE, for the remaining bytes where MAX_SIZE > > >= MIN_SIZE. If MIN_SIZE > the remaining bytes, the last operation is > > performed on MIN_SIZE bytes of overlapping memory from the previous > > operation. > > > > Tested on Linux/x86-64 with both -fminimize-op-by-pieces-run enabled > > and disabled by default. > > > > I will submit a separate patch to enable -fminimize-op-by-pieces-run for > > -Os. > > > > OK for trunk? > > > > gcc/ > > > > PR middl-end/90773 > > * common.opt (-fminimize-op-by-pieces-run): New. > > * expr.c (op_by_pieces_d): Add get_usable_mode. > > (op_by_pieces_d::get_usable_mode): New. > > (op_by_pieces_d::run): Use get_usable_mode to get the largest > > usable integer mode for -fminimize-op-by-pieces-run. > > * doc/invoke.texi: Document -fminimize-op-by-pieces-run. > > > > gcc/testsuite/ > > > > PR middl-end/90773 > > * gcc.target/i386/pr90773-1.c: New test. > > * gcc.target/i386/pr90773-2.c: Likewise. > > * gcc.target/i386/pr90773-3.c: Likewise. > > * gcc.target/i386/pr90773-4.c: Likewise. > > * gcc.target/i386/pr90773-5.c: Likewise. > > > > Thanks. > > > > PING: > > https://gcc.gnu.org/ml/gcc-patches/2019-06/msg00641.html >
PING. -- H.J.