Great Deal! Get Instant $10 FREE in Account on First Order + 10% Cashback on Every Order Order Now

https://eclass.yorku.ca/pluginfile.php/2113916/course/section/269880/LabK.pdf?time= XXXXXXXXXX

1 answer below »

https:
eclass.yorku.ca/pluginfile.php/2113916/course/section/269880/LabK.pdf?time= XXXXXXXXXX
Answered 2 days After Mar 11, 2022

Solution

Neha answered on Mar 14 2022
114 Votes
Assembly Language
Introduction
The assembly language can be defined as the low-level programming language. This language was introduced to understand the programming language into the machine code. In all the computers they have assembler which is used for converting the assembly code into the machine code which is executable by the system. The assembly language is designed in such a manner so that it can get the instruction and send it to the machine language to perform the processing. The processing generally depends over the architecture whether it is the computer architecture or the operating system.
The assembly language includes the mnemonic processor instructions and some other statements or the instructions along with the data. It is generally used for the compilation of high-level language source code like C or C++. It is used for fine tuning in the program. It is the low-level programming language which is used for the programmable device specifically for the computer architecture. Thus, assembly language is further transformed into the machine code which is executable with the help of utility program, and they are known as the assembler like MASM, NASM etc.
Each of the personal computer have the microprocessor which is able to manage the control, logical and arithmetical activities of the computer. Each family of the processor has their own set of the instructions to handle different operations like getting the input from keyboard, performing different jobs or displaying the information over the screen. The machine processor is able to understand the instructions in machine language only. The machine language is very complex and obscure to use them in the software development and this was the reason why the low-level assembly language was designed to be used with the specific family of the processors.
Advantages of Assembly Language
· It needs less execution time and the memory.
· The assembly language allow us to understand how the program interface with the processor and operating systems.
· It helps to understand how the data is represented in the memory.
· We can understand how the processor is able to access and execute instructions.
· It also allows the hardware specific complex jobs to be performed in easier manner.
· It is able to support time critical jobs.
Basic Syntax
The assembly programs can be divided into three basic sections which are data section text section and bss section.
The data section is used to declare the initialized constants and the data. This data cannot be changed at the runtime, and we can declare different constant values, buffer size or the file names in this section. The following is the syntax to declare the data section.
section.data
The bss section is used to declare the variables and the following is the syntax to declare this section.
section.bss
The text section is used to keep the actual code. This code needs to start with the declaration of global start, and it will inform the kernel about the beginning of the program. The following is the syntax to declare the text section in the code.
section.text
global _start
_start:
Comments
In the assembly language we can write the comments with the help of semicolon. It can have the print table character which also includes the blank and it can appear over the line by itself.
; This code will show a message
The comment can be written on the same line of the code as it written in the following manner.
sub ax, ex ; subtract ax from ex
Assembly Language...
SOLUTION.PDF

Answer To This Question Is Available To Download

Related Questions & Answers

More Questions »

Submit New Assignment

Copy and Paste Your Assignment Here