You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Defining data contents is quite tedious now: One has to write code that places the data somewhere in memory - currently only the stack is available for that - and the data cannot be referred to by labels. There is some support for generating this code using the "Code Gen Save String" example, which queries for a string and outputs the code to be used for storing it in memory, but again, this is tedious to use.
The MARS Emulator - which seems to have been a bit of an inspiration for WeMIPS - provides a separate .data segment and some directives - including an .asciiz directive - to define data contents, and a .text directive to introduce actual assembly code. We could implement something similar to that.
A good start would be to implement the follwing
.data directive to introduce data declarations
.text directive to introduce code definitions (without any directives used, this would be the default at the start)
.word directive to fill the data segment with word-sized entries (signed or unsigned)
labels in data space referring to data locations
The text was updated successfully, but these errors were encountered:
Defining data contents is quite tedious now: One has to write code that places the data somewhere in memory - currently only the stack is available for that - and the data cannot be referred to by labels. There is some support for generating this code using the "Code Gen Save String" example, which queries for a string and outputs the code to be used for storing it in memory, but again, this is tedious to use.
The MARS Emulator - which seems to have been a bit of an inspiration for WeMIPS - provides a separate
.data
segment and some directives - including an.asciiz
directive - to define data contents, and a.text
directive to introduce actual assembly code. We could implement something similar to that.A good start would be to implement the follwing
.data
directive to introduce data declarations.text
directive to introduce code definitions (without any directives used, this would be the default at the start).word
directive to fill the data segment with word-sized entries (signed or unsigned)The text was updated successfully, but these errors were encountered: