From: Hugh Sasse Date: 2005-11-29T01:18:06+09:00 Subject: Re: building ruby for speed: wise or otherwise? On Tue, 29 Nov 2005, Joel VanderWerf wrote: > Hugh Sasse wrote: > > My active record based script is taking longer than I'd like. > > While I wait for approval to get a faster machine :-) I'm wondering > > about rebuilding ruby 1.8.2 (which I have now) and changing the > > CFLAGS from the default > > CFLAGS=-g -O2 > > to > > CFLAGS=-O3 > > or something of the sort. I'm presently using gcc-3.4.3 on > > Solaris9. Has anyone done this and if so is there anything I should > > watch out for? ISTR reported problems when building other packages > > with high -O values in the past. > > > > Would the answer be different for gcc-4.0.2? > > If gcc-4.x is an option, try it. Anecdotally, it's substantially faster Yes, I'm unpacking the tarball now, as x.0.2 is sufficiently tried and tested to be worth looking at, for my situation. > than 3.x. In fact, it's one less reason for me to use msvc on windows: > code compiled with gcc-4.0 (with -O2) turns out to be faster than msvc > for some numerically intensive simulation code running as a ruby > extension, whereas msvc was faster than gcc-3.x output code. YMMV. thanks for that. Still curious about dropping -g and bumping up to -03 though... :-) > Hugh