2. Course Logistics and Learning#
2.1. What does it mean to study Computer Systems?#
“Systems” in computing often refers to all the parts that help make the “more exciting” algorithmic parts work. Systems is like the magic that helps you get things done in practice, so that you can shift your attention elsewhere. In intro courses, we typically give you an environment to hide all the problems that could occur at the systems level.
Most of us have had a bug, where we found a solution to get by, without really understanding why the solution fixed it or why that bug happened.
Debugging often requires understanding, in practice, of how the programming language works, how it translates that to hardware, and how the hardware works.
the first “bug” was an actual moth
These programmers had to know how to take apart the physical computer in order to find the insect.
our computers are a lot different, but we still need systems understanding to be efficient.
Important
In this course, we will take the time to understand all of this stuff. This means that we will use a different set of strategies to study it than we normally see in computer science.
This is a 300 level course, so you are one step closer to being a professional instead of only a student.
This is still a college course, so we will be taking time to understand the theory and the why not only the what that a bootcamp or on the job training might provide.
However, instead of using a text book that is designed explicitly and primarily for a school context, we will use primary sources.
In our context, that means using three main types of sources:
official reference docs
direct research results
first hand accounts by professional developers
Back to what a system is …
From ACM Transactions on Computer Systems
ACM Transactions on Computer Systems (TOCS) presents research and development results on the design, specification, realization, behavior, and use of computer systems. The term “computer systems” is interpreted broadly and includes systems architectures, operating systems, distributed systems, and computer networks. Articles that appear in TOCS will tend either to present new techniques and concepts or to report on experiences and experiments with actual systems. Insights useful to system designers, builders, and users will be emphasized.
We are going to be studying aspects of computer systems, but to really understand them, we also have to think about why they are the way they are. We will therefore study in a broad way.
We will look at blogs, surveys of developers, and actually examine the systems themselves.
2.2. Mental Models and Learning#
When we know something well, it is easier to do, we can do it multple ways,
it is easy to explain to others and we can explain it multiple ways.
we can do the task almost automatically and combine and create things in new ways.
This is true for all sorts of things.
Important
We will practice and reinforce things a lot
a mental model is how you think about a concept and your way of relating it.
Novices have sparse mental models, experts have connected mental models.
2.3. Why do we need this for computer systems?#
2.3.1. Systems are designed by programmers#
Warning
this section is a little different than what I said in class, but it is still important and related.
Computer Science is not a natural science like biology or physics where we try to understand some aspect of the world that we live in. Computer Science as a discipline, like algorithms, mostly derives from Math.
So, when we study computer science, while parts of it are limited by physics1, most of it is essentially an imaginary world that is made by people. Understanding how people think, both generally, and common patterns within the community of programmers2 understand how things work and why they are the way they are. The why can also make it easier to remember, or, it can help you know what things you can find alternatives for, or even where you might invent a whole new thing that is better in some way.
2.3.2. Context Matters#
This context of how things were developed can influence how we understand it. We will also talk about the history of computing as we go through different topics in class so that we can build that context up.
2.3.3. Optimal is relative#
The “best” way to do something is always relative to the context. “Best” is a vague term. It could be most computationally efficient theoretically, fastest to run on a particular type of hardware, or easiest for another programmer to read.
We will see how the best choice varies a lot as we investigate things at different levels of abstraction.
For finding and reading this section, add a link to the heading above Systems are designed by programmers
to your community_contributions.md
in your KWL repo on a new branch, title the PR “Community Badge- Careful Reading” and request a review from Dr Brown (@brownsarahm
)
this will count for one community badge!
2.4. Let’s get organized#
For class you should have a folder on your computer where you will keep all of your materials.
Open a terminal window. I am going to use bash
commands
if you are on mac, your default shell is
zsh
which is mostly the same as bash for casual use. you can switch to bash to make your output more like mine using the commandbash
if you want, but it is not required.if you are on windows, your GitBash terminal will be the least setup work to use
bash
if you have WSL (if you do not, no need to worry) you should be able to set your linux shell to
bash
The first command we will use is pwd
which stands for print working directory.
pwd
/Users/brownsarahm
this is called the path and specifically this is an absolute path
We can change into another directory with cd
for change directory
cd Documents/
To see what changed, we use pwd
again
pwd
/Users/brownsarahm/Documents
Note that the current path is the same as the old one plus the place we changed to.
I moved one step further into my inclass folder
cd inclass/
We can mak a new directory with mkdir
mkdir systems
What you want to have is a folder for class (mine is systems) in a place you can find it. (mine is in my inclass folder)
We can view what is in a folder with ls
for list
ls
I have a few other folders here
fa22 prog4dsfa23 sp23 systems
And again check the path
pwd
/Users/brownsarahm/Documents/inclass
then I can do into the new folder I just made
cd systems/
and look at the path one more time
pwd
/Users/brownsarahm/Documents/inclass/systems
We can change back to the home directory with ~
cd ~
and confirm:
pwd
/Users/brownsarahm
just like before
Then we can use the relative path` of where we want to go:
cd Documents/inclass/systems/
cd
with no path also works
cd
and we can use pwd
to see where we end up
pwd
/Users/brownsarahm
it’s the home directoy just like ~
cd Documents/inclass/systems/
..
stands for up one level,
cd ../
pwd
/Users/brownsarahm/Documents/inclass/
2.5. Prepare for Next Class#
Find the glossary page for the course website, link it below. Review the terms for the next class: shell, terminal, bash, git, GitHub.
Check your kwl repo before class and see if you have recieved feedback, reply or merge accordingly.
Make sure you have a working environment, see the list in the syllabus, including
gh
CLI if you use mac`. Use the discussions to ask for help.Sign up for announcements
2.6. Review today’s class#
review notes after they are posted, both rendered and the raw markdown include links to each in your badge PR
map out your computing knowledge and add it to your kwl chart repo. this can be an image that you upload or a text-based outline in a file called prior-knowledge-map. (optional) try mapping out using mermaid syntax, we’ll be using other tools that will faciltate rendering later
2.7. More Practice#
review notes after they are posted, both rendered and the raw markdown versions. Include links to both views in your badge PR comment.
read Chapter 1, “Decoding your confusion while coding” in The Programmer’s Brain add a file called brain.md to your kwl repo that summarizes your thoughts on the chapter and how, if at all, it changes how you think about debugging and learning to program.
map out your computing knowledge and add it to your kwl chart repo in a file called prior-knowledge-map.md. Use mermaid syntax, to draw your map. GitHub can render it for you including while you work using the preview button.
Read more about version control in general and add a “version control” row to your KWL chart with all 3 columns filled in.
2.8. Experience Report Evidence#
In office hours, show us that you have a folder to work in for class.
2.9. Questions After Today’s Class#
2.9.1. I wonder why Mac and Linux have built-in terminals but Windows, arguably the most popular OS, does not have a built-in terminal?#
It does ahve a built in terminal, it just uses a Windows-only shell, bash
is the most popular shell to learn, because it is used on unix and linux systems and those are most commonly used for developers and code production environments where you may only have remote, terminal only access.
2.9.2. No real questions, maybe curious about downloading github files using commands#
that is what we will do Thursday
2.9.3. I’ve seen this type of material before so I would want to know about from other things I’ve seen would be how to interact with apps (google chrome) and stuff like that if that’s even possible?#
one step of the action that builds the course syllabus pdf launches chromium and prints the syllabus to a pdf.
2.9.4. Will we be piping things in the command line often, or are we mostly getting an introduction to the concept?#
we will be workign with the shell A LOT
2.9.5. I want to know more about what reverting does to github#
In a few classes, we will get there!
2.9.6. does making directories in a shell put them in the directory automatically?#
it puts them where you say, nothing explicit, is an implicit relative path to your current working directory.
2.9.7. Are there any benefits to choosing either zsh or bash? Ease of use, compatability, or anything else#
bash
is more standard
zsh
can do some things a little faster
Note
Learning more about the differences is an option for an explore badge
2.9.8. why does cd and cd~ do the same thing?#
~
is a shortcut for home and so is nothing.
2.9.9. I want to know more about how git is connected and will be applied to github and other tools we use.#
we will do this over the next few classes
2.9.10. how do I make up lectures#
Read the notes and complete the experience report (makeup) action
2.9.11. Should I merge the add my name to readme pull request?#
yes
2.9.12. if my lab was approved can i merge the pull request~#
yes
2.9.14. I think I’m still just a little confused on badges, and if they’re basically this class’s version of assignments, or something completely different.#
they’re roughly like assignments, it’s how we track what work you have completed. Not all assigned badges are required though, no matter what grade you want to earn.
- 1
when we are really close to the hardware
- 2
Of course, not all programmers think the same way, but when people spend time together and communicate, they start to share patterns in how they think. So, while you do not have to think the same way as these patterns, knowing what they are will help you reading code, and understanding things.