Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

Expand the instruction set with advanced operations. #4

Merged
merged 1 commit into from
Aug 6, 2024
Merged

Conversation

yezzfusl
Copy link
Owner

@yezzfusl yezzfusl commented Aug 6, 2024

  1. Expanded the instruction set with new logical operations: and, or, xor, and not.
  2. Added shift operations: shl (shift left) and shr (shift right).
  3. Implemented a comparison operation cmp that sets flags based on the result.
  4. Added jump instructions: jmp (unconditional jump), je (jump if equal), jne (jump if not equal), jg (jump if greater), and jl (jump if less).
  5. Introduced a flags register to store comparison results.
  6. Modified the decode function to accommodate the expanded instruction set.
  7. Added new unit tests to verify the correctness of the new instructions.

Copy link
Owner Author

@yezzfusl yezzfusl left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The expanded instruction set adds significant functionality, including control flow and more complex arithmetic and logical operations. The new instructions are seamlessly integrated into the CPU emulator.

@yezzfusl yezzfusl merged commit a345104 into main Aug 6, 2024
@yezzfusl yezzfusl self-assigned this Aug 6, 2024
# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant