> -----Original Message-----
> From: IBM Mainframe Discussion List On Behalf Of John McKown
> 
> On Tue, Feb 18, 2014 at 9:54 AM, Ron Thomas <[email protected]> wrote:
> 
> > Hello,
> >
> > Here is the definition in one our programs
> >
> > ITMLNG   DS    XL2                 BIT MAP LENGTH.
> > ITMAP    DS    XL1250              STORE BIT MAP.
> >
> > Here 1250 , storage allocation means data for 8 stores  ie 1250 * 8,
> > i.e each bit has the information whether the store is closed or opened.
> >
> > Now if we modify to 12500, can ITMLNG , which is the length of the bit
> > data can hold the length ?
> >
> > Thanks,
> > Ron T
> >
> >
> It worries me that you need to ask. But based on the comments on the 
> definitions as well as your
> words, it appears that ITMAP is a bit map of stores (business locations). In 
> an XL2 count field, you
> can have a signed value of -32_767 to 32_767 or an unsigned value of 0 to 
> 65_535.  XL1250 can contain
> 1250*8 or 10_000 bits. An XL12500 would be 10 times as much or
> 100_000 bits. That is too big a value to store in a halfword (XL2 is a 
> halfword), even unsigned. The
> largest size, if ITMLNG is unsigned would be
> XL8191 or 65_528 stores, if ITMLNG is signed, that is cut in half (more of
> less) to XL4095, or 32_760 stores.
> 
> I would say the answer to the original question is "No".

Both the code comment and the OP explicitly declared ITMLEN to contain a data 
length, not a bit count.  Data lengths are usually expressed as a number of 
bytes, not bits.  

Therefore, I submit that John Gilmore got it right the first time.

    -jc-

**********************************************************************
Information contained in this e-mail message and in any attachments thereto is 
confidential. If you are not the intended recipient, please destroy this 
message, delete any copies held on your systems, notify the sender immediately, 
and refrain from using or disclosing all or any part of its content to any 
other person.


----------------------------------------------------------------------
For IBM-MAIN subscribe / signoff / archive access instructions,
send email to [email protected] with the message: INFO IBM-MAIN

Reply via email to