Unit 4 Gloss orig Flashcards
bytecode
The ‘machine code’ of the Java Virtual Machine
bytecode verifier
The part of the Java Virtual Machine that checks whether the bytecode about to be executed has not been tampered with
class loader
A part of the Java Virtual Machine that loads classes at runtime into the Java Virtual Machine’s memory. Java developers can implement their own specialised class loaders.
conditionally thread-safe class
A class that requires some external synchronisation to achieve thread safety. For example, individual accesses may not need external synchronisation, but a sequence of them might.
contention
A situation in which multiple threads are attempting to obtain the same resource.
countdown latch
A flexible thread-coordination mechanism that makes one group of threads wait for each of N other threads to reach a certain point in their execution, with N being the initial value of the latch’s counter.
divide-and-conquer strategy
A problem-solving strategy that breaks down a problem into subproblems of the same or similar type, continuing the process until the obtained subproblems are simple enough to be solved directly.
external synchronisation
Synchronisation done by the callers of methods
factory method
A method that creates objects. Typically, a factory method is a static methodthat hides the concrete class of the returned object: the client knows only which interface the object implements.
fail-fast operation
An operation that fails as soon as it detects some violation to consistency invariants. For example, iterators over pre-Java 1.5 collections throw an exception as soon as they detect that another thread is modifying the collection.
garbage collection
Aruntime technique to free the memory occupied by objects that are no longer used. The Java Virtual Machine specification does not impose any specific garbage collection algorithm.
green thread
Athread that is not visibleto the operating system and has to be created, scheduled and terminated by the Java Virtual Machine
immutable class
A thread-safe class whose instances never change once they have been created.
internal synchronisation
Synchronisation done by the methods themselves
interpreter
A program that executes another program.
Java Virtual Machine (JVM
A virtual machine defined mainly with the execution of Java programs in mind. The Java Virtual Machine is a specification, and there are many implementations of it, optimised for different platforms or Java editions.
just-in-time (JIT) compilation
A technique to compile a sequence of virtual machine instructions into machine code as the sequence is being executed
master–slave model
A model of communication in which one device or process (the master) has unidirectional control over other devices or processes (the slaves). For example, in a client–server system, the client is the master and the server is the slave
memory barrier
A special instruction to make local and shared memories consistent with each other.
memory model
A specification of how and when updates to shared data have to be propagated across different memories and processes.
native thread
Athread visible to the operating system and scheduled by it.
nested monitor lockout
A situation in which a thread T blocks or waits while holding a lock on the monitor that would enable other threads to make T progress. Thread T has therefore locked itself inside the monitor, keeping the ‘key’, i.e. the monitor’s lock.
priority queue
A queue that orders elements according to their associated priority so that the next element to be removed from the queue has the highest priority.
scalability under contention
The ability of an algorithm to maintain a high throughput under contention, i.e. to keep a high ratio of number of threads per time unit that access the same resource.