| Prev 15 | OO Programming and Java | Chapter 2 section 17 + Java Handout + Chapter 12 | lab15 Java101 |
| 16 | Concurrency and Java | Chapter 13 not sect'n 8 | lab16 Java102 |
| Next 17 | Exceptions | Chapter 14 | lab17 Java103 |
All modern operating systems use concurrency.
The introductory definitions and ideas in the book are important.
The various forms of hardware (MIMD and SIMD) and FORTRAN based concurrency can be ignored. Take our advanced architecture courses for this and/or talk to Dr. Gomez.
You need to understand
Threads are easier than networks
[ 14723 ]
Ada
The ideas in Ada are simple to use
Small error in section 13.7.3 (page 587)
The book describes the syntax for synchronizing a statement from Java 1.0.
synchronized(expression)
statement
In later versions of Java a synchronized(...) clause can only be applied to a block.
synchronized(expression)
{
statements
}
The synchronized modifier can still be applied to classes and methods/functions.
Examples of Concurrency
Look in these directories:
[ http://www.csci.csusb.edu/dick/cs320/sieve/ ]
[ http://www.csci.csusb.edu/dick/cs320/crypto/ ]
ls|grep 320
Examples
ls|wc -llists files and counts them. (ls =list, wc -l = count lines)
ls|grep 320|wc -llist files, filters out those with '320' in the name and counts them.
grep -l 320 *|wc -lcounts the number of files with '320' inside them.
ps -elf|grep $USERlists all processes and filters out those with your name in them... including the two processes 'ps -elf' and 'grep'.
. . . . . . . . . ( end of section Notes) <<Contents | End>>
Class Work
[ 16q.html ]