As far as i know, an assembly program is devided to two- 1)the code 2)the data. Now, when we code, say on c\c++, the code is loaded to the memory and then the CPU starts execute the code, one instruction by one, as an assembly program. My questions are: 1. where is the c code stored? I mean, when I'm running a program in Visual Studio, is the code loaded to one of them- Heap,Stack..? 2. So the memory is virtually divided to Stack,Heap and Date segment, but when the CPU executes the program, as an assembly program, are they all 1 assembly program with the same data area or they are formed in to,lets say 2 or 3 assebmly program thats jumps from one to another?
** Let me add this question, maybe it will clarify my intention: When I'm launching a C program, the code (machine instructions) is loaded to the memory. So, this is one assembly program. But how does the memory division take place? I mean, how des the different memory sections such as Stack, Data segment, etc. modify the assembly program?