Skip to content

Commit

Permalink
Merge pull request #37 from Cloverchan/master
Browse files Browse the repository at this point in the history
Added all of the available exams to EDA040 and fixed some spelling mistakes in "Sammanfattning-Felix"
  • Loading branch information
antoneliasson committed Nov 1, 2015
2 parents 2383178 + 1ef1dcf commit c7c5f40
Show file tree
Hide file tree
Showing 18 changed files with 22 additions and 22 deletions.
Binary file added EDA040-realtid/extentor/101218-sol.pdf
Binary file not shown.
Binary file added EDA040-realtid/extentor/101218.pdf
Binary file not shown.
Binary file added EDA040-realtid/extentor/111022-sol.pdf
Binary file not shown.
Binary file added EDA040-realtid/extentor/111022.pdf
Binary file not shown.
Binary file added EDA040-realtid/extentor/120109-sol.pdf
Binary file not shown.
Binary file added EDA040-realtid/extentor/120109.pdf
Binary file not shown.
Binary file added EDA040-realtid/extentor/121027-sol.pdf
Binary file not shown.
Binary file added EDA040-realtid/extentor/121027.pdf
Binary file not shown.
Binary file added EDA040-realtid/extentor/131022.pdf
Binary file not shown.
Binary file added EDA040-realtid/extentor/140107.pdf
Binary file not shown.
Binary file not shown.
Binary file added EDA040-realtid/extentor/RT.081216.Svar.Eng.pdf
Binary file not shown.
Binary file added EDA040-realtid/extentor/RT.081216.Tenta.Eng.pdf
Binary file not shown.
Binary file added EDA040-realtid/extentor/RT.081216.Tenta.Swe.pdf
Binary file not shown.
Binary file added EDA040-realtid/extentor/RT.091216.Svar.Eng.pdf
Binary file not shown.
Binary file added EDA040-realtid/extentor/RT.091216.Tenta.Eng.pdf
Binary file not shown.
22 changes: 11 additions & 11 deletions EDA040-realtid/sammanfattningar/Sammanfattning-Felix.md
Expand Up @@ -72,9 +72,9 @@ Dekker’s Algorithm
------------------

Dekker’s algorithm solves the process synchronization problem with busy
waits. Meaning: using the below specified code results in a correctl
waits. Meaning: using the below specified code results in a correct
handling of critical areas. Alas, the threads spend CPU cycles in the
while loop, needlessly. If we implement Dekker’s we should compliment it
while loop, needlessly. If we implement Dekker’s we should complement it
with wait/notify functionality. Without this improvement the semaphores
can be referred to as spinlocks. The only advantage with using spinlocks
is that there is no context switch required.
Expand Down Expand Up @@ -114,7 +114,7 @@ A race condition is when multiple threads access and manipulate the same
data concurrently, and where outcome of the execution depends on the
particular order in which access takes place.

Mutual Exclustion
Mutual Exclusion
-----------------

If thread $T_i$ is executing in its critical section, then no other
Expand Down Expand Up @@ -172,7 +172,7 @@ accumulated.

Even with this fix, sleep still causes a minimum busy wait.

volatile, transient keywords
Volatile, transient keywords
----------------------------

Volatile means that the compiler is not allowed to cache the value of
Expand Down Expand Up @@ -235,10 +235,10 @@ and can thus resume its execution. (Despite being lower prioritized than
the other thread.) If we called the highest prioritized thead A, and
call the lowest Z. If Z blocks A, and Z is interrupted by a higher
prioritized thread (M?) that doesn’t share its resources, then this
thread (M) also blocks A. This is called a *prioriy inversion* since Z
thread (M) also blocks A. This is called a *priority inversion* since Z
and M will execute before A.

Priority inheritence protocol
Priority inheritance protocol
-----------------------------

The basic idea is to modify the priority of the tasks causing the
Expand All @@ -254,7 +254,7 @@ Raises the priority of the low priority thread temporarily
### Priority Ceiling Protocol

To bound the priority inversion phenomenon and prevent the formation of
deadlocks and chained blocking; PCP extends the priority inheritence
deadlocks and chained blocking; PCP extends the priority inheritance
protocol with a rule for granting a lock request.

When a job enters a critical section it receives the *priority ceiling*
Expand All @@ -280,20 +280,20 @@ job of said priority or lower.
said job has a lower priority than the priority ceiling, the first
job continues to run. If the interrupting job had a higher priority
than the job running inside the semaphore, its priority is
transferred to the currently running job. (Priority inheritence)
transferred to the currently running job. (Priority inheritance)

5. When no others jobs are blocked by the thread it resumes its
original priority, i.e. its “nominal priority.”

6. Priority inheritence is transitive. I.e. if job $J_3$ blocks $J_2$
6. Priority inheritance is transitive. I.e. if job $J_3$ blocks $J_2$
which in turn blocks $J_1$ then $J_3$ may inherit the priority from
$J_1$.

