[Ada] Expand use of TREE_THIS_NOTRAP to unconstrained arrays
Eric Botcazou
ebotcazou@adacore.com
Sun Sep 25 22:50:00 GMT 2011
This expands the use of the TREE_THIS_NOTRAP flag to the dereference expression
built for some unconstrained arrays. It will be propagated onto the regular
INDIRECT_REF expression ultimately passed to the middle-end.
Tested on i586-suse-linux, applied on the mainline.
2011-09-25 Eric Botcazou <ebotcazou@adacore.com>
* gcc-interface/ada-tree.h (TREE_THIS_NOTRAP): Redefine.
* gcc-interface/trans.c (Identifier_to_gnu): Factor out common code in
the by-ref case. Do not set TREE_READONLY on a renamed object. Set
TREE_THIS_NOTRAP on UNCONSTRAINED_ARRAY_REF nodes.
(Attribute_to_gnu) <Attr_Length>: Expand the use of the parameter cache
to the indirect case.
* gcc-interface/utils.c (convert) <UNCONSTRAINED_ARRAY_REF>: Preserve
the TREE_THIS_NOTRAP flag.
--
Eric Botcazou
-------------- next part --------------
A non-text attachment was scrubbed...
Name: p.diff
Type: text/x-diff
Size: 6278 bytes
Desc: not available
URL: <http://gcc.gnu.org/pipermail/gcc-patches/attachments/20110925/4dd19b7f/attachment.bin>
More information about the Gcc-patches
mailing list