Changes between Version 1 and Version 2 of Sperimentazione 4
- Timestamp:
- Apr 22, 2011, 9:39:10 AM (14 years ago)
Legend:
- Unmodified
- Added
- Removed
- Modified
-
Sperimentazione 4
v1 v2 1 1 ==== Esempi con la syscall `clone`, specifica di Linux ==== 2 2 3 * Thread '''senza''' memoria condivisa export:trunk/threads-isolated.c 4 [[IncludeSource(trunk/threads-isolated.c, line_numbers=0)]] 3 * Thread '''senza''' memoria condivisa source:trunk/threads-isolated.c 5 4 6 * Thread '''con''' memoria condivisa export:trunk/threads-shared.c 7 [[IncludeSource(trunk/threads-shared.c, line_numbers=0)]] 5 8 6 9 * Thread '''con''' memoria condivisa, mutua esclusione ottenuta con Peterson export:trunk/threads-peterson.c 10 [[IncludeSource(trunk/threads-peterson.c, line_numbers=0)]] 7 * Thread '''con''' memoria condivisa source:trunk/threads-shared.c 11 8 12 * Thread '''con''' memoria condivisa, mutua esclusione con TSL export:trunk/threads-tsl.c export:trunk/enter.asm13 [[IncludeSource(trunk/threads-tsl.c, line_numbers=0)]]14 [[IncludeSource(trunk/enter.asm, line_numbers=0)]]9 * Thread '''con''' memoria condivisa, mutua esclusione ottenuta con Peterson source:trunk/threads-peterson.c 10 11 * Thread '''con''' memoria condivisa, mutua esclusione con TSL source:trunk/threads-tsl.c source:trunk/enter.asm 15 12 16 13 {{{ … … 21 18 22 19 23 ==== Esempi in Java====20 ==== Esempi in pthreads ==== 24 21 25 * Creazione di thread export:trunk/Basic.java 26 [[IncludeSource(trunk/Basic.java, line_numbers=0)]] 22 * Produttore e consumatore source:trunk/pthreads-pc.c 27 23 28 * Memoria condivisa export:trunk/Shared.java 29 [[IncludeSource(trunk/Shared.java, line_numbers=0)]] 30 31 * Memoria condivisa, mutua esclusione ottenuta con `synchronized`, export:trunk/Shared2.java 32 [[IncludeSource(trunk/Shared2.java, line_numbers=0)]] 33 34 35 * Produttore e consumatore, export:trunk/PC.java 36 [[IncludeSource(trunk/PC.java, line_numbers=0)]] 24 * Incrementer e watcher source:trunk/pthreads-counter.c