<s>
A	O
modern	O
computer	B-General_Concept
operating	I-General_Concept
system	I-General_Concept
usually	O
segregates	O
virtual	B-Architecture
memory	I-Architecture
into	O
user	B-Operating_System
space	I-Operating_System
and	I-Operating_System
kernel	I-Operating_System
space	I-Operating_System
.	O
</s>
<s>
Primarily	O
,	O
this	O
separation	O
serves	O
to	O
provide	O
memory	B-General_Concept
protection	I-General_Concept
and	O
hardware	O
protection	O
from	O
malicious	O
or	O
errant	O
software	O
behaviour	O
.	O
</s>
<s>
Kernel	B-Operating_System
space	I-Operating_System
is	O
strictly	O
reserved	O
for	O
running	O
a	O
privileged	O
operating	B-Operating_System
system	I-Operating_System
kernel	I-Operating_System
,	O
kernel	B-Operating_System
extensions	O
,	O
and	O
most	O
device	B-Application
drivers	I-Application
.	O
</s>
<s>
In	O
contrast	O
,	O
user	B-Operating_System
space	I-Operating_System
is	O
the	O
memory	O
area	O
where	O
application	B-Application
software	I-Application
and	O
some	O
drivers	O
execute	O
.	O
</s>
<s>
The	O
term	O
user	B-Operating_System
space	I-Operating_System
(	O
or	O
userland	O
)	O
refers	O
to	O
all	O
code	O
that	O
runs	O
outside	O
the	O
operating	B-General_Concept
system	I-General_Concept
's	O
kernel	B-Operating_System
.	O
</s>
<s>
User	B-Operating_System
space	I-Operating_System
usually	O
refers	O
to	O
the	O
various	O
programs	O
and	O
libraries	B-Library
that	O
the	O
operating	B-General_Concept
system	I-General_Concept
uses	O
to	O
interact	O
with	O
the	O
kernel	B-Operating_System
:	O
software	O
that	O
performs	O
input/output	B-General_Concept
,	O
manipulates	O
file	B-Application
system	I-Application
objects	O
,	O
application	B-Application
software	I-Application
,	O
etc	O
.	O
</s>
<s>
Each	O
user	B-Operating_System
space	I-Operating_System
process	B-Operating_System
normally	O
runs	O
in	O
its	O
own	O
virtual	B-Architecture
memory	I-Architecture
space	O
,	O
and	O
,	O
unless	O
explicitly	O
allowed	O
,	O
cannot	O
access	O
the	O
memory	O
of	O
other	O
processes	O
.	O
</s>
<s>
This	O
is	O
the	O
basis	O
for	O
memory	B-General_Concept
protection	I-General_Concept
in	O
today	O
's	O
mainstream	O
operating	B-General_Concept
systems	I-General_Concept
,	O
and	O
a	O
building	O
block	O
for	O
privilege	O
separation	O
.	O
</s>
<s>
A	O
separate	O
user	B-Operating_System
mode	I-Operating_System
can	O
also	O
be	O
used	O
to	O
build	O
efficient	O
virtual	O
machines	O
–	O
see	O
Popek	B-Architecture
and	I-Architecture
Goldberg	I-Architecture
virtualization	I-Architecture
requirements	I-Architecture
.	O
</s>
<s>
With	O
enough	O
privileges	O
,	O
processes	O
can	O
request	O
the	O
kernel	B-Operating_System
to	O
map	O
part	O
of	O
another	O
process	B-Operating_System
's	O
memory	O
space	O
to	O
its	O
own	O
,	O
as	O
is	O
the	O
case	O
for	O
debuggers	B-Application
.	O
</s>
<s>
Programs	O
can	O
also	O
request	O
shared	B-Operating_System
memory	I-Operating_System
regions	O
with	O
other	O
processes	O
,	O
although	O
other	O
techniques	O
are	O
also	O
available	O
to	O
allow	O
inter-process	B-Operating_System
communication	I-Operating_System
.	O
</s>
<s>
The	O
most	O
common	O
way	O
of	O
implementing	O
a	O
user	B-Operating_System
mode	I-Operating_System
separate	O
from	O
kernel	B-Operating_System
mode	O
involves	O
operating	B-General_Concept
system	I-General_Concept
protection	B-Operating_System
rings	I-Operating_System
.	O
</s>
<s>
Protection	B-Operating_System
rings	I-Operating_System
,	O
in	O
turn	O
,	O
are	O
implemented	O
using	O
CPU	B-General_Concept
modes	I-General_Concept
.	O
</s>
<s>
Typically	O
,	O
kernel	B-Operating_System
space	I-Operating_System
programs	O
run	O
in	O
kernel	B-Operating_System
mode	O
,	O
also	O
called	O
supervisor	O
mode	O
;	O
</s>
<s>
normal	O
applications	O
in	O
user	B-Operating_System
space	I-Operating_System
run	O
in	O
user	B-Operating_System
mode	I-Operating_System
.	O
</s>
<s>
Many	O
operating	B-General_Concept
systems	I-General_Concept
are	O
single	B-Operating_System
address	I-Operating_System
space	I-Operating_System
operating	I-Operating_System
systems	I-Operating_System
—	O
they	O
have	O
a	O
single	O
address	B-General_Concept
space	I-General_Concept
for	O
all	O
user-mode	B-Operating_System
code	O
.	O
</s>
<s>
(	O
The	O
kernel-mode	B-Operating_System
code	O
may	O
be	O
in	O
the	O
same	O
address	B-General_Concept
space	I-General_Concept
,	O
or	O
it	O
may	O
be	O
in	O
a	O
second	O
address	B-General_Concept
space	I-General_Concept
)	O
.	O
</s>
<s>
Many	O
other	O
operating	B-General_Concept
systems	I-General_Concept
have	O
a	O
per-process	O
address	B-General_Concept
space	I-General_Concept
,	O
a	O
separate	O
address	B-General_Concept
space	I-General_Concept
for	O
each	O
and	O
every	O
user-mode	B-Operating_System
process	B-Operating_System
.	O
</s>
<s>
Another	O
approach	O
taken	O
in	O
experimental	O
operating	B-General_Concept
systems	I-General_Concept
is	O
to	O
have	O
a	O
single	O
address	B-General_Concept
space	I-General_Concept
for	O
all	O
software	O
,	O
and	O
rely	O
on	O
a	O
programming	O
language	O
's	O
semantics	O
to	O
make	O
sure	O
that	O
arbitrary	O
memory	O
cannot	O
be	O
accessed	O
–	O
applications	O
simply	O
cannot	O
acquire	O
any	O
references	O
to	O
the	O
objects	O
that	O
they	O
are	O
not	O
allowed	O
to	O
access	O
.	O
</s>
<s>
This	O
approach	O
has	O
been	O
implemented	O
in	O
JXOS	B-Language
,	O
Unununium	O
as	O
well	O
as	O
Microsoft	O
's	O
Singularity	B-Operating_System
research	O
project	O
.	O
</s>
