what is the name of a DATA directive is used for?

Viewed 118

I am really new to the assembly language(Started to learn just a couple of days ago). I am trying to figure out directives in assembly. As far as I understand, directives are like a variable declaration in high-level languages. For example, after the

AREA myData, DATA 

line, I need to initialize my variables and to start inserting instructions; I need to start with adding this line:

AREA myCode, CODE, READONLY

And if I want to declare more variables I need to write first line again. Please correct me if I am wrong.

My question is, what are the names 'myData' and 'myCode' really for? Do I need to use 'myData' name for accessing the variables declared at that part or does it contain some sort of address?

If it is a repeated question I am sorry. I searched but could not find any answer to that spesific question.

0 Answers
Related