<s>
The	O
GEC	B-Device
4000	I-Device
was	O
a	O
series	O
of	O
16/32	O
-bit	O
minicomputers	B-Architecture
produced	O
by	O
GEC	B-Device
Computers	I-Device
Ltd	I-Device
in	O
the	O
United	O
Kingdom	O
during	O
the	O
1970s	O
,	O
1980s	O
and	O
early	O
1990s	O
.	O
</s>
<s>
GEC	B-Device
Computers	I-Device
was	O
formed	O
in	O
1968	O
as	O
a	O
business	O
unit	O
of	O
the	O
GEC	O
conglomerate	O
.	O
</s>
<s>
Alpha	O
appeared	O
first	O
and	O
became	O
the	O
GEC	B-Device
2050	I-Device
8-bit	O
minicomputer	B-Architecture
.	O
</s>
<s>
The	O
4000	O
series	O
systems	O
were	O
developed	O
and	O
manufactured	O
in	O
the	O
UK	O
at	O
GEC	B-Device
Computers	I-Device
 '	O
Borehamwood	O
offices	O
in	O
Elstree	O
Way	O
.	O
</s>
<s>
In	O
1979	O
,	O
GEC	B-Device
Computers	I-Device
was	O
awarded	O
the	O
Queen	O
's	O
Award	O
for	O
Technical	O
Achievement	O
for	O
the	O
development	O
of	O
the	O
4000	O
series	O
,	O
particularly	O
Nucleus	B-Operating_System
.	O
</s>
<s>
The	O
GEC	B-Device
4000	I-Device
series	I-Device
hardware	B-Architecture
and	O
firmware	B-Application
included	O
a	O
pioneering	O
facility	O
known	O
as	O
Nucleus	B-Operating_System
.	O
</s>
<s>
Nucleus	B-Operating_System
implements	O
a	O
number	O
of	O
features	O
which	O
are	O
more	O
usually	O
implemented	O
within	O
an	O
operating	B-Operating_System
system	I-Operating_System
kernel	I-Operating_System
,	O
and	O
consequently	O
operating	B-General_Concept
systems	I-General_Concept
running	O
on	O
GEC	B-Device
4000	I-Device
series	I-Device
systems	O
do	O
not	O
need	O
to	O
directly	O
provide	O
these	O
features	O
themselves	O
.	O
</s>
<s>
Nucleus	B-Operating_System
firmware	B-Application
cannot	O
be	O
reprogrammed	O
by	O
any	O
code	O
running	O
on	O
the	O
system	O
,	O
and	O
this	O
made	O
the	O
systems	O
particularly	O
attractive	O
to	O
a	O
number	O
of	O
security	O
applications	O
.	O
</s>
<s>
Nucleus	B-Operating_System
performs	O
:	O
</s>
<s>
There	O
is	O
no	O
provision	O
for	O
running	O
any	O
supervisor/privileged/kernel	O
mode	O
code	O
on	O
the	O
4000	O
systems	O
—	O
all	O
operating	B-General_Concept
system	I-General_Concept
code	O
runs	O
as	O
processes	O
.	O
</s>
<s>
Hence	O
,	O
device	B-Application
drivers	I-Application
,	O
file	B-Application
system	I-Application
code	O
,	O
and	O
other	O
features	O
which	O
are	O
often	O
found	O
within	O
operating	B-Operating_System
system	I-Operating_System
kernels	I-Operating_System
must	O
be	O
run	O
in	O
processes	O
on	O
the	O
4000	O
systems	O
.	O
</s>
<s>
Nucleus	B-Operating_System
is	O
configured	O
by	O
a	O
set	O
of	O
system	O
tables	O
,	O
and	O
processes	O
which	O
have	O
a	O
need	O
to	O
modify	O
the	O
operation	O
of	O
nucleus	B-Operating_System
are	O
given	O
access	O
to	O
the	O
relevant	O
system	O
tables	O
.	O
</s>
<s>
This	O
would	O
be	O
the	O
case	O
for	O
processes	O
which	O
directly	O
change	O
the	O
state	O
of	O
other	O
processes	O
,	O
processes	O
which	O
allocate	O
and	O
delete	O
memory	O
segments	O
,	O
processes	O
which	O
can	O
change	O
the	O
routing	O
of	O
messages	O
between	O
other	O
processes	O
or	O
change	O
the	O
mapping	O
of	O
I/O	B-General_Concept
devices	I-General_Concept
to	O
processes	O
,	O
etc	O
.	O
</s>
<s>
will	O
pass	O
a	O
message	O
to	O
the	O
relevant	O
trusted	O
process	B-Operating_System
which	O
it	O
will	O
vet	O
before	O
performing	O
the	O
action	O
and	O
replying	O
.	O
</s>
<s>
The	O
4000	O
series	O
has	O
a	O
CISC	B-Architecture
instruction	B-General_Concept
set	I-General_Concept
.	O
</s>
<s>
It	O
has	O
8-bit	O
bytes	B-Application
,	O
big-endian	O
,	O
byte-addressable	O
memory	O
,	O
two	B-General_Concept
's	I-General_Concept
complement	I-General_Concept
arithmetic	I-General_Concept
,	O
and	O
base-16	B-Device
excess-64	I-Device
floating	I-Device
point	I-Device
format	I-Device
(	O
same	O
as	O
IBM	B-Application
System/360	I-Application
)	O
.	O
</s>
<s>
The	O
model	O
numbers	O
below	O
4090	O
are	O
16-bit	B-Device
processors	I-Device
,	O
and	O
model	O
numbers	O
from	O
4090	O
upwards	O
are	O
mixed	O
16-bit	B-Device
and	O
32-bit	O
.	O
</s>
<s>
All	O
systems	O
support	O
16-bit	B-Device
pointers	O
,	O
which	O
is	O
known	O
as	O
CST	O
(	O
Current	O
Segment	O
Table	O
)	O
addressing	O
.	O
</s>
<s>
Each	O
process	B-Operating_System
has	O
a	O
PAST	O
(	O
Program	O
Accessible	O
Segment	O
Table	O
)	O
which	O
lists	O
which	O
of	O
the	O
system	O
's	O
memory	O
segments	O
the	O
program	O
is	O
permitted	O
to	O
access	O
.	O
</s>
<s>
CST	O
addressing	O
allows	O
four	O
of	O
the	O
PAST	O
entries	O
to	O
be	O
mapped	O
at	O
addresses	O
0	O
,	O
16KiB	O
,	O
32KiB	O
,	O
and	O
48KiB	O
,	O
giving	O
the	O
16-bit/64KiB	O
address	O
space	O
.	O
</s>
<s>
Programs	O
which	O
use	O
more	O
than	O
64KiB	O
of	O
memory	O
must	O
explicitly	O
map	O
the	O
PAST	O
entries	O
they	O
require	O
at	O
any	O
moment	O
into	O
their	O
4	O
CST	O
entries	O
,	O
although	O
Nucleus	B-Operating_System
will	O
automatically	O
map	O
different	O
code	O
segments	O
into	O
the	O
CSTs	O
.	O
</s>
<s>
PAS	O
addressing	O
allows	O
programs	O
to	O
view	O
their	O
address	O
space	O
as	O
a	O
flat	O
32-bit	O
address	O
space	O
,	O
with	O
successive	O
PAST	O
entries	O
appearing	O
every	O
16KiB	O
,	O
and	O
Nucleus	B-Operating_System
performing	O
the	O
PAST	O
entry	O
segment	O
mapping	O
automatically	O
.	O
</s>
<s>
The	O
32-bit	O
systems	O
support	O
mixing	O
of	O
CST	O
and	O
PAS	O
addressing	O
in	O
the	O
same	O
process	B-Operating_System
.	O
</s>
<s>
All	O
instructions	O
are	O
16	B-Device
bits	I-Device
wide	O
,	O
except	O
for	O
some	O
PAS	O
addressing	O
instructions	O
which	O
are	O
32	O
bits	O
.	O
</s>
<s>
A	O
16-bit	B-Device
X	O
register	O
is	O
used	O
mainly	O
for	O
array	O
indexing	O
,	O
and	O
two	O
16-bit	B-Device
Y	O
and	O
Z	O
registers	O
are	O
used	O
as	O
16-bit	B-Device
pointers	O
.	O
</s>
<s>
A	O
16-bit	B-Device
L	O
register	O
points	O
to	O
function	O
local	O
data	O
,	O
and	O
a	O
G	O
register	O
always	O
contains	O
zero	O
which	O
can	O
be	O
used	O
as	O
a	O
16-bit	B-Device
global	O
pointer	O
,	O
and	O
also	O
an	O
8-bit	O
,	O
16-bit	B-Device
,	O
or	O
32-bit	O
zero	O
value	O
.	O
</s>
<s>
The	O
16-bit	B-Device
S	O
(	O
sequence	O
)	O
register	O
points	O
to	O
the	O
next	O
instruction	O
to	O
be	O
obeyed	O
.	O
</s>
<s>
(	O
Some	O
of	O
this	O
is	O
illustrated	O
in	O
the	O
much	O
simpler	O
instruction	B-General_Concept
set	I-General_Concept
of	O
the	O
GEC	B-Device
2050	I-Device
.	O
)	O
</s>
<s>
No	O
32-bit	O
PAS	O
pointer	O
register	O
exists	O
—	O
32-bit	O
PAS	O
pointers	O
reside	O
in	O
memory	O
in	O
the	O
16-bit	B-Device
CST	O
address	O
space	O
,	O
and	O
are	O
accessed	O
by	O
using	O
a	O
16-bit	B-Device
pointer	O
.	O
</s>
<s>
There	O
is	O
no	O
instruction	B-General_Concept
set	I-General_Concept
support	O
for	O
a	O
stack	B-Application
.	O
</s>
<s>
There	O
are	O
a	O
number	O
of	O
registers	O
inaccessible	O
to	O
programs	O
which	O
are	O
used	O
by	O
Nucleus	B-Operating_System
,	O
such	O
as	O
the	O
hardware	B-Architecture
segment	O
registers	O
which	O
point	O
to	O
the	O
running	O
process	B-Operating_System
's	O
four	O
CSTs	O
,	O
master	O
segment	O
and	O
PAS	O
segments	O
,	O
and	O
the	O
system	O
tables	O
.	O
</s>
<s>
The	O
instruction	B-General_Concept
set	I-General_Concept
contains	O
instructions	O
which	O
operate	O
register-register	O
,	O
store-register	O
,	O
register-store	O
,	O
and	O
store-store	O
.	O
</s>
<s>
There	O
are	O
a	O
number	O
of	O
Nucleus	B-Operating_System
instructions	O
for	O
tasks	O
such	O
as	O
sending	O
a	O
message	O
to	O
another	O
process	B-Operating_System
or	O
a	O
peripheral	O
device	O
,	O
receiving	O
a	O
message	O
or	O
interrupt	B-Application
,	O
changing	O
a	O
CST	O
entry	O
to	O
point	O
to	O
a	O
different	O
segment	O
which	O
is	O
accessible	O
to	O
the	O
process	B-Operating_System
,	O
etc	O
.	O
</s>
<s>
The	O
4080	O
has	O
a	O
two-stage	O
instruction	B-General_Concept
pipeline	I-General_Concept
.	O
</s>
<s>
The	O
normal	O
operating	O
mode	O
of	O
the	O
CPU	O
is	O
called	O
Full	O
Nucleus	B-Operating_System
.	O
</s>
<s>
In	O
Basic	O
Test	O
mode	O
,	O
Nucleus	B-Operating_System
is	O
disabled	O
,	O
I/O	B-General_Concept
is	O
performed	O
differently	O
,	O
and	O
only	O
a	O
single	O
program	O
can	O
run	O
,	O
restricted	O
to	O
the	O
bottom	O
64KiB	O
of	O
store	O
,	O
but	O
all	O
other	O
non-nucleus	O
and	O
non-PAS	O
instructions	O
operate	O
normally	O
.	O
</s>
<s>
This	O
mode	O
is	O
used	O
very	O
early	O
during	O
booting	O
to	O
set	O
up	O
the	O
system	O
tables	O
required	O
by	O
Nucleus	B-Operating_System
,	O
before	O
obeying	O
a	O
Switch	O
Full	O
Nucleus	B-Operating_System
instruction	O
.	O
</s>
<s>
Once	O
the	O
system	O
has	O
switched	O
to	O
Full	O
Nucleus	B-Operating_System
,	O
it	O
cannot	O
return	O
to	O
Basic	O
Test	O
mode	O
without	O
operator	O
intervention	O
at	O
the	O
front	O
panel	O
,	O
in	O
effect	O
killing	O
any	O
operating	B-General_Concept
system	I-General_Concept
which	O
was	O
running	O
.	O
</s>
<s>
The	O
4000	O
I/O	B-General_Concept
design	O
is	O
based	O
around	O
a	O
number	O
of	O
Input/Output	B-Device
Processors	I-Device
known	O
as	O
IOPs	O
,	O
each	O
of	O
which	O
interfaces	O
between	O
the	O
store	O
and	O
a	O
set	O
of	O
I/O	B-General_Concept
controllers	O
.	O
</s>
<s>
The	O
IOPs	O
are	O
controlled	O
by	O
the	O
Nucleus	B-Operating_System
function	O
in	O
the	O
CPU	O
,	O
but	O
once	O
an	O
I/O	B-General_Concept
event	O
is	O
triggered	O
,	O
they	O
operate	O
autonomously	O
without	O
interaction	O
with	O
the	O
CPU	O
until	O
the	O
I/O	B-General_Concept
completes	O
.	O
</s>
<s>
The	O
Normal	O
Interface	O
IOPs	O
can	O
each	O
support	O
up	O
to	O
255	O
or	O
256	O
simultaneous	O
I/O	B-General_Concept
operations	I-General_Concept
,	O
each	O
on	O
a	O
separate	O
Way	O
.	O
</s>
<s>
The	O
I/O	B-General_Concept
controllers	O
on	O
each	O
IOP	O
would	O
each	O
occupy	O
one	O
or	O
more	O
Ways	O
,	O
depending	O
on	O
how	O
many	O
simultaneous	O
I/O	B-General_Concept
operations	I-General_Concept
they	O
need	O
to	O
handle	O
.	O
</s>
<s>
The	O
IOP	O
polices	O
each	O
Way	O
's	O
access	O
to	O
main	O
store	O
,	O
allowing	O
only	O
access	O
to	O
successive	O
memory	B-General_Concept
locations	I-General_Concept
defined	O
for	O
the	O
I/O	B-General_Concept
operation	I-General_Concept
that	O
Way	O
is	O
currently	O
performing	O
.	O
</s>
<s>
The	O
earlier	O
IOPs	O
performed	O
8-bit	O
and	O
16-bit	B-Device
wide	O
store	O
accesses	O
,	O
with	O
a	O
burst	O
mode	O
for	O
doing	O
up	O
to	O
8	O
transfers	O
together	O
for	O
higher	O
throughput	O
I/O	B-General_Concept
controllers	O
.	O
</s>
<s>
The	O
entry	O
level	O
415x	O
and	O
4x6x	O
systems	O
have	O
their	O
first	O
IOP	O
(	O
Integral	O
Multiplexer	O
Channel	O
,	O
or	O
IMC	O
)	O
integrated	O
into	O
the	O
Nucleus	B-Operating_System
firmware	B-Application
,	O
and	O
thus	O
I/O	B-General_Concept
operations	I-General_Concept
on	O
the	O
IMC	O
did	O
have	O
some	O
impact	O
on	O
CPU	O
performance	O
,	O
although	O
the	O
4x6x	O
systems	O
could	O
have	O
external	O
IOPs	O
added	O
.	O
</s>
<s>
The	O
4000	O
series	O
Nucleus	B-Operating_System
I/O	B-General_Concept
instructions	O
and	O
system	O
tables	O
allow	O
for	O
up	O
to	O
8	O
IOPs	O
,	O
although	O
most	O
of	O
the	O
models	O
in	O
the	O
4000	O
series	O
range	O
had	O
some	O
type	O
of	O
hardware	B-Architecture
limitation	O
which	O
reduced	O
this	O
.	O
</s>
<s>
Some	O
commonly	O
used	O
I/O	B-General_Concept
Controllers	O
are	O
the	O
interval	B-Device
timer	I-Device
,	O
system	B-Device
console	I-Device
controller	O
,	O
punched	O
tape	O
reader	O
and	O
punch	O
controllers	O
,	O
line	O
printer	O
controller	O
(	O
all	O
these	O
use	O
a	O
single	O
Way	O
)	O
,	O
a	O
number	O
of	O
SMD	B-Architecture
(	O
and	O
earlier	O
disk	B-Device
bus	O
interface	O
)	O
disk	B-Device
controllers	O
for	O
controlling	O
up	O
to	O
four	O
drives	O
(	O
all	O
using	O
two	O
Ways	O
)	O
,	O
Pertec	O
PPC	O
magnetic	O
tape	O
controllers	O
for	O
up	O
to	O
four	O
"	O
tape	O
drives	O
,	O
and	O
a	O
number	O
of	O
multi-ported	O
synchronous	B-Application
and	O
asynchronous	B-Application
serial	B-Protocol
communication	I-Protocol
controllers	O
(	O
using	O
between	O
4	O
and	O
32	O
Ways	O
)	O
.	O
</s>
<s>
A	O
digital	O
I/O	B-General_Concept
board	O
(	O
using	O
four	O
Ways	O
)	O
was	O
commonly	O
used	O
for	O
direct	O
process	B-Operating_System
control	O
interfacing	O
,	O
and	O
for	O
providing	O
a	O
fast	O
parallel	O
link	O
between	O
systems	O
.	O
</s>
<s>
A	O
CAMAC	B-Architecture
crate	I-Architecture
controller	O
was	O
also	O
available	O
(	O
again	O
,	O
used	O
for	O
process	B-Operating_System
control	O
interfacing	O
)	O
.	O
</s>
<s>
The	O
Normal	O
Interface	O
bus	O
which	O
these	O
controllers	O
plug	O
into	O
is	O
a	O
published	O
interface	O
,	O
and	O
many	O
customers	O
also	O
built	O
their	O
own	O
controllers	O
for	O
their	O
own	O
specific	O
process	B-Operating_System
control	O
requirements	O
.	O
</s>
<s>
The	O
earlier	O
GEC	B-Device
2050	I-Device
minicomputer	B-Architecture
used	O
an	O
8-bit	O
version	O
of	O
the	O
Normal	O
Interface	O
,	O
and	O
most	O
I/O	B-General_Concept
Controllers	O
could	O
be	O
used	O
on	O
both	O
ranges	O
of	O
systems	O
.	O
</s>
<s>
All	O
the	O
IOPs	O
designed	O
and	O
built	O
through	O
the	O
1970s	O
provided	O
the	O
same	O
Normal	O
Interface	O
bus	O
for	O
I/O	B-General_Concept
Controllers	O
,	O
and	O
the	O
I/O	B-General_Concept
controllers	O
could	O
generally	O
be	O
used	O
in	O
any	O
of	O
them	O
.	O
</s>
<s>
A	O
Direct	O
Memory	O
Access	O
Director	O
(	O
DMAD	O
)	O
IOP	O
allowed	O
for	O
a	O
new	O
type	O
of	O
I/O	B-General_Concept
controller	O
which	O
had	O
more	O
freedom	O
to	O
access	O
main	O
memory	O
,	O
and	O
allowed	O
the	O
design	O
of	O
more	O
intelligent	O
communications	O
controllers	O
.	O
</s>
<s>
A	O
SCSI	B-Architecture
IOP	O
generated	O
a	O
SCSI	B-Architecture
bus	O
for	O
attaching	O
more	O
modern	O
disks	O
,	O
and	O
also	O
included	O
an	O
integrated	O
Interval	B-Device
Timer	I-Device
,	O
system	B-Device
console	I-Device
controller	O
,	O
and	O
Calendar	O
Clock	O
so	O
that	O
an	O
additional	O
Normal	O
Interface	O
IOP	O
and	O
separate	O
controllers	O
was	O
not	O
required	O
to	O
support	O
just	O
these	O
functions	O
.	O
</s>
<s>
Users	O
of	O
GEC	B-Device
4000	I-Device
series	I-Device
systems	O
included	O
many	O
British	O
university	O
physics	O
and	O
engineering	O
departments	O
,	O
the	O
central	O
computing	O
service	O
of	O
University	O
College	O
London	O
(	O
Euclid	O
)	O
and	O
Keele	O
University	O
,	O
the	O
JANET	O
academic/research	O
network	O
X.25	B-Protocol
switching	O
backbone	O
,	O
Rutherford-Appleton	O
Laboratory	O
,	O
Daresbury	O
Laboratory	O
,	O
Harwell	O
Laboratory	O
,	O
NERC	O
,	O
Met	O
Office	O
,	O
CERN	O
,	O
ICI	O
,	O
British	O
Telecom	O
,	O
SIP	O
(	O
Italian	O
telco	O
)	O
,	O
and	O
Plessey	O
.	O
</s>
<s>
British	O
Steel	O
Corporation	O
and	O
BHP	O
Steel	O
used	O
them	O
for	O
real-time	B-General_Concept
control	I-General_Concept
of	O
rolling	O
steel	O
mills	O
,	O
British	O
Rail	O
and	O
London	O
Underground	O
for	O
real-time	O
train	O
scheduling	O
,	O
London	O
Fire	O
Brigade	O
and	O
Durham	O
Fire	O
Brigade	O
for	O
command	O
and	O
control	O
systems	O
.	O
</s>
<s>
The	O
computers	O
controlled	O
most	O
of	O
the	O
world	O
's	O
national	O
Videotex	B-Operating_System
systems	O
,	O
including	O
the	O
Prestel	B-General_Concept
viewdata	B-Application
service	O
.	O
</s>
<s>
At	O
the	O
Rutherford-Appleton	O
Laboratory	O
a	O
GEC	B-Device
4000	I-Device
system	O
was	O
used	O
to	O
control	O
the	O
synchrotron	O
and	O
injectors	O
used	O
for	O
the	O
ISIS	O
neutron	O
spallation	O
source	O
until	O
1998	O
.	O
</s>
<s>
A	O
number	O
of	O
variants	O
of	O
the	O
GEC	B-Device
4000	I-Device
processor	O
were	O
produced	O
,	O
including	O
(	O
in	O
approximate	O
chronological	O
order	O
)	O
:	O
</s>
<s>
Several	O
operating	B-General_Concept
systems	I-General_Concept
were	O
available	O
for	O
the	O
GEC	B-Device
4000	I-Device
series	I-Device
,	O
including	O
:	O
</s>
<s>
Programming	O
languages	O
available	O
included	O
Babbage	B-Device
(	O
a	O
high-level	B-Application
assembly	I-Application
language	I-Application
)	O
,	O
FORTRAN	O
IV	O
,	O
CORAL	B-Language
66	I-Language
,	O
ALGOL	B-Language
,	O
APL	B-Language
and	O
BASIC	O
.	O
</s>
