JITer allocates space, such as a heap or a stack, and inserts assembly code into it. No, self-editing code is great. VirtualProtect (Windows) and mmap (Unix) can render pages as executable. General operating systems will by default mark executable pages as read / execute, but not write, you can still change this at runtime.
, dll, Virutal Address ; , .
, NX DEP .., , ..