Re: Some words of encouragement

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



> When you say 4GB pointers, you mean physical addresses? It sounds
> feasible, but I've never heard of anybody doing it.

Basically, yes.  It'd be a 4GB virtual address space, but could be
backed by a real 4GB RAM if there was appropriate hardware.  Otherwise
it could be backed by swap.

> This would give you fast pointer arithmetic at the expensive of much
> slower indirection, due to having to frequently reload ds or es; I'd
> imagine that there's more indirection than pointer arithmetic in the
> average C program.

Yeah, the trick to getting good performance would be compiler
optimizations on the access strategies, with a more hard limit of
really only having 2x64KB data windows in "view" at a time (without
counting CS and SS).  There wouldn't be many ways around that without
the compiler performing caching strategies which would be on a whole
new plane of insanity.  The real killer for large applications
wouldn't be the time for the kernel to adjust pointers, it'd be the
data moving if there isn't RAM available to back the used memory.

> Hmm... the compiler would be able to optimise constant indirections
> (a->b), but not non-constant indirections (a[i]). The first case would
> turn into a ds:[si+$n] indirection, but the latter case would have to do
> explicit pointer arithmetic on the physical address a and then reload ds.

Right, the optimization possible for a[i] type stuff would degrade
quickly after 64KB size is reached.  The same window could be reused
only if the next data is still within it, but if the compiler doesn't
know this ahead of time, there would be a penalty in checking if it's
still ok.  Some arithmetic could be done on the SI register but
external code would have to be invoked to correct an arithmetic
borrow/carry and fix the segment register/prepare data.

>> tl;dr:  I'd love me some nethack running on 8088.
>
> Get the overlaid real-mode version from here:
>
> http://www.nethack.org/v331/ports/download-msdos.html

[totally off topic]:

Well either way I'd have to build a RAM board to do nethack on this
hardware, I'm mostly trying to find a good reason to build a big RAM
board and have it useful for more than ramdisk or task switching DOS
instances.  On this machine there is well over 512KB of address space
unused, so any chunk of the expansion memory could be mapped to each
of the 4 segments by only having the hardware decode upper addresses
based on 64KB mapping windows.

x86-16 address -> ram board address
mapping 0x4**** -> 0x0013****
mapping 0x5**** -> 0x0014****
DS=0x4367 would give a window into a 64KB that crosses ram board
mapping boundaries

The mapping hardware would just be a 4 address bit, 8 data bit RAM,
for up to 24 bit hardware addressing.  It starts to sound like a
non-standard 286 without memory protection.

I have an unexplainable thing for imagining up huge projects like this...

Sorry if this is sending you CC messages, it shouldn't be, but I have
to manually rewrite the address each time I reply.  I might have
forgot.
--
To unsubscribe from this list: send the line "unsubscribe linux-8086" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [Kernel]     [Linux ia64]     [DCCP]     [Linux for ARM]     [Yosemite News]     [Linux SCSI]     [Linux Hams]

  Powered by Linux