implemented more memory alloc. optimizations
- added frame alloc. counter