UPGRADE YOUR BROWSER

We have detected your current browser version is not the latest one. Xilinx.com uses the latest web technologies to bring you the best online experience possible. Please upgrade to a Xilinx.com supported browser:Chrome, Firefox, Internet Explorer 11, Safari. Thank you!

cancel
Showing results for 
Search instead for 
Did you mean: 
Observer adithyab
Observer
1,193 Views
Registered: ‎10-01-2018

Petalinux build takes too long

I have started using petalinux (2018.2) for generation of linux images.

I thing I find annoying is that the build is very slow. Even if I change just one line in kernel, build easily takes 15~20 minutes. Even something like 'petalinux-build -c kernel' does not seem to make any difference.

Is there any way to speed up the build?

9 Replies
Moderator
Moderator
1,183 Views
Registered: ‎09-12-2007

Re: Petalinux build takes too long

Moderator
Moderator
1,163 Views
Registered: ‎12-04-2016

Re: Petalinux build takes too long

Hi @adithyab

Please refer to UG1144 guide below (Page 33) which explains Build optimization techniques

https://www.xilinx.com/support/documentation/sw_manuals/xilinx2018_3/ug1144-petalinux-tools-reference-guide.pdf

 

 

Best Regards

Shabbir

Observer adithyab
Observer
1,141 Views
Registered: ‎10-01-2018

Re: Petalinux build takes too long

@shabbirk

Thanks.

I have removed the fsbl and pmu as I don't need it to build every time.

I did see a parallel thread tab in yocto settings which was blank. I have set both the number of threads and parallel make to 4 (number of cpu cores). I don't see that this is mentioned in the user guide.

local Sstate looks like interesting option. I will need some time to download and set it up.

0 Kudos
Explorer
Explorer
1,130 Views
Registered: ‎10-21-2015

Re: Petalinux build takes too long

Hi 

See Building Ignoring Dependencies at p35 of ug1144

petalinux-build -b recipe ignore depencies of the recipe

You can set local sstate location from Yocto Setting using petalinux-config

 

0 Kudos
Scholar watari
Scholar
508 Views
Registered: ‎06-16-2013

Re: Petalinux build takes too long

Hi @adithyab 

 

Why don’t you use package management system ?

Petalinux supports it.

 

Best regards,

0 Kudos
Explorer
Explorer
424 Views
Registered: ‎10-04-2017

Re: Petalinux build takes too long

It may be cliche to say but get a bigger system, mine is 32-core deskside.   I can build 2018.2 for an ultra96 board from scratch in about 15 minutes.   Something is wrong in 2018.3 since chrome and webkitgtk takes forever but disabling those and it's back to 16.   But I agree that the overhead of petalinux and yocto is a lot but there are a lot of positives.  If doing a lot of kernel work you  can build it outside of yocto and use scripts/makefile to get around the overhead but it takes time to get that working.

 

jeff

 

0 Kudos
Observer holotronic
Observer
356 Views
Registered: ‎07-02-2018

Re: Petalinux build takes too long

I'm also building 32 core for the Ultra96 with 32GB of ram in petalinux 2019.1 takes 80 min,  (due to swapping)

Building Chromium and webkitgtk push the memory usage up to Allmost 64GB, when running no other applications

(tops out at allmost 32GB of swap space) while Chromuim is building.

Since there is only options for reducing number of threads and number of parrallel jobs, I don't see

how that can be utilized to limit Chromiums memory build requirements without tradding off "muscle/time" elsewhere

(perhaps 8 threads pr job 2 parallel jobs only  through the whole build to avoid swapping ???)

So I have instead ordered 32GB of ram upgrade....

 

0 Kudos
Explorer
Explorer
315 Views
Registered: ‎10-04-2017

Re: Petalinux build takes too long

Hi,

  This is a problem that started in  2018.3.   My build was fine in 2018.2 and then chrome, WebKit and rootfs creation just killed it in 2018.3

  The version of chrome remained the same so I’m not sure what has happened.   I don’t need those packages so I’ve disable the packagegroup that contained them and my build time is back to something reasonable.

  Sadly, I added PYNQ as a user layer today and my build time went up by 10 minutes.

 

Jeff

0 Kudos
Highlighted
Observer viggsy
Observer
176 Views
Registered: ‎05-16-2019

Re: Petalinux build takes too long

I am currently trying to do a petalinux build but it fails at do_rootfs.
Do you have any idea what the error could be?
0 Kudos