Path: utzoo!utgpu!jarvis.csri.toronto.edu!mailrus!ames!oliveb!apple!farrier From: farrier@Apple.COM (Cary Farrier) Newsgroups: comp.sys.apple Subject: Re: JMP/JML differences Message-ID: <1729@internal.Apple.COM> Date: 9 May 89 15:51:55 GMT References: <8905081131.aa03291@SMOKE.BRL.MIL> Organization: Apple Computer Inc, Cupertino, CA Lines: 28 In article <8905081131.aa03291@SMOKE.BRL.MIL> JWANKERL@UTCVM.BITNET ("Josef W. Wankerl") writes: > >I've just been wondering what the advantages vs. disadvantages of >using a JML instead of a JMP would be. I guess an advantage of the JML >would be that it wouldn't need space in a loader relocation dictionary. >Is there any other difference?? Actually, any label reference (which isn't thrown out by optimizing), except brances (they contain an offset in the operand), will find its way into a relocation table. The difference between a JMP and a JML is that a JMP instruction can only jump to an address within the current code bank, while a JML can jump to any address in any bank. The reason is because the JMP only uses a 16 bit address, and the JML uses a 24 bit address. The JMP will affect only the program counter (PC), and not the code bank register (K), while the JML will affect both. Most decent assemblers will convert any JMP instructions to JML if long addressing is required, so your code may vary. Cary Farrier -- +--------------+-------------------+ | Cary Farrier | farrier@apple.com | Ok, how's this for net traffic? +--------------+-------------------+