Added host memory fallback, nits in code.