The MASM Forum Archive 2004 to 2012

General Forums => The Campus => Topic started by: dsouza123 on October 06, 2005, 11:29:29 PM

Title: What is the syntax for reg == address of a variable
Post by: dsouza123 on October 06, 2005, 11:29:29 PM
What is the syntax for comparing a register (holding an address) with the address of a variable ?


.data
 stuff  dd  0,1,2,3
 after  dd  4,5,6,7

.code
 mov esi, offset after

 .repeat
    dec esi
 .until esi == address of stuff
Title: Re: What is the syntax for reg == address of a variable
Post by: QvasiModo on October 06, 2005, 11:39:26 PM

.data
  stuff  dd  0,1,2,3
  after  dd  4,5,6,7

.code
  mov esi, offset after

  .repeat
     dec esi
  .until esi == offset stuff


:U
Title: Re: What is the syntax for reg == address of a variable
Post by: dsouza123 on October 06, 2005, 11:46:46 PM
Thanks