Initial version of generator - not working well for many cells
Little fix in generator
Working version of generator. Added flag ENSURE_FAST_GENERATION