[Ada] Fix ACATS failures on PowerPC/Linux

Eric Botcazou ebotcazou@adacore.com
Thu Sep 8 21:54:00 GMT 2011


This fixes the 6 ACATS failures present at -O2 on PowerPC/Linux:

FAIL:   cd1009a
FAIL:   cd1009i
FAIL:   cd1c03a
FAIL:   cd2a21c
FAIL:   cd2a24a
FAIL:   cd2a32a

The problem is a very aggressive SCCVN pass looking through a special view 
conversion we build in gigi.  The optimization relies exclusively on types of 
bitfields in lieu of their sizes and this doesn't play nice with this view 
conversion.  The patch adjusts the types so as to make the pass happy.

Tested on x86-64/Linux and PowerPC/Linux, applied on the mainline.


2011-09-08  Eric Botcazou  <ebotcazou@adacore.com>

	* gcc-interface/utils.c (unchecked_convert): Use a field of the right
	precision when converting to or from an integral type whose precision
	is not equal to its size.


-- 
Eric Botcazou
-------------- next part --------------
A non-text attachment was scrubbed...
Name: p.diff
Type: text/x-diff
Size: 3049 bytes
Desc: not available
URL: <http://gcc.gnu.org/pipermail/gcc-patches/attachments/20110908/c7e509d2/attachment.bin>


More information about the Gcc-patches mailing list