Jarkko Hietaniemi wrote:
Jarkko Hietaniemi wrote:
cc: Warning: sv.c, line 2943: This statement uses the type "struct sv"
to reference the same storage location as the statement at line number
3174 in file sv.c, which uses the type "struct gv". This does not
conform to the ANSI aliasing rules. (badansialias)
SvAMAGIC_off(dstr);
----^
dtype = SvTYPE(dstr);
2943: SvAMAGIC_off(dstr);
if ( SvVOK(dstr) )
{
and
CV* const cv = GvCV(dstr);
if (cv) {
3174: if (!GvCVGEN((GV*)dstr) &&
(CvROOT(cv) || CvXSUB(cv)))
I am guessing tru64 cc would like ANSI aliasing rules because of
optimisation being turned on.
Since gcc uses -fno-strict-aliasing, let's make Tru64 follow suit.
This affects OpenVMS also:
Tru64 and OpenVMS share the same compiler with many of the same
defaults. Currently for OpenVMS, ANSI aliasing is active.
CC
/ANSI_ALIAS
/ANSI_ALIAS
/NOANSI_ALIAS
Directs the compiler to assume the ANSI C aliasing rules, thus
giving it the freedom to generate better optimized code.
The aliasing rules are explained in Section 3.3, paragraphs 20 and
25 of the ANSI C Standard.
The default is /NOANSI_ALIAS for the /STANDARD=VAXC and
/STANDARD=COMMON compiler modes. The default is /ANSI_ALIAS for
all other modes.
Tru64 and OpenVMS share the same compiler with many of the same
defaults. Currently for OpenVMS, ANSI aliasing is active.
-John
[EMAIL PROTECTED]
Personal Opinion Only