On Mon, 12 Mar 2001, Dan Phoenix wrote:
> CC="gcc -O6 -fomit-frame-pointer" OPTIM="-O2 -DBUFFERED_LOGS"
>
> could some c guru tell me if this would be bad to use to an apache
> optimization? I need to compile apache on my own not with ports....
> looking at makefile
> in apache13 in ports collection i see these optimization flags.
> along with --mmap-static module.
>
>
> can you use both -06 and -02 for optmization at the same time?
> -fomit-frame-pointer as well?
-O6 and -O2 do seem a bit contradictory. I'm guessing it just uses -O6.
-fomit-frame-pointer is not enabled per the -O flags so that does do
something, but it does make it rather difficult to track down problems
without a frame pointer.
> this is my full config line so far
> CC="gcc -O6 -fomit-frame-pointer" OPTIM="-O2 -DBUFFERED_LOGS" ./configure
> --prefix=/usr/local/apache --enable-module=rewrite
> --activate-module=src/modules/php4/libphp4.a
>
> alot of other crap modules get thrown into httpd.conf as well i have
> noticed....slowly researching each and disabling what i don;t need.
Unless you really need mod_rewrite, I suggest you don't use it. It's
rather black-magicish, difficult to get working, and as I recall, I think
it's had some security issues about it.
> INterested in talking with some c experts and apache experts on this
> issue.
I probably qualify for the latter.... Optimizations are good and all, but
I look at it this way: It's a mission critical webserver, I don't want it
crashing. As a result, we compile ours with nothing higher that -O2 and no
unusual optimizations. Sure, it might be a bit slower than it could have
been, but we don't have to worry about chasing down compiler bugs that
interact strangly with the webserver code. Also, I think anything higher
than -O2 actually produces a larger binary (it inlines functions whenever
possible). Again, I don't like living on the bleeding edge when it comes
to revenue streams.
Hope this helps,
-gordon
To Unsubscribe: send mail to [EMAIL PROTECTED]
with "unsubscribe freebsd-hackers" in the body of the message