Forums before death by AOL, social media and spammers... "We can't have nice things"
|    alt.os.development    |    Operating system development chatter    |    4,255 messages    |
[   << oldest   |   < older   |   list   |   newer >   |   newest >>   ]
|    Message 3,467 of 4,255    |
|    mutazilah@gmail.com to muta...@gmail.com    |
|    Re: segmentation    |
|    20 Nov 22 04:07:27    |
      From: muta...@gmail.com              On Wednesday, October 12, 2022 at 9:01:03 PM UTC+8, muta...@gmail.com wrote:              > > Concerning huge mode: having function call for array indexing       > > is performance killer, people who care about performance       > > issues would not accept this.              > Huge memory model is a performance killer already. That's       > why it is rarely used. If someone wants to request a       > binary with a hardcoded segment manipulation (out of the       > many possible) of a shift of 4 bits rather than making       > it flexible, and rather than simply upgrading to a faster       > processor for their alleged speed requirements - so be it,       > hardcode the 4.              By the way, today I got huge memory model working in       PDPCLIB. This was my first experience with actually       using huge.              Watcom generates function calls already.              And I wrote routines that hardcode a shift of 4.              But what I realized while doing that is that I simply needed       to check a global variable. If it is non-zero, I branch to       whatever routine that is and it doesn't matter where it comes       from (e.g. the OS).              Otherwise, the hardcoded 4-bit segment shift version of the       code is executed.              Performance overhead on an 8086 is near-zero.              And people with modern CPUs don't care about such       trivialities.              The code I wrote can be found here:              https://sourceforge.net/p/pdos/gitcode/ci/master/tree/pdpclib/dossupa.asm#l552              It's designed to be called with register parameters and       ideally written with a little bit of assembler.              I converted it into a C call because I have enough trouble       even getting it to work in C (take a look at the history!).              BFN. Paul.              --- 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