Documente Academic
Documente Profesional
Documente Cultură
Referat
Disciplina:Arhitectura Calculatoarelor
A verificat
Chisinau 2021
cmp al,'y'
jz IsDad
cmp al,'n'
jz IsNud
ex:
exit
main ENDP
END main
INCLUDE Irvine32.in
C ; Include file for Irvine32.lib
(Irvine32.inc
C
C ;OPTION CASEMAP:NON ; optional: make identi-
fiers case-sensitiv
C
C INCLUDE SmallWin.in ; MS-Windows prototypes,
structures, and constant
C .NOLIS
C .LIS
C
C INCLUDE VirtualKeys.in
C ; VirtualKeys.in
C .NOLIS
C .LIS
C
C
C .NOLIS
C .LIS
C
0000000 .dat
00000000 44 6F 72 65 7 Promt DB 'Doresti sa devii programator?(da/nu)-[y/n]',
74 69 20 73 6
20 64 65 76 6
69 20 70 72 6
67 72 61 6D 6
74 6F 72 3F 2
64 61 2F 6E 7
29 2D 5B 79 2
6E 5D 0
0000002B 0D 0A 56 65 6 Dad DB 13,10,'Vei deveni!',13,10,
20 64 65 76 6
6E 69 21 0D 0
0
0000003B 0D 0A 56 65 6 Nud DB 13,10,'Vei deveni filosof!',13,10,
20 64 65 76 6
6E 69 20 66 6
6C 6F 73 6F 6
21 0D 0A 0
0000000 .cod
0000000 main PRO
0000002 ex
0
0
0
D
m
0
9
4
E
C
A
0
3
9
9
R
E
E
R
E
R
E
s
E
c
c
0
1
exi
0000002D 6A 0 push +000000000
0000002F E8 00000000 E call ExitProces
0000003 main END
END mai
_Microsoft (R) Macro Assembler Version 12.00.31101. 03/18/15 11:15:4
Source.as Symbols 2 -
4
m
0
*
*
n
0
s
pe 64 biţi:
; AddTwoSum_64.asm - Ch3 example.
ExitProcess proto
.data
sum qword 0
.code
main proc
mov rax,5
add rax,6
mov sum,rax
mov ecx,0
call ExitProcess
main endp
end
Concluzie:
În aceasta lucrare am învățat instrucțiunile de bază ale limbajul de programare MASM în VS, a
fost realizat scopul de scriere a programelor in MASM pe 16, 32 și 64 de biți, după care sa anal-
izat offseturile și verificat logica de lucru a asemblerului.