stride code for managed memory