Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
  • Loading branch information
bhuvy2 committed Jul 7, 2019
1 parent 181ef10 commit 2340238
Show file tree
Hide file tree
Showing 6 changed files with 55 additions and 6 deletions.
2 changes: 1 addition & 1 deletion _scripts/deploy.sh
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ if test $BUILD_FOCUS = WIKI; then
else
# Copy main to a tempfile, so we don't get any checkout errors
TMP_DIR=`mktemp -d`;
find . -iname "*.pdf" -exec mv {} $TMP_DIR \;
find . -maxdepth 2 -iname "*.pdf" -exec mv {} $TMP_DIR \;

# Set up ssh
git config --global core.sshCommand "ssh -i /tmp/deploy_wiki -F /dev/null";
Expand Down
10 changes: 8 additions & 2 deletions malloc/malloc.tex
Original file line number Diff line number Diff line change
Expand Up @@ -582,8 +582,14 @@ \section{Case Study: SLUB Allocator, Slab allocation}

\section{Further Reading}

There are many other allocation schemes.
One of three allocators used internally by the Linux Kernel.
Guiding questions

\begin{itemize}
\item Is malloc'ed memory initialized? How about calloc or realloc?
\item Does realloc accept a number of elements or bytes?
\item Why may the allocation functions error?
\end{itemize}

See \href{http://man7.org/linux/man-pages/man3/malloc.3.html}{the man page} or the appendix of the book \ref{man_malloc}!

\begin{itemize}
Expand Down
17 changes: 17 additions & 0 deletions processes/processes.tex
Original file line number Diff line number Diff line change
Expand Up @@ -964,6 +964,23 @@ \subsection{Environment Variables}
\section{Further Reading}

Read the man pages and the POSIX groups above!
Here are some guiding questions.
Note that we aren't expecting you to memorize the man page.

\begin{itemize}
\item What is one reason fork may fail?
\item Does fork copy all pages to the child?
\item Are file descriptors cloned between parent and child?
\item Are file descript\textbf{ions} cloned between parent and child?
\item What is the difference between exec calls ending in an \keyword{e}?
\item What is the difference between l and v in an exec call? How about \keyword{p}?
\item When does exec error? What happens?
\item Does wait only notify if a child has exited?
\item Is it an error to pass a negative value into wait?
\item How does one extract information out of the status?
\item Why may wait fail?
\item What happens when a parent doesn't wait on their children?
\end{itemize}

\begin{itemize}
\item \href{http://man7.org/linux/man-pages/man2/fork.2.html}{fork}
Expand Down
6 changes: 5 additions & 1 deletion scheduling/scheduling.tex
Original file line number Diff line number Diff line change
Expand Up @@ -677,12 +677,16 @@ \section{Questions}
\tightlist
\item
What is scheduling?
\item
What is queueing? What are some different queueing methods?
\item
What is Turnaround Time? Response Time? Wait Time?
\item
What is the convoy effect?
\item
Which algorithms have the best turnaround/response/wait time on average
Which algorithms have the best turnaround/response/wait time on average?
\item
Do preemptive algorithms do better on average response time compared to non preemptive? How about turnaround/wait time?
\end{itemize}

\bibliographystyle{plainnat}
Expand Down
13 changes: 11 additions & 2 deletions synchronization/synchronization.tex
Original file line number Diff line number Diff line change
Expand Up @@ -2457,11 +2457,20 @@ \subsection{Consume}

\section{External Resources}

Guiding questions for the man pages

\begin{itemize}
\item How is a recursive mutex different than a default mutex?
\item How is mutex trylock different than mutex lock?
\item Why would a mutex lock fail? What's an example?
\item What happens if you try to destroy a locked mutex?
\item Can you copy the underlying bytes of a mutex instead of using a pointer?
\item What is the lifecycle of a semaphore?
\end{itemize}

\begin{itemize}
\item \href{http://linux.die.net/man/3/pthread_mutex_lock}{pthread\_mutex\_lock man page}
\item \href{http://linux.die.net/man/3/pthread_mutex_unlock}{pthread\_mutex\_unlock man page}
\item \href{http://linux.die.net/man/3/pthread_mutex_init}{pthread\_mutex\_init man page}
\item \href{http://linux.die.net/man/3/pthread_mutex_destroy}{pthread\_mutex\_destroy man page}
\item \href{http://man7.org/linux/man-pages/man3/sem_init.3.html}{sem\_init}
\item \href{http://man7.org/linux/man-pages/man3/sem_wait.3.html}{sem\_wait}
\item \href{http://man7.org/linux/man-pages/man3/sem_post.3.html}{sem\_post}
Expand Down
13 changes: 13 additions & 0 deletions threads/threads.tex
Original file line number Diff line number Diff line change
Expand Up @@ -603,6 +603,19 @@ \subsection{Extra: Lightweight Processes?}

\subsection{Further Reading}

Guiding questions

\begin{itemize}
\item What is the first argument to pthread create?
\item What is the start routing in pthread create? How about arg?
\item Why might pthread create fail?
\item What are a few things that threads share in a process? What are a few things that threads have different?
\item How can a thread uniquely identify itself?
\item What are some examples of non thread safe library functions? Why might they not be thread safe?
\item How can you stop a thread?
\item How can you get back a thread's "return value"?
\end{itemize}

\begin{itemize}
\item \href{http://man7.org/linux/man-pages/man3/pthread_create.3.html}{man page}
\item \href{http://man7.org/linux/man-pages/man7/pthreads.7.html}{pthread reference guide}
Expand Down

0 comments on commit 2340238

Please sign in to comment.