Quark (kernel)

In computing, Quark is an operating system kernel used in MorphOS. It is a microkernel designed to run fully virtualized computers, called boxes (see sandbox). As of 2020[update], only one box is available, the ABox, that lets users run extant AmigaOS software compiled for Motorola 68000 series (MC680x0 or 68k) and PowerPC central processing units (CPUs).

## Contents

* 1 Design goals
* 2 Functions
* 3 Trance JIT
* 4 ABox
* 5 References

## Design goals

The Quark microkernel is not a member of the L4 microkernel family, but borrows concepts from it, including: the clan (group of tasks), ID concept, and recursive address mapping. Quark also has an asynchronous/synchronous message interface similar to Amiga's Exec kernel but adapted to an environment with memory protection.

Other Quark features include:

* High super/usermode switch speed
* Low interrupt latency
* Interrupt threads (IntThreads) and Int P-code abstraction
* Symmetric multiprocessing (SMP)
* Models task/thread and clan/chief
* Resource tracking
* Virtual memory (optional)
* Distributed computing
* No access to kernel structures
* Clean design with an elegant application programming interface (API)
* Micro/pico kernel mix

For this new kernel, a hardware abstraction layer is used which provides the needed hardware resource information like scanning all Amiga Zorro II bus boards, Peripheral Component Interconnect (PCI) boards, and local hardware resources.[1][2]

## Functions

* SYS_AddLinkMessage
* SYS_AttemptSemaphore
* SYS_AttemptSemaphoreShared
* SYS_CopyCPUHalConfig
* SYS_CreateMemList
* SYS_CreateTask
* SYS_DeletePort
* SYS_DeleteSemaphore
* SYS_DumpMemHeader
* SYS_FindFreeMemArea
* SYS_FindSkipSize
* SYS_GetLinkMessage
* SYS_GetMessageAttr
* SYS_GetNextCPU
* SYS_Init
* SYS_InsideClan
* SYS_IsClanMember
* SYS_MMUAddPage
* SYS_MMUGetEntry
* SYS_MoveRomModuleToMemoryEnd
* SYS_ObtainPort
* SYS_ObtainSemaphore
* SYS_ObtainSemaphoreShared
* SYS_ReleaseSemaphore
* SYS_ReplyMessage
* SYS_SendMessage
* SYS_SetMessageAttr
* SYS_SetupPageTable
* SYS_ShowExceptionThreads
* SYS_ShowForbidThreads
* SYS_ShowIntThreads
* SYS_ShowQuarkState
* SYS_ShowReadyThreads
* SYS_ShowRunThreads
* SYS_ShowThreads
* SYS_ShowWaitIntThreads
* SYS_ShowWaitThreads
* SYS_Start
* SYS_StartNextThread
* SYS_StartThread
* SYS_WaitPort

## Trance JIT

Trance JIT is a MorphOS just-in-time (JIT) compiler, or code translator, for running 68k applications within the MorphOS environment. It has been part of the MorphOS operating system since MorphOS 1.4.[3]

MorphOS has a fully integrated 68k emulator to run many Amiga applications, which were almost exclusively compiled for the 68k processor, though MorphOS runs on PowerPC. Trance supplements this function by adding JIT compiling, increasing the speed of the emulation. It does not interfere with the full integration of 68k and PowerPC tasks MorphOS provides.[1]

Trance exists in the form of an executable, run during boot, and a shared library. Although it is not technically part of the kernel, and MorphOS can be run without it, Trance is considered a fundamental part of MorphOS and one of its most powerful features.

Compatibility of Trance is considered to be very high and there are few to no 68k instruction sequences or applications which cause it any problems. It is also considered to be very fast, with users noticing few differences between 68k programs and native PowerPC code.[4][5][6]

Trance was developed by Ralph Schmidt and Teemu Suikki, with minor support from other MorphOS team members, Mark Olsen, Sigbjørn Skjæret, and Harry Sintonen.

## ABox

Under the Quark kernel, a PowerPC native reimplementation of the OS known from the Commodore A1000, A500(+), A600, A2000, A1200, A3000(T) and A4000(T) systems runs as a mix of a virtual emulation and a driver. This OS driver is called an ABox.

The 68k emulation is written in C and uses GNU Compiler Collection (GCC) assembler macros where needed to speed up some complex instructions.

A JIT engine named Trance is also available for MorphOS, to speed up old 68k programs beyond the current state of the traditional emulation.

