mmap pages and stack improvement