POV-Ray : Newsgroups : povray.off-topic : I am convinced... Server Time
3 Sep 2024 23:28:18 EDT (-0400)
  I am convinced... (Message 41 to 43 of 43)  
<<< Previous 10 Messages Goto Initial 10 Messages
From: Darren New
Subject: Re: I am convinced...
Date: 1 Feb 2011 14:23:06
Message: <4d485d9a@news.povray.org>
Invisible wrote:
> Because in order to do this, the OS would have to keep track of not only 
> what resources are in use, but *who* is using them.

Yes, it does that. Especially with VM, as you say, since every time the OS 
switches to running a different process, it has to reassign what pages of 
physical memory go with which virtual addresses.

-- 
Darren New, San Diego CA, USA (PST)
  "How did he die?"   "He got shot in the hand."
     "That was fatal?"
          "He was holding a live grenade at the time."


Post a reply to this message

From: Invisible
Subject: Re: I am convinced...
Date: 2 Feb 2011 04:49:08
Message: <4d492894@news.povray.org>
On 31/01/2011 09:31 PM, Darren New wrote:
> Orchid XP v8 wrote:
>> Well, since the microcode is just a bunch of extremely wide bitmaps
>> that open and close various switches, it wouldn't surprise me if doing
>> so in the wrong combination could short-circuit something, or do
>> something similarly bad.
>
> That's a point. I don't think that's real common, tho. There's usually
> something where you're connecting an input to an output. You connect the
> memory bus to the register, not the power in to the power out. :-)

Connect two outputs together, with one trying to drive a line high, and 
the other trying to drive it low, and you could have some "interesting" 
problems.

>> So what you're saying is it lets you access a file like you access
>> memory? (And presumably avoids the data being swapped out to the swap
>> file when you actually want it to end up in some other file anyway...)
>
> Yes, precisely.

OK. So what's all this stuff about "the OS loads programs by memory 
mapping them"? (Hopefully this will explain why programs show up as 
generating a non-zero number of "page faults", even though no swapping 
is actually happening...)


Post a reply to this message

From: Darren New
Subject: Re: I am convinced...
Date: 2 Feb 2011 12:46:09
Message: <4d499861$1@news.povray.org>
Invisible wrote:
> Connect two outputs together,

I don't think two outputs would have a gate between them like that. However, 
at this point I'm really over my head. I've never *actually* written 
microcode for a real computer myself. :-)

> OK. So what's all this stuff about "the OS loads programs by memory 
> mapping them"? (Hopefully this will explain why programs show up as 
> generating a non-zero number of "page faults", even though no swapping 
> is actually happening...)

It's exactly the same thing. If you have a chunk of executable that's 
supposed to be in addresses 0x1000 to 0x3000, and that's at offset zero in 
the file, you memmap the file into the page tables. Basically, you use the 
executable file itself as the swap file for that region of memory.

That's why in UNIX you can delete a running executable file, but you can't 
write to it. Because you're actually running code right out of the file, and 
not a copy of the file.

-- 
Darren New, San Diego CA, USA (PST)
  "How did he die?"   "He got shot in the hand."
     "That was fatal?"
          "He was holding a live grenade at the time."


Post a reply to this message

<<< Previous 10 Messages Goto Initial 10 Messages

Copyright 2003-2023 Persistence of Vision Raytracer Pty. Ltd.