[PATCH] Fix ICE in get_memory_rtx
Eric Botcazou
ebotcazou@adacore.com
Mon Jun 9 09:59:00 GMT 2008
Hi,
Ada is unique in that it can generate aggregate bit-fields (fields with
aggregate types and DECL_BIT_FIELD set) and even variable-sized aggregate
bit-fields. In this latter case, they are aligned to a byte-boundary (the
middle-end doesn't support byte-unaligned objects with variable size) and
occupy an integral number of bytes (same reason) so block-copy operations
can be invoked on them.
That's the case for the attached testcase on SPARC/Solaris. The problem is
that get_memory_rtx stops on any field with DECL_BIT_FIELD set on it.
Tested on i586-suse-linux and sparc-sun-solaris2.8, OK for mainline?
2008-06-09 Eric Botcazou <ebotcazou@adacore.com>
Olivier Hainque <hainque@adacore.com>
* builtins.c (get_memory_rtx): Accept BLKmode and BLKmode-like
bitfields in COMPONENT_REFs. Use DECL_SIZE_UNIT for the size.
2008-06-09 Eric Botcazou <ebotcazou@adacore.com>
* gnat.dg/specs/varsize_copy.ad[sb]: New test.
--
Eric Botcazou
-------------- next part --------------
A non-text attachment was scrubbed...
Name: p.diff
Type: text/x-diff
Size: 1404 bytes
Desc: not available
URL: <http://gcc.gnu.org/pipermail/gcc-patches/attachments/20080609/626bc22f/attachment.bin>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: varsize_copy.ads
Type: text/x-adasrc
Size: 629 bytes
Desc: not available
URL: <http://gcc.gnu.org/pipermail/gcc-patches/attachments/20080609/626bc22f/attachment-0001.bin>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: varsize_copy.adb
Type: text/x-adasrc
Size: 466 bytes
Desc: not available
URL: <http://gcc.gnu.org/pipermail/gcc-patches/attachments/20080609/626bc22f/attachment-0002.bin>
More information about the Gcc-patches
mailing list