7#include <manux/config.h>
8#include <manux/types.h>
12#include <manux/i386.h>
30 printf(
"[%d] C'est la boucle numero %d : \n", q, cpt++);
32 while(1){};
for (n = 3; n < 32; n += 2) {
35 while ((!compose) && (
d*
d <= n)) {
36 compose = compose || (n%
d == 0);
40 printf(
", %d", n);
for (
int i = 0; i<10000000; i+=2){
asm(
"");};
43 printf(
"\n--------------------------------------------------------------------------------\n");
46 nbLu =
lire(0, txt, 31);
49 printf(
" Lu %d => '%s'\n", nbLu, txt);
52#ifndef MANUX_PREEMPTIF
62 printf(
"Deuxieme tache\n");
64 for (n = 0; n < 10000000; n++) {
73 printf(
"Greetings from userland !\n");
77 for (n = 0; n < 10000000; n++) {
void calculerPremiers(int q)
int lire(int fd, void *buffer, int nb)
void printf(char *format,...)
Un premier printf.
int basculerTache()
Basculer vers une autre tâche. On rend simplement la main, c'est du collaboratif.
int creerNouvelleTache(void(corps()), booleen shareCons)
Création d"une nouvelle tâche.