Relay-Version: version B 2.10 5/3/83; site utzoo.UUCP Path: utzoo!utgpu!water!watmath!clyde!rutgers!ames!think!husc6!wjh12!lotto From: lotto@wjh12.UUCP Newsgroups: comp.sys.ibm.pc Subject: Please explain this MASM/LINK behavior... Message-ID: <88@wjh12.HARVARD.EDU> Date: Mon, 31-Aug-87 09:41:55 EDT Article-I.D.: wjh12.88 Posted: Mon Aug 31 09:41:55 1987 Date-Received: Tue, 1-Sep-87 04:39:36 EDT Reply-To: lotto@wjh12.UUCP (Jerry Lotto) Organization: Harvard Univ. Chem. Dept. Lines: 35 Keywords: MASM LINK bug? I was writing a tiny utility the other day and I ran into this behavior. The following example is not supposed to DO anything but illustrate the problem... Code_Seg Segment Para 'CODE' Assume CS:Code_Seg Org 100H Begin: mov ax, Code_Seg:[2ch] Code_Seg Ends End Begin assembles fine, but generates a link error (invalid object module). On further investigation, MASM appears to be generating a FIXUP record with a target THREAD field that uses a METHOD 4. Now the Microsoft version of the Intel object module docs clearly :-) states that for target threads, method equals from 0 to 7 MOD 4 which leaves 4 out in the cold. If you rewrite the Begin line to read: Begin: mov ax, [2ch] everything works OK. I repeat that MASM generates NO warnings or errors of any kind. In light of the recent posting by Microsoft documenting the linker behavior in such fine detail, perhaps someone from the assembler division would be kind enough to take a stab at this one? -- Gerald Lotto - Harvard Chemistry Dept. UUCP: {seismo,harpo,ihnp4,linus,allegra,ut-sally}!harvard!lotto ARPA: lotto@harvard.harvard.edu