PR# 10845 C compiler optimization option repeated twice for freeze or finalize
Problem Report Summary
Submitter: prestoat2000
Category: EiffelStudio
Priority: Medium
Date: 2006/07/31
Class: Bug
Severity: Non-critical
Number: 10845
Release: 5.7.62110
Confidential: No
Status: Analyzed
Responsible: manus_eiffel
Environment: Mozilla/5.0 (X11; U; SunOS sun4u; en-US; rv:1.7.10) Gecko/20050726 Firefox/1.0.6
Solaris 9 on SPARC
Synopsis: C compiler optimization option repeated twice for freeze or finalize
Description
Freeze a system. C compiler optimization option is repeated twice (-O0 -O0) - see C output window. Similarly, for a finalization the option is "-O3 -O3". My value for CFLAGS is "-pipe -D__BUILTIN_VA_ARG_INCR -Wall -Wno-unused". This doesn't really hurt anything, but looks a little silly.
To Reproduce
Problem Report Interactions
This is reproducible by setting $CFLAGS=-xO2 when finalizing.
I can't reproduce it at home on Solaris x86. Could it be specific to Solaris on SPARC? I just tried at work and it happens with command line compiler too. I don't think I modified config.sh (didn't need to thanks to the changes you made!) or finish_freezing. And CFLAGS doesn't have any optimization options. Actually, I just found out that I *can* reproduce it on Solaris x86 if I finalize. Apparently the "optimize" variable for finalization is "-xO2" and "wkoptimize" is "". So on x86 platform, it is doubled only if I finalize and only if CFLAGS environment variable is set. CFLAGS must also be set for it to happen on Solaris SPARC.
I cannot reproduce the problem. Is this happening also when compiled from the command line? Is this in the generated Makefile?