| TIP: Click on subject to list as thread! | ANSI |
| echo: | |
|---|---|
| to: | |
| from: | |
| date: | |
| subject: | Some weird addressing... |
On Thursday, 31 December 1998,
HERBERT ROSENAU wrote to IVAN TODOROSKI about Some weird addressing...
IT>> Do you get a single descritor with a 1000000 byte limit, or a
IT>> bunch of small descriptors with 65536 limits?
HR> In a 32 bit process you will become 245 descriptors. Each
HR> describes a single page of 4 KB. Then you can acces all Bytes in a
HR> range of 245 * 4KB.
HR> Lets look at the dimenson:
HR> 1000000 / 4096 = 245 pages
HR> x[1003519] is functional altough it's is illegal from your view.
HR> The processor (and the operatingsystem) can bounds check only
HR> on boundary of a single page = 4096 Bytes.
HR> x[1003520] will crash with access violation. It will address the
HR> unallocated
HR> page 246.
From the little assembly protected mode programming I did, I would say
that assigning a separate new descriptor to every 4KB of memory would
be extremely inefficient and a terrible waste of address space, since
the descriptor tables in 80386 and later processors can hold only 8191
descriptors, which would limit the address space of every single
process to little less than 32 megs. (8191*4096)
I think that you might have mistaken the descriptors for page table
entries. Descriptors can describe memory chunks of any size up to 4GB
(well almost any size, because of granularity issues), while page
table entries can describe only fixed 4KB chunks of memory.
HR> You'll become a logical continuous block of memory. It my or my
HR> not physical continous. From view as application programmer it
HR> dosn't matter if all pages bounded physically or not. Because the
HR> processor works with virtual addressspace.
Yes, the page mapping is transparent from programmers (even assembly
programmers) point of view. But chunking up an allocated piece of
memory in multiple decriptors is NOT totally transparent. I think it
can BE MADE transparent in software (or the OS) by installing
appropriate handlers for exceptions 11,12,13 and 14, but it would be
messy and would require additional CPU processing. Not efficient in
any case, especially since you already have a good, transparent and
efficient hardware mechanism (arbitrary sized descriptors coupled with
page mapping) to alocate chunks of arbitrary size.
Any more info is appreciated!
- Ivan -
.!. Cannot understand Tagline: bort, etry, augh anyway?
--- Terminate 5.00/Pro [OS/2]
þ TerMail/QWK þ
* Origin: GET ALL YOUR FIDO HERE! telnet://bbs.docsplace.org (1:3603/140)SEEN-BY: 396/1 632/0 371 633/260 262 267 270 371 635/444 506 728 639/252 SEEN-BY: 670/218 @PATH: 3603/140 396/1 633/260 635/506 728 633/267 |
|
| SOURCE: echomail via fidonet.ozzmosis.com | |
Email questions or comments to sysop@ipingthereforeiam.com
All parts of this website painstakingly hand-crafted in the U.S.A.!
IPTIA BBS/MUD/Terminal/Game Server List, © 2025 IPTIA Consulting™.