Bug 115909

Summary: [GTK] Linking should run sequentially and not in parallel (at least for debug builds)
Product: WebKit Reporter: Claudio Saavedra <csaavedra>
Component: WebKitGTKAssignee: Nobody <webkit-unassigned>
Status: UNCONFIRMED ---    
Severity: Normal CC: berto, bugs-noreply, mrobinson, zan
Priority: P2    
Version: 528+ (Nightly build)   
Hardware: Unspecified   
OS: Unspecified   

Description Claudio Saavedra 2013-05-10 08:11:30 PDT
A debug link of wkgtk can take up to 8 GB of RAM. In a parallelized build more than one instance of ld will be running at the same time, fighting for memory, and causing endless amounts of swapping in and out.

Linking, in particular in debugging builds, should run sequentially.
Comment 1 Alberto Garcia 2013-05-31 03:13:17 PDT
I wonder if the -l option can help here?

https://www.gnu.org/software/make/manual/html_node/Parallel.html#Parallel
Comment 2 Claudio Saavedra 2013-05-31 04:21:27 PDT
Not really, because -l is about reducing the number of jobs when the system load is high. Usually when the I/O is high, the system load is actually low.
Comment 3 Zan Dobersek 2013-07-28 04:08:43 PDT
Hrm, the idea is sound, the realization might be a PITA.

Thinking of it very little, I guess sequential dependencies could be set up for all the linking targets. One problem about that would be keeping such a list up-to-date, though it's only a problem if it doesn't outweigh the benefit of the approach.
Comment 4 Claudio Saavedra 2013-07-29 01:21:23 PDT
There is a special built-in target in GNU make that perhaps can be used for this - - .NOTPARALLEL

  http://www.gnu.org/software/make/manual/make.html#Special-Targets