Skip to content

Conversation

YoshiRulz
Copy link
Member

dev build for branch | TASEmulators:regs-mem-domain

Screenshot_20250926_042924

@YoshiRulz YoshiRulz linked an issue Sep 25, 2025 that may be closed by this pull request
@YoshiRulz YoshiRulz changed the title Create a MemoryDomain subclass which wraps IDebuggable reg get/set Create a MemoryDomain subclass which wraps IDebuggable.{GetCpuFlagsAndRegisters,SetCpuRegister} Sep 25, 2025
@vadosnaprimer
Copy link
Contributor

I like the concept. No idea about the code tho.

@YoshiRulz YoshiRulz added Request: Feature/Enhancement For feature requests or possible improvements Tool: Hex Editor labels Sep 26, 2025
Copy link
Contributor

@SuuperW SuuperW left a comment

Choose a reason for hiding this comment

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

  1. I think it would be better to not modify cores' code. It should be possible to conditionally add the registers domain outside of the core, depending on if it provides the required service.

  2. I don't exactly like the inefficiencies here with reading and writing more than necessary, but I suppose there's not a lot you could realistically do about that.

  3. I also see unchecked in a lot of places. Does this provide any benefit? Since unchecked is default, this seems like unneeded fluff.

@YoshiRulz
Copy link
Member Author

  1. I think it would be better to not modify cores' code. It should be possible to conditionally add the registers domain outside of the core, depending on if it provides the required service.

In BasicServiceProvider maybe? It can't be something the Hex Editor does internally if we want it to be usable from the APIs.

  1. I also see unchecked in a lot of places. Does this provide any benefit? Since unchecked is default, this seems like unneeded fluff.

Enabling $(CheckForOverflowUnderflow) is one of my long-term cleanup goals.
Some casts in unchecked are equivalent to the same cast without it, not sure which, but if someone cared enough to make a list we could flag those with an Analyzer. I just have muscle memory to write unchecked((uint) n) instead of something clearer like Unsafe.As<int, uint>(ref n).

@SuuperW

This comment was marked as off-topic.

@YoshiRulz

This comment was marked as off-topic.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Request: Feature/Enhancement For feature requests or possible improvements Tool: Hex Editor
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Genplus-gx advanced VDP Viewer and Hex Editor
3 participants