compile time decision for fixed of on-demand cells
added distances to primitives cost calculation