On Thu, May 10, 2018 at 8:56 AM, Alexander Monakov <amona...@ispras.ru> wrote:
>         * sort.cc: New file.
>         * system.h [!CHECKING_P] (qsort): Redirect to gcc_qsort.
>         * vec.c (qsort_chk): Use gcc_qsort.
>

This breaks bootstrap on Fedora 28/i686:

https://gcc.gnu.org/ml/gcc-regression/2018-05/msg00088.html

../../src-trunk/gcc/sort.cc:112:5: note: in expansion of macro ‘REORDER_45’
     REORDER_45 (8, 8, 0);
     ^~~~~~~~~~
../../src-trunk/gcc/sort.cc:100:10: error: ‘void* memcpy(void*, const
void*, size_t)’ forming offset [5, 8] is out of the bounds [0, 4] of
object ‘t2’ with type ‘size_t’ {aka ‘unsigned int’}
[-Werror=array-bounds]
   memcpy (&t2, e2 + OFFSET, SIZE);              \
   ~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~
../../src-trunk/gcc/sort.cc:112:5: note: in expansion of macro ‘REORDER_45’
     REORDER_45 (8, 8, 0);
     ^~~~~~~~~~
../../src-trunk/gcc/sort.cc:97:18: note: ‘t2’ declared here
   size_t t0, t1, t2, t3;                        \
                  ^~
../../src-trunk/gcc/sort.cc:112:5: note: in expansion of macro ‘REORDER_45’
     REORDER_45 (8, 8, 0);
     ^~~~~~~~~~
../../src-trunk/gcc/sort.cc:101:10: error: ‘void* memcpy(void*, const
void*, size_t)’ forming offset [5, 8] is out of the bounds [0, 4] of
object ‘t3’ with type ‘size_t’ {aka ‘unsigned int’}
[-Werror=array-bounds]
   memcpy (&t3, e3 + OFFSET, SIZE);              \
   ~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~
../../src-trunk/gcc/sort.cc:112:5: note: in expansion of macro ‘REORDER_45’
     REORDER_45 (8, 8, 0);
     ^~~~~~~~~~
../../src-trunk/gcc/sort.cc:97:22: note: ‘t3’ declared here
   size_t t0, t1, t2, t3;                        \
                      ^~
../../src-trunk/gcc/sort.cc:112:5: note: in expansion of macro ‘REORDER_45’
     REORDER_45 (8, 8, 0);
     ^~~~~~~~~~
../../src-trunk/gcc/sort.cc:105:10: error: ‘void* memcpy(void*, const
void*, size_t)’ forming offset [5, 8] is out of the bounds [0, 4] of
object ‘t0’ with type ‘size_t’ {aka ‘unsigned int’}
[-Werror=array-bounds]
   memcpy (out, &t0, SIZE); out += STRIDE;       \
   ~~~~~~~^~~~~~~~~~~~~~~~
../../src-trunk/gcc/sort.cc:112:5: note: in expansion of macro ‘REORDER_45’
     REORDER_45 (8, 8, 0);
     ^~~~~~~~~~
../../src-trunk/gcc/sort.cc:97:10: note: ‘t0’ declared here
   size_t t0, t1, t2, t3;                        \
          ^~
../../src-trunk/gcc/sort.cc:112:5: note: in expansion of macro ‘REORDER_45’
     REORDER_45 (8, 8, 0);
     ^~~~~~~~~~
../../src-trunk/gcc/sort.cc:106:10: error: ‘void* memcpy(void*, const
void*, size_t)’ forming offset [5, 8] is out of the bounds [0, 4] of
object ‘t1’ with type ‘size_t’ {aka ‘unsigned int’}
[-Werror=array-bounds]
   memcpy (out, &t1, SIZE); out += STRIDE;       \
   ~~~~~~~^~~~~~~~~~~~~~~~
../../src-trunk/gcc/sort.cc:112:5: note: in expansion of macro ‘REORDER_45’
     REORDER_45 (8, 8, 0);
     ^~~~~~~~~~
../../src-trunk/gcc/sort.cc:97:14: note: ‘t1’ declared here
   size_t t0, t1, t2, t3;                        \
              ^~
../../src-trunk/gcc/sort.cc:112:5: note: in expansion of macro ‘REORDER_45’
     REORDER_45 (8, 8, 0);
     ^~~~~~~~~~
../../src-trunk/gcc/sort.cc:107:10: error: ‘void* memcpy(void*, const
void*, size_t)’ forming offset [5, 8] is out of the bounds [0, 4] of
object ‘t2’ with type ‘size_t’ {aka ‘unsigned int’}
[-Werror=array-bounds]
   memcpy (out, &t2, SIZE); out += STRIDE;       \
   ~~~~~~~^~~~~~~~~~~~~~~~
../../src-trunk/gcc/sort.cc:112:5: note: in expansion of macro ‘REORDER_45’
     REORDER_45 (8, 8, 0);
     ^~~~~~~~~~
../../src-trunk/gcc/sort.cc:97:18: note: ‘t2’ declared here
   size_t t0, t1, t2, t3;                        \
                  ^~
../../src-trunk/gcc/sort.cc:112:5: note: in expansion of macro ‘REORDER_45’
     REORDER_45 (8, 8, 0);
     ^~~~~~~~~~
../../src-trunk/gcc/sort.cc:108:10: error: ‘void* memcpy(void*, const
void*, size_t)’ forming offset [5, 8] is out of the bounds [0, 4] of
object ‘t3’ with type ‘size_t’ {aka ‘unsigned int’}
[-Werror=array-bounds]
   memcpy (out, &t3, SIZE);                      \
   ~~~~~~~^~~~~~~~~~~~~~~~
../../src-trunk/gcc/sort.cc:112:5: note: in expansion of macro ‘REORDER_45’
     REORDER_45 (8, 8, 0);
     ^~~~~~~~~~
../../src-trunk/gcc/sort.cc:97:22: note: ‘t3’ declared here
   size_t t0, t1, t2, t3;                        \
                      ^~
../../src-trunk/gcc/sort.cc:112:5: note: in expansion of macro ‘REORDER_45’
     REORDER_45 (8, 8, 0);
     ^~~~~~~~~~

Reply via email to