. : : Assembly Language : : .  |  首页  |  我提出的问题  |  我参与的问题  |  我的收藏  |  消息中心   |  游客  登录  | 
刷新 | 提问 | 未解决 | 已解决 | 精华区 | 搜索 |
  《汇编语言》论坛 ->编译原理
  管理员: assembly   [回复本贴] [收藏本贴] [管理本贴] [关闭窗口]
主题 : :  x86 汇编小问题  [待解决] 回复[ 1次 ]   点击[ 533次 ]  
snbbqsb
[帖 主]   [ 发表时间:2012-12-16 04:29 ]   [引用]   [回复]   [ top ] 
荣誉值:0
信誉值:0
注册日期:2012-12-16 04:28
想做一个循环机,要把产生的数字和输出放到数组里。 每当输出为1101的时候停止运转,写完了但是一跑 程序就停止运转  可能是call randomrange出错   或者dword array 出界,大家能帮我看看吗,​

   还有,call random产生的数字在eax里面 但是这是个dword. 怎么把他放到byte的数组里面?​



.data

  Series dword 9999 DUP(0)

  output dword 9999 DUP(0)

  state dword 999 DUP(0)

 .code

 main PROC

    mov esi,0

    call Randomize

 state0:

       mov output[esi],0            ;record output

       call check

   .if(boolean==1)

     jmp printme

   .endif

   mov eax,2  ;call random

   call RandomRange

       mov series[esi],eax ;save random

   inc esi

   inc esi

   inc esi

   inc esi

  .if (eax==0)

       jmp State0

      .elseif (eax==1)

       jmp state1

      .endif
需要登录后才能回帖 -->> 请单击此处登录
    Copyright © 2006-2024   ASMEDU.NET  All Rights Reserved