The PPC native Exec supports the PowerPC register model which means there is no difference for this Exec if it runs 68k or PowerPC code. PowerPC code does not block multitasking inside the OS box like in emulations where the 68k code is just emulated in some host system's task (then every access outside this environment would stop the multitasking in the emulated environment).

For applications running under this new PowerPC ABox kernel 68k code runs as subroutines inside PowerPC tasks. For 68k or PowerPC applications it's fully transparent if some library, hook, interrupt is still 68k or already using PowerPC code.[7]

## References

1. ↑ 1.0 1.1 "MorphOS? What's that, then?". AmigActive: pp. 14–17. July 2000.
2. ↑ Gerber, David (2002). "MorphOS Full Features List". http://www.ggsdata.se/Pegasos/Bilder/morphos_reference.pdf.
3. ↑ "MorphOS 1.4 available". 9 August 2003. http://www.ann.lu/comments2.cgi?view=1060418084&category=files.
4. ↑ "How fast is MorphOS?". 8 February 2003. http://www.amiga.org/forums/archive/index.php/t-3501.html.
5. ↑ "MorphOS 68k speed". 3 November 2002. http://www.ann.lu/comments2.cgi?show=1036326848&category=forum&23.
6. ↑ "Comparatif : performances entre AmigaOS 4.1 et MorphOS 2.3 sur Pegasos II" (in Fr). September 2009. http://obligement.free.fr/articles/amigaos41_vs_morphos23.php.
7. ↑ "MorphOS Full Features List". 11 December 2002. http://polarboing.com/div/morphos/morphos-full-features-list.txt.

* v
* t
* e

MorphOS

Hardware|

* A1200
* A3000
* A3000T
* A3000UX
* A4000
* A4000T
* Efika
* Pegasos
* Mac Mini
* eMac
* Power Mac G4
* PowerBook G4
* iBook G4
* Power Mac G5

Components|

* AHI
* Ambient
* AmigaDOS
* CyberGraphX
* MUI
* PowerUP
* RAM disk
* TurboPrint
* WarpOS
* more...

File systems|

* FAT
* OFS
* FFS
* EXT2
* HFS
* NTFS
* PFS
* SFS

Software|

* Blender
* Cubic IDE
* Hollywood
* NetSurf
* Origyn Web Browser
* YAM
* more...

Games|

* Aquaria
* The Battle for Wesnoth
* Knights and Merchants
* OpenTTD
* Robin Hood
* Quake III
* Stratagus
* more...

* v
* t
* e

Microkernels-nanokernels

Kernels|

* ADEOS
* EPOC
* EKA1
* EKA2
* Eumel
* Exec
* ExecSG
* EROS
* K42
* L3
* L4
* Little Kernel
* Mac OS nanokernel
* Mach
* GNU Mach
* MicroEmpix
* µ-velOSity
* nucleus
* NuKernel
* Off++
* Opus
* PowerUP
* Quark
* TI-RTOS kernel
* Vanguard
* WarpOS
* Zircon

Operating
systems|

* AmigaOS
* Amoeba
* AROS
* AspireOS
* Broadway
* Icaros Desktop
* ARX
* BeRTOS
* ChibiOS/RT
* ChorusOS
* Copland
* Cosmos
* EROS
* FreeRTOS
* Fuchsia
* Genode
* GNOSIS
* GNU Hurd
* HelenOS
* Hydra
* Integrity
* JX
* JavaOS
* KeyKOS
* Lites
* Classic Mac OS (PowerPC kernel)
* MachTen
* MacMach
* MeikOS
* MERT
* µC/OS
* Midori
* MINIX
* Minix-vmd
* MINIX 3
* MkLinux
* MorphOS
* MQX
* NLTSS
* Nucleus RTOS
* NuttX
* OS2000
* OSE
* Phantom OS
* PikeOS
* QNX
* RC 4000
* Redox
* REX OS
* RIOT
* SharpOS
* Singularity
* SPIN
* Spring
* Symbian
* Taligent OS
* ThreadX
* TI-RTOS
* Tinix
* UNICOS
* V
* Verve
* VRTX
* VSTa
* Wombat OS
* Workplace OS
* Zephyr

0.00

(0 votes)

Original source: https://en.wikipedia.org/wiki/Quark (kernel). Read more

|

Retrieved from "https://handwiki.org/wiki/index.php?title=Quark_(kernel)&oldid=256676"
*[v]: View this template
*[t]: Discuss this template
*[e]: Edit this template