fixed 64-bit release build

Got rid of a ton of size_t usages in core library