*Ceiling blocking* occurs when the highest prioritized task that can
access a resource is blocked by a lower prioritized job using the
resource.

### Immediate inheritence
### Immediate inheritance

The priority of the thread running in a semaphore is immediately raised
to the ceiling priority.
Expand Down Expand Up @@ -342,7 +342,7 @@ Sufficient and necessary
The analysis is *sufficient* if, when it answers “YES”, all deadlines
are met.

The analysis is *necesary* if, when it answers “NO”, there is a
The analysis is *necessary* if, when it answers “NO”, there is a
situation where deadlines could be missed.

The analysis is *exact* if it is both necessary and sufficient.
Expand Down
22 changes: 11 additions & 11 deletions EDA040-realtid/sammanfattningar/Sammanfattning-Felix.tex
Expand Up @@ -92,9 +92,9 @@ \section{Process synchronization}

\subsection{Dekker's Algorithm}
Dekker's algorithm solves the process synchronization problem with busy waits.
Meaning: using the below specified code results in a correctl handling of
Meaning: using the below specified code results in a correct handling of
critical areas. Alas, the threads spend CPU cycles in the while loop, needlessly.
If we implement Dekker's we should compliment it with wait/notify functionality.
If we implement Dekker's we should complement it with wait/notify functionality.
Without this improvement the semaphores can be referred to as spinlocks.
The only advantage with using spinlocks is that there is no context switch
required.
Expand Down Expand Up @@ -134,7 +134,7 @@ \subsection{Race condition}
data concurrently, and where outcome of the execution depends on the
particular order in which access takes place.

\subsection{Mutual Exclustion}
\subsection{Mutual Exclusion}
If thread $T_i$ is executing in its critical section, then no other threads
can be executing in their critical sections.

Expand Down Expand Up @@ -179,7 +179,7 @@ \subsection{Drifting}

Even with this fix, sleep still causes a minimum busy wait.

\subsection{volatile, transient keywords}
\subsection{Volatile, transient keywords}
Volatile means that the compiler is not allowed to cache the value of this
variable. It should be updated before evaluation.

Expand Down Expand Up @@ -229,9 +229,9 @@ \subsection{Priority inversion phenomenon}
If we called the highest prioritized thead A, and call the lowest Z. If Z
blocks A, and Z is interrupted by a higher prioritized thread (M?) that doesn't
share its resources, then this thread (M) also blocks A. This is called a
\emph{prioriy inversion} since Z and M will execute before A.
\emph{priority inversion} since Z and M will execute before A.

\subsection{Priority inheritence protocol}
\subsection{Priority inheritance protocol}
The basic idea is to modify the priority of the tasks causing the blocking. In
particular when Z blocks higher prioritized tasks, it temporarily inherits the
highest priority of the blocked tasks. This prevents medium prioritized threads
Expand All @@ -240,7 +240,7 @@ \subsubsection{Basic}
Raises the priority of the low priority thread temporarily
\subsubsection{Priority Ceiling Protocol}
To bound the priority inversion phenomenon and prevent the formation of deadlocks
and chained blocking; PCP extends the priority inheritence protocol with a
and chained blocking; PCP extends the priority inheritance protocol with a
rule for granting a lock request.

When a job enters a critical section it receives the \emph{priority ceiling}
Expand All @@ -263,17 +263,17 @@ \subsubsection{Priority Ceiling Protocol}
job has a lower priority than the priority ceiling, the first job
continues to run. If the interrupting job had a higher priority than
the job running inside the semaphore, its priority is transferred to the
currently running job. (Priority inheritence)
currently running job. (Priority inheritance)
\item When no others jobs are blocked by the thread it resumes its original
priority, i.e. its ``nominal priority.''
\item Priority inheritence is transitive. I.e. if job $J_3$ blocks $J_2$ which
\item Priority inheritance is transitive. I.e. if job $J_3$ blocks $J_2$ which
in turn blocks $J_1$ then $J_3$ may inherit the priority from $J_1$.
\end{enumerate}

\emph{Ceiling blocking} occurs when the highest prioritized task that can access
a resource is blocked by a lower prioritized job using the resource.

\subsubsection{Immediate inheritence}
\subsubsection{Immediate inheritance}
The priority of the thread running in a semaphore is immediately raised to the
ceiling priority.

Expand Down Expand Up @@ -310,7 +310,7 @@ \subsection{Sufficient and necessary}
The analysis is \emph{sufficient} if, when it answers ``YES'', all deadlines
are met.

The analysis is \emph{necesary} if, when it answers ``NO'', there is a
The analysis is \emph{necessary} if, when it answers ``NO'', there is a
situation where deadlines could be missed.

The analysis is \emph{exact} if it is both necessary and sufficient.
Expand Down

0 comments on commit c7c5f40

Please sign in to comment.