We've just updated MediaWiki and its underlying software. If anything doesn't look or work quite right, please mention it to us. --RanAS

SEV: Difference between revisions

From SnesLab
Jump to: navigation, search
(SEP)
(→‎External Links: hid archive URL for E&L)
 
(6 intermediate revisions by the same user not shown)
Line 1: Line 1:
SEV (SEt Overflow) is a mnemonic for a non-existant 6502 instruction.
SEV (SEt Overflow) is a mnemonic for a non-existant 6502 instruction.


To set the [[overflow flag]], consider using [[SEP]].
To set the [[overflow flag]], consider using [[SEP]] or [[BIT]]. Like this:
 
<pre>
SEP #$40
</pre>
 
A common way is to use BIT on the address of a byte in ROM that has bit 6 set, like an [[RTS]].<sup>[1]</sup>


=== See Also ===
=== See Also ===
Line 8: Line 14:


=== External Links ===
=== External Links ===
* http://www.6502.org/tutorials/vflag.html
# Clark, Bruce. http://www.6502.org/tutorials/vflag.html
* page 263, https://archive.org/details/0893037893ProgrammingThe65816/page/n289
# [[Eyes & Lichty]], [https://archive.org/details/0893037893ProgrammingThe65816/page/263 page 263]


[[Category:ASM]]
[[Category:ASM]]
[[Category:Non-Existant Instructions]]
[[Category:Non-Existant Instructions]]

Latest revision as of 01:50, 10 August 2024

SEV (SEt Overflow) is a mnemonic for a non-existant 6502 instruction.

To set the overflow flag, consider using SEP or BIT. Like this:

SEP #$40

A common way is to use BIT on the address of a byte in ROM that has bit 6 set, like an RTS.[1]

See Also

External Links

  1. Clark, Bruce. http://www.6502.org/tutorials/vflag.html
  2. Eyes & Lichty, page 263