Early memory allocation