You are not logged in.

#1 2008-05-25 01:58:23

liquibyte
Member
Registered: 2007-11-11
Posts: 91
Website

Is there a way to detect -j*

Does anyone know if there is a way to detect how many processors a user has and output the number to make as a variable?  Would it hurt to make -j5 on a processor that can't do more than -j2?  I'm curious to see if anyone has had this thought.

Offline

#2 2008-05-25 03:09:44

hacosta
Member
From: Mexico
Registered: 2006-10-22
Posts: 423

Re: Is there a way to detect -j*

probably a very sucky way to do it but this should work

grep MHz /proc/cpuinfo|wc -l

Offline

#3 2008-05-30 08:44:18

janboe
Member
From: Germany
Registered: 2007-08-09
Posts: 12

Re: Is there a way to detect -j*

well, this whould detect 2 cpus at my pentium-m thinkpad. the reason is:

$ grep MHz /proc/cpuinfo
model name    : Intel(R) Pentium(R) M processor 1500MHz
cpu MHz        : 600.000

what does the job for me is:

grep "^processor" /proc/cpuinfo | wc -l

[pidgin-knotify] Native KDE notifications for pidgin - [series60-remote] Manage your Symbian S60 phone

Offline

Board footer

Powered by FluxBB