Forums before death by AOL, social media and spammers... "We can't have nice things"
|    comp.lang.asm.x86    |    Ahh, the lost art of x86 assembly    |    4,675 messages    |
[   << oldest   |   < older   |   list   |   newer >   |   newest >>   ]
|    Message 4,505 of 4,675    |
|    Alexei A. Frounze to Paul Edwards    |
|    Re: seg keyword    |
|    19 Nov 22 14:05:14    |
      From: alexfrunews@nospicedham.gmail.com              On Saturday, November 19, 2022 at 11:23:06 AM UTC-8, Paul Edwards wrote:       > I have code like this:       ...       > mov bx, offset handler0       > mov es:[0h], bx       > mov bx, seg handler0       > mov es:[02h], bx       ...       > as86 uses 16-bit a.out format, and I'm not sure it can       > handle a reference to just "seg". ie half of an address       > being fixed up (I think that's what it does).       >       > Is there a better way of writing this code, more in line       > with the simple a.out format?       >       > Is it:       >       > addr0 dd handler0       >       > And then do an les of that?              I don't recall the a.out format supporting segmentation.              I found my way around the similar problem with the ELF       format by simply using 32-bit physical addresses,       which are then decomposed into 16-bit segment and       16-bit offset pairs whenever necessary.              Alex              --- SoupGate-Win32 v1.05        * Origin: you cannot sedate... all the things you hate (1:229/2)    |
[   << oldest   |   < older   |   list   |   newer >   |   newest >>   ]
(c) 1994, bbs@darkrealms.ca