In a high-level language, this is the job of the compiler, though. If the compiler isn&#x27;t generating those instructions for cases where the increment can be proven to be 1, I would consider it a bug.