Singularity is an experimental
operating system
An operating system (OS) is system software that manages computer hardware, software resources, and provides common daemon (computing), services for computer programs.
Time-sharing operating systems scheduler (computing), schedule tasks for ef ...
developed by
Microsoft Research
Microsoft Research (MSR) is the research subsidiary of Microsoft. It was created in 1991 by Richard Rashid, Bill Gates and Nathan Myhrvold with the intent to advance state-of-the-art computing and solve difficult world problems through technologi ...
between July 9, 2003, and February 7, 2015. It was designed as a high
dependability OS in which the
kernel
Kernel may refer to:
Computing
* Kernel (operating system), the central component of most operating systems
* Kernel (image processing), a matrix used for image convolution
* Compute kernel, in GPGPU programming
* Kernel method, in machine lea ...
,
device driver
In computing, a device driver is a computer program that operates or controls a particular type of device that is attached to a computer or automaton. A driver provides a software interface to hardware devices, enabling operating systems and o ...
s, and
application software
Application may refer to:
Mathematics and computing
* Application software, computer software designed to help the user to perform specific tasks
** Application layer, an abstraction layer that specifies protocols and interface methods used in a ...
were all written in
managed code. Internal security uses
type safety
In computer science, type safety and type soundness are the extent to which a programming language discourages or prevents type errors. Type safety is sometimes alternatively considered to be a property of facilities of a computer language; that i ...
instead of
hardware memory protection
Memory protection is a way to control memory access rights on a computer, and is a part of most modern instruction set architectures and operating systems. The main purpose of memory protection is to prevent a process from accessing memory that h ...
.
Operation
The lowest-level
x86 interrupt
In digital computers, an interrupt (sometimes referred to as a trap) is a request for the processor to ''interrupt'' currently executing code (when permitted), so that the event can be processed in a timely manner. If the request is accepted ...
dispatch code is written in
assembly language and
C. Once this code has done its job, it invokes the kernel, which
runtime system
In computer programming, a runtime system or runtime environment is a sub-system that exists both in the computer where a program is created, as well as in the computers where the program is intended to be run. The name comes from the compile t ...
and
garbage collector are written in
Sing# (an extended version of
Spec#, itself an extension of
C#) and runs in unprotected mode. The
hardware abstraction layer
Hardware abstractions are sets of routines in software that provide programs with access to hardware resources through programming interfaces. The programming interface allows all devices in a particular class ''C'' of hardware devices to be acce ...
is written in
C++ and runs in protected mode. There is also some C code to handle debugging. The computer's basic input/output system (
BIOS
In computing, BIOS (, ; Basic Input/Output System, also known as the System BIOS, ROM BIOS, BIOS ROM or PC BIOS) is firmware used to provide runtime services for operating systems and programs and to perform hardware initialization during the ...
) is invoked during the 16-bit
real mode
Real mode, also called real address mode, is an operating mode of all x86-compatible CPUs. The mode gets its name from the fact that addresses in real mode always correspond to real locations in memory. Real mode is characterized by a 20-bit s ...
bootstrap stage; once in
32-bit
In computer architecture, 32-bit computing refers to computer systems with a processor, memory, and other major system components that operate on data in 32- bit units. Compared to smaller bit widths, 32-bit computers can perform large calcula ...
mode, Singularity never invokes the BIOS again, but invokes device drivers written in
Sing#. During installation,
Common Intermediate Language
Common Intermediate Language (CIL), formerly called Microsoft Intermediate Language (MSIL) or Intermediate Language (IL), is the intermediate language binary instruction set defined within the Common Language Infrastructure (CLI) specification. ...
(CIL)
opcode
In computing, an opcode (abbreviated from operation code, also known as instruction machine code, instruction code, instruction syllable, instruction parcel or opstring) is the portion of a machine language instruction that specifies the opera ...
s are compiled into x86 opcodes using the
Bartok compiler.
Security design
Singularity is a
microkernel
In computer science, a microkernel (often abbreviated as μ-kernel) is the near-minimum amount of software that can provide the mechanisms needed to implement an operating system (OS). These mechanisms include low-level address space management, ...
operating system. Unlike most historic microkernels, its components execute in the same
address space
In computing, an address space defines a range of discrete addresses, each of which may correspond to a network host, peripheral device, disk sector, a memory cell or other logical or physical entity.
For software programs to save and retrieve ...
(
process
A process is a series or set of activities that interact to produce a result; it may occur once-only or be recurrent or periodic.
Things called a process include:
Business and management
*Business process, activities that produce a specific se ...
), which contains ''software-isolated processes'' (SIPs). Each SIP has its own data and code layout, and is independent from other SIPs. These SIPs behave like normal processes, but avoid the cost of task-switches.
Protection in this system is provided by a set of rules called
invariants that are verified by
static program analysis
In computer science, static program analysis (or static analysis) is the analysis of computer programs performed without executing them, in contrast with dynamic program analysis, which is performed on programs during their execution.
The term ...
. For example, in the memory-invariant states there must be no cross-references (or memory pointers) between two SIPs; communication between SIPs occurs via higher-order communication channels managed by the operating system. Invariants are checked during installation of the application. (In Singularity, installation is managed by the operating system.)
Most of the invariants rely on the use of safer
memory-managed languages, such as Sing#, which have a
garbage collector, allow no arbitrary pointers, and allow code to be verified to meet a given
computer security policy.
Project status
The first Singularity Research Development Kit (RDK), RDK 1.1, was initially released on March 4, 2008,
being released under a
shared source license allowing academic non-commercial use and available from
CodePlex
CodePlex was a forge website by Microsoft. While it was active, it allowed shared development of open-source software.
Its features included wiki pages, source control based on Mercurial, TFVC, Subversion or Git, discussion forums, issue tr ...
.
RDK 2.0 was later released on November 14, 2008.
Similar projects
*
Inferno, first created in 1995, based on
Plan 9 from Bell Labs
Plan 9 from Bell Labs is a distributed operating system which originated from the Computing Science Research Center (CSRC) at Bell Labs in the mid-1980s and built on UNIX concepts first developed there in the late 1960s. Since 2000, Plan 9 has b ...
; programs are run in a virtual machine and written in
Limbo
In Catholic theology, Limbo (Latin ''limbus'', edge or boundary, referring to the edge of Hell) is the afterlife condition of those who die in original sin without being assigned to the Hell of the Damned. Medieval theologians of Western Europ ...
instead of C# with CIL;
open-source software
Open-source software (OSS) is computer software that is released under a license in which the copyright holder grants users the rights to use, study, change, and distribute the software and its source code to anyone and for any purpose. Ope ...
*
JavaOS
JavaOS is an operating system based on a Java virtual machine and predominantly used on SIM cards to run applications on behalf of operators and security services. It was originally developed by Sun Microsystems. Unlike Windows, macOS, Unix, or Un ...
, a legacy OS based on the same concept as Singularity
* JNode, an OS similar in concept to Singularity, but with
Java
Java (; id, Jawa, ; jv, ꦗꦮ; su, ) is one of the Greater Sunda Islands in Indonesia. It is bordered by the Indian Ocean to the south and the Java Sea to the north. With a population of 151.6 million people, Java is the world's mo ...
instead of C# with CIL
*
JX, a Java OS that, like Singularity, uses
type safety
In computer science, type safety and type soundness are the extent to which a programming language discourages or prevents type errors. Type safety is sometimes alternatively considered to be a property of facilities of a computer language; that i ...
instead of
computer hardware memory protection
Memory protection is a way to control memory access rights on a computer, and is a part of most modern instruction set architectures and operating systems. The main purpose of memory protection is to prevent a process from accessing memory that h ...
*
Phantom OS, a managed OS
*
SharpOS, a former effort to write an operating system using C#;
open-source software
Open-source software (OSS) is computer software that is released under a license in which the copyright holder grants users the rights to use, study, change, and distribute the software and its source code to anyone and for any purpose. Ope ...
* MOSA, a
.NET Framework
The .NET Framework (pronounced as "''dot net"'') is a proprietary software framework developed by Microsoft that runs primarily on Microsoft Windows. It was the predominant implementation of the Common Language Infrastructure (CLI) until bein ...
compiler and operating system using C#
*
Cosmos
The cosmos (, ) is another name for the Universe. Using the word ''cosmos'' implies viewing the universe as a complex and orderly system or entity.
The cosmos, and understandings of the reasons for its existence and significance, are studied in ...
, a ''building blocks'' toolkit for developing an OS using C#;
open-source software
Open-source software (OSS) is computer software that is released under a license in which the copyright holder grants users the rights to use, study, change, and distribute the software and its source code to anyone and for any purpose. Ope ...
*
TempleOS, a ring-0 operating system with JIT compiler;
open-source software
Open-source software (OSS) is computer software that is released under a license in which the copyright holder grants users the rights to use, study, change, and distribute the software and its source code to anyone and for any purpose. Ope ...
See also
*
Language-based system, general kernel design using language-based protection instead of hardware protection.
*
Spec#, programming language derived from C# by adding
Eiffel
Eiffel may refer to:
Places
* Eiffel Peak, a summit in Alberta, Canada
* Champ de Mars – Tour Eiffel station, Paris, France; a transit station
Structures
* Eiffel Tower, in Paris, France, designed by Gustave Eiffel
* Eiffel Bridge, Ungheni, ...
-like
design by contract.
*
Sing#, programming language derived from Spec# by adding channels and low-level constructs; used to build Singularity.
*
Midori, a Microsoft-developed microkernel-based operating system. Based on and related to Singularity.
References
External links
*
Singularity Design Motivationand an
tp://ftp.research.microsoft.com/pub/tr/TR-2005-135.pdf overview of the Singularity ProjectSingularity source codeon
CodePlex
CodePlex was a forge website by Microsoft. While it was active, it allowed shared development of open-source software.
Its features included wiki pages, source control based on Mercurial, TFVC, Subversion or Git, discussion forums, issue tr ...
Singularity: A research OS written in C#an interview of the Channel 9 team to Jim Larus and Galen Hunt (video & thread)
Singularity III: Revenge of the SIP an interview of the Channel 9 team to 3 researchers of the Singularity Project Team (video & thread).
Singularity IV: Return of the UI a demo of Singularity actually running (video & thread).
Singularity Revisited an interview of the Channel 9 team to 4 researchers of the Singularity Project Team (video & thread)
{{DEFAULTSORT:Singularity (Operating System)
Microsoft operating systems
Microsoft Research
Microkernel-based operating systems
Microkernels
.NET
Operating system distributions bootable from read-only media