Introduction to A. Out (Hello, world Program ) What happened after execution? This is a rough description of system hardware and operations, which is helpful to us. If any error occurs in the middle, please do not hesitate to inform us. Read the. out command from the keyboard. When we open our terminal, the shell program will execute its command and wait for our input. When we enter "A. Out" on the keyboard and press enter, shell will know that we have ended the command input. Then the shell command will read the target file a. out one by one. Code And data to the Register, and then copy the code and data to the primary storage. The flowchart is as follows:
How does one run in hardware?
Popular Science:
1. The primary storage is used to store the data processed by commands and commands.
2. The processor (short for CPU) is the engine for interpreting (or executing) commands stored in the primary storage. At any time point, the PC (program counter) in the CPU points to a machine language instruction in the main memory.
3. There is a DMA (direct Storage Access) technology that allows data to be directly transferred from the disk to the primary storage without passing through the processor.
From the memory write output string to the display 1. Once the code and data in the. out target file are loaded into the main memory, the CPU starts to execute
Main Program of Main. C program Machine language commands. 2. These commands copy the bytes in the "Hello, world \ n" string from the primary memory to the register file. 3. copy the file from the register to the display device and display it on the screen. Flowchart:
How are these running in hardware?
The problem is summarized from two perspectives: Machine commands: First copied to the primary storage on the disk (when the program is loaded) (when the processor runs the commands) copy from the primary storage to the processor. Data string: The data string is initially copied to the primary storage on the disk and the device is displayed. References: in-depth understanding of computer systems
Recommendation