Skip to content

SuperJaremy/dist-comp

 
 

Repository files navigation

Ricart–Agrawala Algorithm

Implementation of Ricart-Agrawala algorithm based on a library made in task 1.
Description is available in Russian (original) and English (translated and shorted).

ru

Task description in Russian

en

Description

Each child process should print to the terminal message in log_loop_operation_fmt (specified in pa2345.h) id * 5 times.

Build

clang -std=c99 -Wall -pedantic *.c -L. -lruntime

Run

export LD_LIBRARY_PATH="LD_LIBRARY_PATH:/path/to/pa4/dir";  
### empty line
LD_PRELOAD=/full/path/to/llibruntime.so ./pa4 -p <proc_num> [--mutexl]

--mutexl - if flag is specified, the child process will enter the critical section before printing to terminal.

About

ITMO Distributed Computing Fall 2022

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages