Skip to content
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

Update cpu instruction definition and asm programs for customasm v0.11 #5

Open
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

sparr
Copy link

@sparr sparr commented Dec 12, 2022

List of changes:

The submodule change abandons your 4 divergent commits. They might be worth a PR?

resolves #2

#bits in global scope
#bankdef and #bank ".data"/".instr" is now bare data/instr
consistent indenting in #bankdef
nested #tokendef is now #subruledef, in global scope
#cpudef is now #ruledef
token/subrule def "=" is now "=>"
cup/rule def "->" is now "=>"
3'5 constant is now 5`3 (hlorenzi/customasm#158)
#str is now #d
@sparr
Copy link
Author

sparr commented Dec 13, 2022

It's difficult to compare assembled results of the example programs because it seems some of the existing ones were assembled with and without (and partially with?) the ldi optimization discussed in #6

@vascofazza
Copy link
Owner

Thank you for the PR.
It is actually difficult to compare due to the indentation. Did you make any change to the instructions due per #6 ?

I actually already merged the PRs into the original repository, it's curious the changes are not there anymore?
hlorenzi/customasm#35
hlorenzi/customasm#37

@sparr
Copy link
Author

sparr commented Dec 14, 2022

re issue 6, I did not change line 41, ldi {dst: reg} 0 -> 0b11 @ 0b01 @ 0b00 @ dst[1:0], other than to fix the =>. The third crumb is still 0b00 so it should still behave identically.

re the upstream repo, I'm confused because I do see your commits merged in the PRs you linked, but https://github.com/vascofazza/customasm still says it's 4 commits ahead and hlorenzi/customasm@main...vascofazza:customasm:master lists some of your merged commits. Probably not worth worrying about right now if you're willing to move the submodule dependency to the upstream commit.

@sparr sparr mentioned this pull request Dec 14, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Version control w/ example code and customasm syntax
2 participants