This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
Problem with tree pass pre
- From: shmeel gutl <shmeelgutl at shmuelhome dot mine dot nu>
- To: "gcc at gcc dot gnu dot org" <gcc at gcc dot gnu dot org>
- Date: Mon, 31 Aug 2015 07:51:03 +0300
- Subject: Problem with tree pass pre
- Authentication-results: sourceware.org; auth=none
When dealing with an array with known values, pre will evaluate the
first iteration of a loop over the elements. The code generator with
then jump into the loop. This is at best increasing the size of the
code. It also creates inferior code when the hardware supports zero
overhead loops. The attached code demonstrates the difference between an
unknown array and a known array. The loop size has been picked large
enough for cunrolli to not fully unroll the loop. The problem did not
exist in gcc 4.8.
Attachment:
test.c
Description: Text document