Skip to content

Commit 116a4fc

Browse files
committed
Small fixes for the first draft deadline
1 parent 16278d5 commit 116a4fc

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

src/paper.tex

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -132,11 +132,11 @@ \subsection{The Go Programming Language}
132132
In the official documentation of Go it claims: ``Go is expressive, concise, clean, and efficient. Its concurrency mechanisms make it easy to write programs that get the most out of multicore and networked machines, while its novel type system enables flexible and modular program construction.''~\cite{goDocs}
133133
So, Go tries to solve some of the problems that arise when writing concurrent software application by their design of language.
134134
% TODO: How does Go want to archive this?
135-
Go abstracts the creation of threads by using lightweight \emph{goroutines}, which can be created by using the \lstinline{go} followed by a named or anonymous function.
135+
Go abstracts the creation of threads by using lightweight \emph{goroutines}, which can be created by using the \lstinline{go} keyword followed by a named or anonymous function.
136136
The Go runtime maps these goroutines to normal Kernel threads during execution.
137137
Go encourages programmers to use concurrency by \emph{message passing}, which is assumed to be safer and more convenient to use than \emph{shared memory}.
138138
However, it is also possible to make use of \emph{shared memory}, which gives the developer a lot of freedom to orchestrate the parallel execution of threads.
139-
A study by Tu, Liu, Song and Zhan analyzed popular Go projects and their concurrency bugs.
139+
A study conducted by Tu, Liu, Song and Zhan analyzed popular Go projects and their concurrency bugs.
140140
They came to the conclusion that \emph{message passing} produced even more errors than \emph{shared memory}.
141141
Projects written in Go also tend to have more concurrency than projects written in traditional programming languages such as C.~\cite{tu2019go}
142142
Given all those conclusions it is even more important for Go developers to catch concurrency bugs effectively.
@@ -211,7 +211,7 @@ \subsection{Deadlocks}
211211

212212
A second example of a deadlock that might not be obvious is \Cref{lst:deadlockCh} which uses two unbuffered channels to transfer information between threads.
213213
The problem here is that without an active listener on an unbuffered channel, any send action will be blocked.
214-
To fix this, one could replace the unbuffered channel with a buffered one so that the execution flow of the program can continue without blocking.
214+
To fix this, one could replace the unbuffered channel with a buffered one, so that the execution flow of the program can continue without blocking.
215215
This shows how important it is to know the concrete implementation of a concurrency abstraction.
216216
Even though intended to ease the synchronization between threads and make inter-thread communication safer, by not knowing the implementation of an abstraction the developer can unknowingly create hard to find concurrency bugs.
217217

@@ -386,7 +386,7 @@ \section{Concurrency-aware Testing}
386386
They make use of a technique called \emph{Delta debugging}, which describes the process of narrowing down the spot where a failure is introduced by going back and forth between working and non-working conditions, in this case working and non-working thread schedules.~\cite{zeller2002delta}
387387
\Cref{fig:testing} shows a modified model of the \emph{DEJAVU} approach, suited for Go programs by using rr instead of of \emph{DEJAVU} for the recording and replay of the thread schedule.
388388
As a prerequisite, test cases need to be created that define the expected behavior of the application.
389-
These can either succeed or fail which can be shown be the exit code for example.
389+
These can either succeed or fail which can be shown by the exit code for example.
390390
In the first step, the Go application with these test cases gets executed and the thread schedule gets recorded by \emph{rr}.
391391
The either failing or succeeding recorded thread schedule is then passed to the next instance where the delta debugging unit requests new executions of the application with an alternated thread schedule until it can pinpoint the failure-inducing thread switch.
392392
The thread schedule is generated by the \emph{Schedule generator} and is replayed by the replay module in \emph{rr}.

0 commit comments

Comments
 (0)