Skip to content

Commit

Permalink
incorrect register in TSX
Browse files Browse the repository at this point in the history
  • Loading branch information
xubiod committed Feb 27, 2024
1 parent e3bd7dd commit 1fdbd16
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions cpu/set_transfer.go
Original file line number Diff line number Diff line change
Expand Up @@ -82,13 +82,13 @@ func (c *Core) TSX____i() {

c.X = c.S

if c.Y == 0 {
if c.X == 0 {
c.Flags = c.Flags | FLAG_ZERO
} else {
c.Flags = c.Flags & ^FLAG_ZERO
}

if c.Y&0b10000000 > 0 {
if c.X&0b10000000 > 0 {
c.Flags = c.Flags | FLAG_NEGATIVE
} else {
c.Flags = c.Flags & ^FLAG_NEGATIVE
Expand Down

0 comments on commit 1fdbd16

Please sign in to comment.