Path: utzoo!utgpu!news-server.csri.toronto.edu!rpi!think.com!zaphod.mps.ohio-state.edu!unix.cis.pitt.edu!pitt!willett!ForthNet From: ForthNet@willett.pgh.pa.us (ForthNet articles from GEnie) Newsgroups: comp.lang.forth Subject: ANS TC Magnet for Tick, >BODY, ['],etc Message-ID: <2922.UUL1.3#5129@willett.pgh.pa.us> Date: 25 Jun 91 02:31:11 GMT Organization: (n.) to be organized. But that's not important right now. Lines: 46 Category 10, Topic 25 Message 29 Mon Jun 24, 1991 D.RUFFER [Dennis] at 00:23 EDT Again, I think you all are missing the point. Since I won't be passing this stuff back to Elizabeth for a week, I will try to explain it again. C, can most certainly cause HERE to return an unaligned address and no, it does not need to be "fixed" and results will be unpredictable if used by an operator that is expecting an aligned address. BASIS does not require HERE to return an aligned address, but since the programmer is in control of the situation (and actually caused the misalignment), it is his responsiblity to use ALIGN before he assumes HERE can be used with an operator that requires alignment. In other words, if you do a C, and then want to do a HERE @, then you had better do an ALIGN first. Why is this such a mystery? Re: rob@innovus.uucp (Rob Sciuk) >=> appropriate boundaries. Further, `ALLOT' and `,' should align >=> on CELL boundaries, and `C,' should ensure that the next >=> invocation of `HERE', `ALLOT', `,' etc. will utilize a CELL >=> boundary appropriate to the processor [mine]. This is _NOT_ what Elizabeth said. ALLOT and C, do not do anything about alignment, nor do they assure that the next invocation of HERE will return an aligned address. It is up to the programmer to make these assurances, since he is the one that used the C, or an odd number of bytes in ALLOT. In fact, Elizabeth specifically did say that HERE can return an unaligned address if the programmer does these things. At FORTH, Inc. we work on aligned systems all the time and it is really not a problem. Sure, a nieve programmer can get himself in trouble, by using HERE improperly, but in practice, this doesn't happen much. All the defining words that are garanteed to return aligned addresses, do the alignment before they make use of HERE. Yes, this does mean that ALIGN gets executed frequently as you compile your system, but IMHO, it should be written for speed and frequent use anyways. {B-{)> DaR ----- This message came from GEnie via willett. You *cannot* reply to the author using e-mail. Please post a follow-up article, or use any instructions the author may have included (USMail addresses, telephone #, etc.). Report problems to: dwp@willett.pgh.pa.us _or_ uunet!willett!dwp