Академический Документы
Профессиональный Документы
Культура Документы
programs:
Execution options
Parent and children execute concurrently
Parent waits until children terminate
i ni t
pi d = 1
l ogi n
pi d = 8415
khe l pe r
pi d = 6
bas h
pi d = 8416
ps
pi d = 9298
e mac s
pi d = 9204
s s hd
pi d = 3028
kt hr e add
pi d = 2
pdf l us h
pi d = 200
s s hd
pi d = 3610
t cs ch
pi d = 4005
Address space
Child duplicate of parent
Child has a program loaded into it
UNIX examples
fork() system call creates new process
exec() system call used after a fork() to
replace the process memory space with a
new program
Information sharing
Computation speedup
Modularity
Convenience
Information sharing
Computation speed-up
Modularity
Convenience
send(message)
receive(message)
Implementation issues:
Shared memory
Hardware bus
Network
Logical:
Direct or indirect
Synchronous or asynchronous
Automatic or explicit buffering
Operations
Mailbox sharing
Solutions
ftruncate(shm_fd, 4096);
Wait indefinitely
Wait at most n milliseconds
Return immediately
Temporarily cache a message
Sockets
Remote Procedure Calls
Pipes
Remote Method Invocation (Java)