use of cpus in building

Comer Duncan comer.duncan at gmail.com
Wed May 25 16:49:15 PDT 2016


Thanks Justin for the perspective!

This 'thread' has helped me a lot in understanding some aspects of the ins
and outs of using more cores and more threads.

Comer

On Wed, May 25, 2016 at 6:07 PM, Justin C. Walker <justin at mac.com> wrote:

>
> On May 25, 2016, at 14:42 , Adam Dershowitz wrote:
>
> >
> >
> >
> >> On May 25, 2016, at 5:25 PM, Brandon Allbery <allbery.b at gmail.com>
> wrote:
> >>
> >> On Wed, May 25, 2016 at 5:22 PM, Christopher Jones <
> jonesc at hep.phy.cam.ac.uk <mailto:jonesc at hep.phy.cam.ac.uk>> wrote:
> >> you don’t. Its automatic for the ports that allow it.
> >>
> >> And this is also true, if that was not clear. Using multiple cores is
> *on by default*. You are already getting it, unless you at some point in
> the past overrode buildmakejobs in macports.conf.
> >>
> >> --
> >
> >
> > You can also manually change it for a single install, for example by
> using build.jobs.  Such as:
> > sudo port install port_whatever_name build.jobs=4
> > and then, for that specific install it will attempt to use 4 cores.
> This can be handy to reduce the number of cores used, from the default, so
> that you can do other things on the machine while building.
>
> FWIW, you can also increase the "thread count" because each core in modern
> Macs provide two "hyperthreads" per core.  It's almost like getting two
> cores per core, but there are various architectural limitations in getting
> "full throttle" performance (memory bandwidth, ...).
>
> Also, to see this in action, you can use the Activity Monitor, and invoke
> "Window -> Floating CPU Window -> {Horizontal, Vertical, None}".  This
> gives you a sort of histogram view of per-hyperthread activity.
>
> I regularly build SageMath on Macs, and usually max out the thread count.
> There can be issues with this.  I've had my systems tie themselves up in
> what appear to be resource knots, but I've never tracked down the real
> cause (the apps I use to see what goes on get stalled when this happens).
> Sometimes the system doesn't recover, but mostly, it does.
>
> HTH
>
> Justin
>
> --
> Justin C. Walker, Curmudgeon-At-Large
> Institute for the Enhancement of the Director's Income
> --------
> Experience is what you get
>   when you don't get what you want.
> --------
>
>
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.macosforge.org/pipermail/macports-users/attachments/20160525/fb60554f/attachment.html>


More information about the macports-users mailing list