Another protected-mode segment question.

Started by r_miele, January 07, 2005, 04:13:44 AM

Previous topic - Next topic

r_miele

Sorry for all the questions guys, I have no one else to ask.

I thought I had a good grasp of the concept of segments until I started protected-mode programming.  It seems that the more research I do on them the more confused I get. :lol

The flat memory model works similar to the tiny memory model in which the code, data, and stack reside in the same segment.  What if you want to create a program that needs to keep data in a seperate segment? 

In real-mode, is any data and code segment you make put in a different physical memory segment?

Thanks guys

tenkey

Physical memory has no segments. The segments are "windows" into physical memory. The descriptors tell the processor how big the window is, and where in physical memory it starts. That is why segments can overlap, creating more than one way to address the same physical memory location.
A programming language is low level when its programs require attention to the irrelevant.
Alan Perlis, Epigram #8