Content deleted Content added
Guy Harris (talk | contribs) Mark a link that has an expired certificate as dead. |
mNo edit summary |
||
Line 4:
{{Use list-defined references|date=December 2021}}
{{Use American English|date=January 2019}}
In [[computer science]], '''self-modifying code''' ('''SMC''') is [[Source code|code]] that alters its own [[instruction (computer science)|instructions]] while it is [[execution (computers)|executing]] – usually to reduce the [[instruction path length]] and improve [[Computer performance|performance]] or simply to reduce otherwise [[Duplicate code|repetitively similar code]], thus simplifying [[Software maintenance|maintenance]]. The term is usually only applied to code where the self-modification is intentional, not in situations where code accidentally modifies itself due to an error such as a [[buffer overflow]].
Self-modifying code can involve overwriting existing instructions or generating new code at run time and transferring control to that code.
|