Does mprotect flush the instruction cache on ARM Linux?
问题 I am writing a JIT on ARM Linux that executes an instruction set that contains self-modifying code. The instruction set does not have any cache flush instructions (similar to x86 in that respect). If I write out some code to a page and then call mprotect on that page, is that sufficient to invalidate the instruction cache? Or do I also need to use the cacheflush syscall on those pages? 回答1: You'd expect that the mmap/mprotect syscalls would establish mappings that are updated immediately, and