Protothreads

Protothreads

In der Informatik ist ein Protothread ein leichtgewichtiger Mechanismus zur parallelen Programmierung.

Protothreads kommen im Gegensatz zu Threads ohne eigenen Stapelspeicher aus. Sie können blockierende Kontexte mit geringstmöglichem Speicherbedarf abbilden. Solche Aufgabenstellungen findet man in der Informatik häufig, z.B. beim Umsetzen von Protokollen, bei Schnittstellen zwischen Computern und in eingebetteten Systemen.

Protothreads ist eine Art des kooperativen Multitasking. Deshalb können Kontextwechsel nur an speziell vorgesehenen Programmstellen stattfinden. Protothreads haben keinen eigenen Stapelspeicher, deshalb müssen lokale Variable statisch oder global definiert werden, wenn sie über einen Kontextwechsel hinweg erhalten bleiben sollen.

Protothreads verbinden die Vorteile von ereignisgetriebener (bzw. durch Zustandsautomater gesteuerter) Programmierung mit threadorientierter Programmierung. Protothreads wurden von Adam Dunkels entwickelt und veröffentlicht.[1] Die Umsetzung von Adam Dunkels ist ANSI-C-konform und kommt ohne Maschinensprache aus. Eine weitere Umsetzung[2] nutzt spezifische Spracherweiterungen der GCC-Toolchain. Zwei bekannte, ebenfalls von Adam Dunkels veröffentlichte Projekte, der TCP/IP-Stack uIP[3] und das Betriebssystem Contiki[4], nutzen Protothreads.

Siehe auch

Einzelnachweise

  1. Adam Dunkels: Protothreads - Lightweight, Stackless Threads in C.
  2. Larry Ruane: Protothreads.
  3. Adam Dunkels: The open source TCP/IP stack for embedded 8-Bit microcontrollers.
  4. Adam Dunkels: The Operating System for Embedded Smart Objects - the Internet of Things.

Quellen


Wikimedia Foundation.

Игры ⚽ Поможем сделать НИР

Schlagen Sie auch in anderen Wörterbüchern nach:

  • Protothreads — In computer science, protothreads are a low overhead mechanism for concurrent programming.Protothreads function as stackless, lightweight threads providing a blocking context cheaply using only two bytes per protothread.… …   Wikipedia

  • Protothread — In der Informatik ist ein Protothread bzw. Protofaden ein leichtgewichtiger Mechanismus zur parallelen Programmierung. Protothreads kommen im Gegensatz zu Threads ohne eigenen Stapelspeicher aus. Sie können blockierende Kontexte mit… …   Deutsch Wikipedia

  • Contiki — Скриншот VNC сервера запушенного на Atmel AVR порте ОС Contiki. Разработчик …   Википедия

  • Adam Dunkels — Infobox Celebrity name = Adam Dunkels caption = birth date = birth date and age|1978|05|28 birth place = Sweden occupation = Researcher website = http://www.sics.se/ adam/ known for = Contiki, lwIP, uIP, Protothreads footnotes = Adam Dunkels,… …   Wikipedia

  • Duff's device — In computer science, Duff s device is an optimized implementation of a serial copy that uses a technique widely applied in assembly language for loop unwinding. Its discovery is credited to Tom Duff in November of 1983, who at the time was… …   Wikipedia

  • Contiki — This article is about the embedded operating system. For other uses, see Contiki (disambiguation). Not to be confused with Kontiki. Contiki Screenshot of the VNC server running on the Atmel AVR port of Contiki. Com …   Wikipedia

  • Устройство Даффа — В информатике, Устройство Даффа (англ. Duff s device)  это оптимизированная реализация последовательного копирования, использующая ту же технику, что применяется для размотки циклов. Первое описание сделано Томом Даффом (Tom Duff) в… …   Википедия

  • Метод Даффа — В информатике, Метод Даффа (англ. Duff s device)  это оптимизированная реализация последовательного копирования, использующая ту же технику, что применяется для размотки циклов. Первое описание сделано в ноябре 1983 года Томом Даффом… …   Википедия

  • List of computer scientists — Expand list|date=August 2008This is a list of well known computer scientists, people who do work in computer science, in particular researchers and authors.Some persons notable as programmers are included here because they work in research as… …   Wikipedia

  • List of programmers — This list is incomplete; you can help by expanding it. This is a list of programmers notable for their contributions to software, either as original author or architect, or for later additions. Contents: A B C D E F G H I J K L M N …   Wikipedia

Share the article and excerpts

Direct link
Do a right-click on the link above
and select “Copy Link”