vhelin / wla-dx

WLA DX - Yet Another GB-Z80/Z80/Z80N/6502/65C02/65CE02/65816/68000/6800/6801/6809/8008/8080/HUC6280/SPC-700/SuperFX Multi Platform Cross Assembler Package
Other
548 stars 98 forks source link

SECTION attribute to prevent crossing a page boundary #501

Closed Kroc closed 2 years ago

Kroc commented 2 years ago

This is kind of like alignment, but the ability to specify that a SECTION/RAMSECTION must not cross an 8-bit boundary. If a section can be guaranteed not to cross into a 9th bit, then I can make Z80/SM83 code faster by only incrementing an 8-bit counter instead of a 16-bit counter. I just got bitten by this today when code I added bumped a table over a boundary and my code exploded unintentionally!

This is not quite the same as ALIGN, as the actual position with the 256-byte range may not be important at all, and even with ALIGN you still may not want a section to go over the 8-bit boundary.

I don't really have a suggestion what keyword could be used for this.

vhelin commented 2 years ago

Have you checked out WINDOW and BITWINDOW? .SECTION has those and I think they should do the job...

Kroc commented 2 years ago

These aren't in the current online documentation and the documentation isn't included in releases either :/

vhelin commented 2 years ago

Yes they are in the documentation in v10.1 release. Yes they are here: https://www.villehelin.com/wla-README.html

No, they are not in the Documentation linked in README.md, for some reason. Which is kind an issue... Why https://wla-dx.readthedocs.io/en/latest/ is out-of-date? This needs to be solved...

vhelin commented 2 years ago

Ok, Read the Docs can now build the latest documentations.

Kroc commented 2 years ago

Ah, BITWINDOW is perfect, thanks!