-
-
Notifications
You must be signed in to change notification settings - Fork 172
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Improve instruction documentation #1560
Comments
I've taken the liberty of reformatting your comment, so that it becomes a checklist for us :)
You might be surprised to learn that The issue becomes finding the right wording. First off, since
Yes, thank you! These sound like improvements.
I'm not sure what you're talking about here. Can you point at / link to a specific example?
Perhaps we should call it something else, then. Maybe
Ah, well, we don't really control the HTML generation.
Interesting. I thought the term was more widespread. Sure, feel free to open a PR against
That sounds fair. We can, and maybe should, link to https://bgb.bircd.org/manual.html#expressions to explain
Optimisation tips indeed definitely don't belong in |
Great!
I'm not a 100% sure. But with this, noone will first think that this is some kind of optimized general-purpose integer, which was my first reaction.
Ah! Because the HTML files were just static files in the repository where this issue was originally posted, I thought this was easily changed, though I did wonder how they even got there in the first place.
At least Wikipedia uses the "bitwise NOT" term first, and then calls "bitwise complement" and alias. I primarily use Delphi (Pascal) for programming, a language that does not distinguish between bitwise and logical operators at all (except for shifts, which have no logical "true/false" equivalent), and also spelling these operators out. All these suggestions are only about
If that's in scope of the document. |
Be sure to use the master-branch docs; we've already moved |
I see, this was still cached. I had no idea my browser's cache could live for so long! |
Re: the It appears common for SM83 assemblers to output a two-byte
Although it's not universal:
|
Going through all the points:
|
Oh, you linked to the documentation for v0.8.0, not
You have a point that we may want to point this out within
I think a “improvements to instr docs” draft PR can be created already, and one or more commits pushed with the changes we have agreed upon thus far; this would let their wording be bikeshed in parallel to debating other changes here. Once more changes are agreed upon here, they can be added to that PR.
Yeah, I think it's worth linking to it. For discovery purposes, if nothing else. |
Re: I'm also fine with opening an issue to discuss moving the pokecrystal optimizations page. I could probably shorten the one on pret to just link to gbdev and explain the Pokemon-specific options. |
STOP
When reading through
gbz80(7)
's documentation, I noticed it saysSTOP
was 2 bytes long, when the instruction itself is only 1, not located in CB and doesn't take useful arguments. People on Discord pointed me to this chart (which BTW misses a "Yes" label at the very bottom). I suggest the documentation say something like this:Some other suggestions:
<abbr>
HTML tag, one would expect the anchors to have a hint or point to the legend (or something like that), when in fact it's just a useless link. The legend of the 8-bit instructions looks really odd as B, D, E and L are underlined, but A, C, and H are not.CPL
should mention that the operation is also known as "bitwise NOT". I do programming for 20 years (though in high-level languages) and this was the first time I ever saw this operation being called the complement.LD r8,r8
doesn't do anything at all if both arguments are the same. I thought that there must be a use if these exist, butLD [HL], [HL]
does not — but there's no use, except for BGB usingLD B, B
for breakpoints andLD D, D
for debug.LD A, 0
could be written asXOR A
, andCP 0
could be written asAND A
orOR A
, although flags are different. I acknowledge that this document is probably the wrong place for notes like that. If so, is there a location for community notes and advice on individual instructions?The text was updated successfully, but these errors were encountered: