Merge "Add sanity check for large object allocation"