Path: utzoo!attcan!uunet!cs.utexas.edu!wuarchive!brutus.cs.uiuc.edu!psuvax1!rutgers!mcnc!uvaarpa!murdoch!davinci.acc.Virginia.EDU!tmb From: tmb@davinci.acc.Virginia.EDU (Thomas M. Breeden) Newsgroups: comp.sys.amiga Subject: Re: BENCHMARK Modula-2 Source Debugger purchase info Message-ID: <1990Jun11.123847.20949@murdoch.acc.Virginia.EDU> Date: 11 Jun 90 12:38:47 GMT References: <13751@venera.isi.edu> <1990Jun8.181538.18276@zorch.SF-Bay.ORG> <3074@crash.cts.com> Sender: news@murdoch.acc.Virginia.EDU Organization: University of Virginia Lines: 34 In article <3074@crash.cts.com> jcs@crash.cts.com (John Schultz) writes: >In article <1990Jun8.181538.18276@zorch.SF-Bay.ORG> xanthian@zorch.SF-Bay.ORG (Kent Paul Dolan) writes: >>My biggest worry with the product so far, though I haven't yet hit it >>as a problem, is the limit on single arrays and of total module data >>requirements of 64K (bytes?). On a nine and a half megabyte machine, >>an array size limit of 64K is a joke, and there is no immediately >>evident, straightforward way to get around it. >> > > Declare a pointer to an array of your type, then allocate memory with >AllocMem, and set the pointer to your memory. That's it. Arrays as big as you >need. Use as: mydata^[index] := xxx. > > > John This will not work. The disassembler window of the Benchmark Source Level Debugger shows code for ANY array reference to be generated with assumptions that the array is no bigger than 64K bytes since a word sized index register (or displacement for constant indices) is used in the generated code. (Maybe that should be 32K, since the M68000 uses signed indices). This is the same reason a module/procedure's data is limited. What you need to do is declare p:POINTER TO x, ALLOCATE(p, AsBigAsYouWant) and then do some "C style" processing: move p through the data, changing the pointer with address arithmetic (being careful to increment by SIZE(x)). Tom Breeden tmb@viginia.edu -->> Internet tmb@virginia -->> BITNET