【正文】
y dw 2z dw ?DATAS ENDSCODES SEGMENT ASSUME CS:CODES,DS:DATASSTART: MOV AX,DATAS MOV DS,AX sub sp,2 push y push x call cal pop z mov bx,z MOV AH,4CH INT 21Hcal proc push bp mov bp,sp push ax push bx mov ax,[bp+4] mov bx,[bp+6] imul bx add ax,[bp+4] adc dx,0 sub ax,[bp+6] sbb dx,0 mov [bp+8],ax pop bx pop ax pop bp ret 4cal endpCODES ENDS END START(2)寄存器傳遞參數(shù)。$39。the 8 bit is 139。$39。the 7 bit is 139。$39。the 6 bit is 139。$39。the 5 bit is 139。$39。the 4 bit is 139。$39。the 3 bit is 139。$39。the 2 bit is 139。$39。the 1 bit is 139。DATAS ENDSCODES SEGMENT ASSUME CS:CODES,DS:DATASSTART: MOV AX,DATAS MOV DS,AX mov bl,00010000b mov cx,8 mov si,0again: shl bl,1 jc next add si,3 loop againnext: add si,offset jmptable jmp sijmptable: jmp near ptr l1 jmp near ptr l2 jmp near ptr l3 jmp near ptr l4 jmp near ptr l5 jmp near ptr l6 jmp near ptr l7 jmp near ptr l8 l1: lea dx,str1 jmp outputl2: lea dx,str2 jmp outputl3: lea dx,str3 jmp outputl4: lea dx,str4 jmp outputl5: lea dx,str5 jmp outputl6: lea dx,str6 jmp outputl7: lea dx,str7 jmp outputl8: lea dx,str8 output: mov ah,9 int 21h MOV AH,4CH INT 21HCODES ENDSEND START(2)地址表。,0dh,0ah,39。 str8 db 39。,0dh,0ah,39。 str7 db 39。,0dh,0ah,39。 str6 db 39。,0dh,0ah,39。 str5 db 39。,0dh,0ah,39。 str4 db 39。,0dh,0ah,39。 str3 db 39。,0dh,0ah,39。 str2 db 39。,0dh,0ah,39。轉(zhuǎn)移表,bl 左到右18位DATAS SEGMENT str1 db 39。三. 實驗過程和程序?qū)嶒瀮?nèi)容一:BL中的只有一位為1。3. 實踐C224。2. 編寫一個子程序計算z=f(x,y)=x*y+xy(x,y,z有符號數(shù)內(nèi)存數(shù))。二. 實驗內(nèi)容BL中的只有一位為1。實驗三 匯編語言子程序設(shè)計(分支、子程序)一. 實驗目的掌握分支和子程序結(jié)構(gòu)和設(shè)計方法;熟悉在PC機上建立、匯編、連接、調(diào)試和運行8086/8088匯編語言程序的過程。)cr db 0ah,0dh,$data endscodes segment assume cs:codes,ds:datastart: mov ax,data mov ds,axinput: mov ah,10 lea dx,buffer int 21h lea dx,cr mov ah,9 int 21houtput: lea dx,buffer+2 mov ah,9 int 21h mov ah,4ch int 21hcodes endsend start四. 實驗結(jié)果(包括必要的截圖)實驗內(nèi)容一:設(shè)x=156,y=10,z=220,v=2000,則sum1=0006h,sum2=0004h在ax中看sum1,在dx中看sum2 實