Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
[Compilation]Very abnormal compilation time.
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Other Things Gentoo
View previous topic :: View next topic  
Author Message
Djento
n00b
n00b


Joined: 03 May 2005
Posts: 66
Location: Bruxelles

PostPosted: Thu Aug 23, 2007 1:42 am    Post subject: [Compilation]Very abnormal compilation time. Reply with quote

Hi,

I'm not new to Gentoo's world, but it makes a moment i didn't use it, so now, i've installed the current release of Gentoo and i'm experiencing very bad compile time compared with old experience.
I suspect gcc but why? Is there a signficant changment during these last 7months?

I explain: my previous computer was an petium-m 1.5Ghz with 768mb DDr2, i lost it in April, i'm currently running a pentium-m 1.4Ghz with the same amount/type of memory but the time compile between both are huge.
Look, kernel compile time on my old 1.5Ghz Pentium M was about ~14min, here on the 1.4Ghz Pentum M increases of 30minutes.
Another example: Gimp took me 15-20minutes on my old P-M 1.5Ghz, here on the "100mhz in less" one, it takes more than one hour.

My GCC:
- gcc (GCC) 4.1.1 (Gentoo 4.1.1-r3)
flags: CFLAGS="-O2 -mtune=pentium-m -pipe"

Libs C/C++ are up to date

My harddisk perfs seems correct too:
a 4years old toshiba 40gb 8mb 7200rpm

hdparm -tT /dev/hda:
Timing cached reads: 416 MB in 2.00 seconds = 207.63 MB/sec
Timing buffered disk reads: 74 MB in 3.05 seconds = 24.29 MB/sec

In fact, on the Apple Powerbook G4 1,67 Ghz+1,5Gb DDR2 of my brother, compile time is also too long, in the same range, it is simply abnormal.

What's wrong?

thank you


Last edited by Djento on Thu Aug 23, 2007 4:55 pm; edited 2 times in total
Back to top
View user's profile Send private message
NathanZachary
Moderator
Moderator


Joined: 30 Jan 2007
Posts: 2605

PostPosted: Thu Aug 23, 2007 2:59 am    Post subject: Reply with quote

Well, I have never used -mtune in my /etc/make.conf. I usually use -march=xxx. On my laptop with a Pentium-M, I actually set the -march=pentium4 and saw much better compilation times (with no errors). Possibly you could try that. I have had no negative experiences with gcc-4.1.1.
_________________
“Truth, like infinity, is to be forever approached but never reached.” --Jean Ayres (1972)
---avatar cropped from =AimanStudio---
Back to top
View user's profile Send private message
Akkara
Bodhisattva
Bodhisattva


Joined: 28 Mar 2006
Posts: 6702
Location: &akkara

PostPosted: Thu Aug 23, 2007 3:42 am    Post subject: Reply with quote

Sometimes a speed difference can be the result of different RAM or timings.

Are the motherboards similar? Bios updated?

There was a old motherboard that kept giving me errors which turned out to be bad settings for the RAM - most were too conservative but one was too aggressive (and the cause of the errors). After some hand-tuning I had managed to fix the errors while also increasing the memory bandwidth 30% or so.
Back to top
View user's profile Send private message
Djento
n00b
n00b


Joined: 03 May 2005
Posts: 66
Location: Bruxelles

PostPosted: Thu Aug 23, 2007 11:50 am    Post subject: Reply with quote

Hi,

Thanks for your responses.
Well, i could try -march=pentium4 ou i686 but it will be very strange.

The motherboard is different but chipset is the same. Harddisk too, memory DDR2 266 same.
oh, my current computer use a shared memory vga card (about 16mb)

I used the same make.conf coming from my good experience, the only difference is on my reference computer i began installation on stage 2 and i compiled myself GCC and . Here, the P-M 1,4Ghz and by the past on the G4 1,67Ghz, i used these provided with the distro 2007.x (x86 and PowerPC respectively)

Indeed, that's very strange, if you need more details (Hardware, Kernel config), just ask.

I'm going to try -march option and recompile my GCC

AkKara: what's the options were changed in your BIOS?

EDIT: I'm suspecting the PREEMPTION MODE currently activated, let's digg it.

Regards
Back to top
View user's profile Send private message
obrut<-
Apprentice
Apprentice


Joined: 01 Apr 2005
Posts: 183
Location: near hamburg, germany

PostPosted: Thu Aug 23, 2007 2:13 pm    Post subject: Reply with quote

can it be, that the 1,5 ghz cpu had 2 mb of cache and your current one only 1 mb? a shared memory graphics card does not just eat up some ram but it also reduces the memory bandwidth. in combination with a smaller cache this can degrade performance. you can speed up compilation times by mounting a tmpfs on /var/tmp/portage. search the forums for "temerge". it's a wrapper script that does the mounting an unmounting for you.
Back to top
View user's profile Send private message
Djento
n00b
n00b


Joined: 03 May 2005
Posts: 66
Location: Bruxelles

PostPosted: Thu Aug 23, 2007 5:07 pm    Post subject: Reply with quote

Hi,

No, both Pentium-M banias had 1mb of cache.
Well, preemption was activated in voluntary mode, firstly i've changed to "no preempt", made a compilation and there was no big difference.
Now i recompiled in preemption for desktop, freq latency 1khz, i'm trying to remake a compilation without real expectation anyway.

obrut<- : i'm going to investigate the "temerge" way.

Thank you
Back to top
View user's profile Send private message
didl
Retired Dev
Retired Dev


Joined: 09 Sep 2003
Posts: 1106
Location: Pittsburgh, PA

PostPosted: Thu Aug 23, 2007 10:42 pm    Post subject: Reply with quote

You didn't happen to have ccache enabled on your old box?
Back to top
View user's profile Send private message
Akkara
Bodhisattva
Bodhisattva


Joined: 28 Mar 2006
Posts: 6702
Location: &akkara

PostPosted: Fri Aug 24, 2007 4:18 am    Post subject: Reply with quote

Quote:
my current computer use a shared memory vga card (about 16mb)


That can impact performance if it is using up main memory bandwidth to run the display.

Quote:
Akkara: what's the options were changed in your BIOS?


I went to the screen where it lets you change memory timing - the tRAS, tCAS, stuff like that.

Then I set all memory parameters to their max (slowest) settings.

I also overclocked the machine a little bit for the tests that follow (like 5%), so that I got some built-in margin after I was finished and removed the overclocking.

Then I started with the topmost parameter, and decreased it (made it faster) 1 step at a time, and rebooting to bios to test that it still works at that speed. Kept doing this till it didn't boot, then wrote down the last number it didn't fail at.

Then reset that parameter back to its max, and repeated the above process finding the limit of the second parameter, then third, until I had the limits of all the parameters.

Then I removed the overclocking and set the memory timings to the limits found above, and tested it. Mine worked, but if yours doesn't, try backing off 1 parameter at a time, by 1 step, until it works.

Sometimes you'll get memory that works with timings where one number can be smaller than the rest. like 4 3 4 10 and also with 3 4 4 10 might work, but not 3 3 4 10 nor 3 3 5 10. Use memtest and pick the one that gives the best memory bandwidth.

Then run memtest overnight to be sure.
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Other Things Gentoo All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum