This is the mail archive of the
mailing list for the GCC project.
[Bug middle-end/20937] BLK ptr's losing original ptr's static-constant readonly attribute.
- From: "schlie at comcast dot net" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 12 Apr 2005 12:45:58 -0000
- Subject: [Bug middle-end/20937] BLK ptr's losing original ptr's static-constant readonly attribute.
- References: <email@example.com>
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
------- Additional Comments From schlie at comcast dot net 2005-04-12 12:45 -------
(In reply to comment #0)
As heads up, I've verified this is a target problem, the block mem-move expansion needs
to treat the expansion differently if the source is a READONLY. This only leaves three issues:
- For some reason although __FUNCTION__ appeares to be declared as a "static const", references
to it aren't being corespondingly properly marked? (this should likely be considred a bug).
- For some reason, GCC is casting "char" to "int" prior to returning their value as a "char", which
although works, is a fairly gross mis-optimization? (which should also likely be considred a bug).
- Finally, as likely an enhancment request, could it please be considred to allow function pointer
parameters to point to a "static" storage qualifed type, (as opposed to qualifying the parameter
itself as being qualifed). Thereby enabling a function to differentiate between (static const)* vs.
(const)* parameters so that their references may be ideally differentiated within the body of the
function? (as a hopfully broadly usefull extention to enable "static data" to be potentially more
optimally allocated in a different storage area than run-time allocated data storage may be.)