[PATCH i-g-t v2 4/5] tests/xe_compute_preempt: adjust number of children according to ram size

Zbigniew Kempczyński zbigniew.kempczynski at intel.com
Mon Apr 7 19:01:43 UTC 2025


On Mon, Apr 07, 2025 at 10:49:38AM +0200, Dandamudi, Priyanka wrote:

<cut>

> > +				 * Get half of ram / 2, then divide by
> > +				 * CONTEXT_MB * 2 (long and short) job
> > +				 */
> > +				child_count = ram_mb / 2 / CONTEXT_MB / 2;
> Here it should be CONTEXT_MB* 2 or CONTEXT_MB/2 ??
> -- Priyanka

child_count = ram_mb / 2 / CONTEXT_MB / 2;

or

child_count = ram_mb / 2 / (CONTEXT_MB * 2);

are equal.

--
Zbigniew


> > +
> > +				igt_debug("RAM: %zd, child count: %d\n",
> > +					  ram_mb, child_count);
> > 
> >  				test_compute_preempt(xe, hwe, false);
> >  				igt_fork(child, child_count)
> > --
> > 2.34.1
> 


More information about the igt-dev mailing list