diff options
author | Jakub Jelinek <jakub@redhat.com> | 2019-06-11 10:20:02 +0200 |
---|---|---|
committer | Jakub Jelinek <jakub@gcc.gnu.org> | 2019-06-11 10:20:02 +0200 |
commit | 9f95c526a9f165fb7026d2ebd9a2ca82b25a503d (patch) | |
tree | d6896357effad66046535797bf297604cf2e6cde /gcc/trans-mem.c | |
parent | 3f2cf0365782a0d5acf637b7513dd333af43ea05 (diff) | |
download | gcc-9f95c526a9f165fb7026d2ebd9a2ca82b25a503d.zip gcc-9f95c526a9f165fb7026d2ebd9a2ca82b25a503d.tar.gz gcc-9f95c526a9f165fb7026d2ebd9a2ca82b25a503d.tar.bz2 |
re PR bootstrap/90819 (-Walloc-size-larger-than error in trans-mem.c)
PR bootstrap/90819
* trans-mem.c (tm_memopt_compute_available): Add assertion
that blocks is not empty. Formatting fix.
From-SVN: r272145
Diffstat (limited to 'gcc/trans-mem.c')
-rw-r--r-- | gcc/trans-mem.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/gcc/trans-mem.c b/gcc/trans-mem.c index d16f5f9..35d4fab 100644 --- a/gcc/trans-mem.c +++ b/gcc/trans-mem.c @@ -3708,9 +3708,9 @@ tm_memopt_compute_available (struct tm_region *region, /* Allocate a worklist array/queue. Entries are only added to the list if they were not already on the list. So the size is bounded by the number of basic blocks in the region. */ + gcc_assert (!blocks.is_empty ()); qlen = blocks.length () - 1; - qin = qout = worklist = - XNEWVEC (basic_block, qlen); + qin = qout = worklist = XNEWVEC (basic_block, qlen); /* Put every block in the region on the worklist. */ for (i = 0; blocks.iterate (i, &bb); ++i) |