CPS 209 Lecture 7: Lecture 7 Concurrency

57 views16 pages

Document Summary

Java virtual machine: one of the processes running inside a computer execution of jvm: simulates an imaginary computer that executes byte code (which resides in a sandbox) inside your real computer. Data memory of the jvm has 3 parts, which are intensely secured from improper use: bytecode object heap local variable stack areas. How is communication done b/w java threads? all threads share the same object heap so communication occurs via reading and writing shared objects. What is divided into separate threads? execution of the bytecode program each thread has its own program counter points to the position in the bytecode where the thread is currently being executed at. Why is it necessary for each thread to have its own stack of local variables? useful in general bc different threads execute different parts of the program. Threads generally: share same object heap have their own local variables have an internal program counter.

Get access

Grade+20% off
$8 USD/m$10 USD/m
Billed $96 USD annually
Grade+
Homework Help
Study Guides
Textbook Solutions
Class Notes
Textbook Notes
Booster Class
40 Verified Answers
Class+
$8 USD/m
Billed $96 USD annually
Class+
Homework Help
Study Guides
Textbook Solutions
Class Notes
Textbook Notes
Booster Class
30 Verified Answers