week 7 - eecs.umich.edu
Post on 08-Dec-2021
1 Views
Preview:
TRANSCRIPT
AnnouncementsBasic and Advanced 4 due October 18
Basic, Advanced 5 due October 22
Basic, Advanced 6 due October 27
Lecture 7: Potpourri 2 / 30
OverviewHow do computers understand us?
Fields and jobs in EECSInternships
GNU/Linux experience
Lecture 7: Potpourri 4 / 30
Quick rundown on comp archParts
CPUThe star of the show: handles general workloads
Memory (RAM)
Storage (HDD, SSD)
AcceleratorsGPU
MotherboardConnects everything together
Lecture 7: Potpourri 6 / 30
How do computers work?The CPU executes a sequence of instructions in the form of binary
This is known as machine code
The instruction set architecture defines what instructions there are and how they areencoded in binary
Yes, even CPUs have their own languages
Example ISAs: x86-64, ARMv8, RISC-V, MIPS
CPUs perform relatively rudimentary operationsArithmetic: add, sub, mul, div
Control: br, jmp
Memory: ld, st
(These are generic instruction names)
Example operation: "add 5 to variable"x86-64: [0x48,0x83,0xc0,0x05]
AArch64 (ARMv8): 0xe2800005
Lecture 7: Potpourri 7 / 30
How do computers understand us?Writing a program in machine code with a hex editor is not most people's idea of fun
Assembly languages are human readable representations of machine instructionsx86-64: add rax, #5 -> [0x48,0x83,0xc0,0x05]
AArch64 (ARMv8): add r0, r0, #5 -> 0xe2800005
An assembler takes assembly code and turns it into machine code
Assembly is still rather cumbersome to useYou're still working with machine instructions
You just now you have a tool that remembers how instructions are encoded
This isn't portable: assembly for one ISA won't work for another
Lecture 7: Potpourri 8 / 30
How do computers understand us?Higher level languages were developed
Raises abstraction level: can think in arithmetic expressions and higher levelconstructs
Leads to portability since you don't have to worry as much about hardware/ISAs
"Classic" classesCompiled
Interpreted
Things get a bit hazyByte-code
Just-in-time (JIT) compilation
Keep in mind languages don't necessarily need to fit any one classification
Lecture 7: Potpourri 9 / 30
Compiled languages"Compilation" in general refers to taking the language and producing a lower levelform
Compiled languages usually have the source code compiled down to the machinecode level
The CPU can directly run this machine codeThis is fast
Examples: C, C++, Fortran, Go, Objective-C, Rust, (Java*)
Lecture 7: Potpourri 10 / 30
Interpreted languagesThese languages usually are read by another program known as an interpreter
This program will parse statements and do something based o� of them
This is understandably slow and there are other strategies to improveperformance
Examples: Shell, Bash, Python, Ruby
Lecture 7: Potpourri 11 / 30
Lines get hazySome languages compile down to byte-code that is meant to be e�iciently interpreted
Java is a poster child
Some languages have interpreters that do just-in-time (JIT) compilationSource code is compiled to machine code at runtime
Traditional compilation is known as ahead-of-time (AOT) compilation in contrast
Ultimately these aren't really hard classificationsYou can compile Python if you want
You can write a C interpreter if you
Lecture 7: Potpourri 12 / 30
Running a programOn *nix systems you can execute both machine code and interpreted programs
Machine code programs are put into file formatted with data pertaining toexecution known as an "executable"
The execute permission bit must be set for you to execute a program file
Executable file formats have information that can identify their file type
*nix systems will recognize the shebang (#!) on the first line to figure that it's aninterpreted program, then call the appropriate interpreter
If there's no shebang, the OS will generally assume it's a shell script
#!/bin/env python3: invoke the /bin/env executable to find thepython3 executable
#!/bin/bash: invoke Bash as the interpreter
Lecture 7: Potpourri 13 / 30
EECS is a very broad subjectNo wonder when you have EE, CE, and CS all in one acronym
There's a lot of di�erent ways to divy up the space: this is just my conception of it
I'll keep it computer-relatedSorry, analog and power EEs
Not an all-encompassing list
Lecture 7: Potpourri 16 / 30
DomainsComputer hardware
Physical design engineer
RTL/ASIC design engineer
Design verification engineer
Computer architect
Hardware-so�ware twilight zoneEmbedded systems engineer
Firmware engineer
Lecture 7: Potpourri 17 / 30
DomainsComputer systems
Systems so�ware engineer
Compiler engineer
Embedded so�ware engineer
Lecture 7: Potpourri 18 / 30
DomainsApplications
Desktop so�ware developer 🦕
Mobile app developer 📱
Front-end web developer
Back-end web developer
Full-stack developer
So�ware engineer*
DevOps engineer
Testing/QA engineer
Lecture 7: Potpourri 19 / 30
DomainsData science
Data analyst
Data engineer
Machine learning engineer
Other areasCybersecurity
Robotics
Scientific computing/simulation
Research
Lecture 7: Potpourri 20 / 30
IndustriesYou can find these jobs in various industries
Tech
Gaming
Finance
Telecommunications
Defense
Government
Health care
and more (you'd be surprised at the opportunities in the restaurant industry)
Lecture 7: Potpourri 21 / 30
InternshipsGreat way to get experience and build up your resume
I learned a lot of my practical skills on the job
Job postings will go up during the Fall and early Winter: try to nab them!That doesn't mean all hope is lost if you're applying in late February/March
I got my internships as a "late" applicant
It doesn't cost anything to apply, unlike with college applications
Career fairs are not the only way to applyYou can still find success in online applications
Interviews o�en have a behavioral and technical portionBehavioral interview will involve questions about you as a person
Technical interview will test your knowledge
Getting an answer wrong on a technical interview isn't the end of the world: o�enthe interviewer is just as interested in your problem-solving process
Lecture 7: Potpourri 22 / 30
InternshipsIf your summer is open, try looking for an internship!
If you have companies in mind, check the job postings on their website
You can use websites like Indeed, Glassdoor, and LinkedIn to browse for jobs and seewhat's around
You might find something you like based on the description!
r/cscareerquestions can be a useful place to get some opinions on how the job marketis doing
Lecture 7: Potpourri 23 / 30
GNU/Linux experienceGNU/Linux o�ers a very large degree of freedom in setting up your system
You are in control of your computer
Lots of free alternatives to commonly used so�wareO�ice applications: LibreO�ice
Note taking: xournal++
Video editing: Kdenlive
Photo processing: darktable
Art: Krita, Inkscape
Fun list (it's for Arch, but gives a sense of what's there)
Lecture 7: Potpourri 26 / 30
Building your own environmentA Linux distribution encompasses a so�ware collection, the Linux kernel, and aparticular philosophy
Many distributions come with a lot of stu� and a particular look a feel, but you still havethe ability to radically change how they look and operate
What's most evident is the graphical user interface (GUI); here's some vocab
Display server: so�ware that handles the graphics for various client applicationse.g. X11, Wayland
Window manager: so�ware that manages control and appearance of windowse.g. awesome, i3, xmonad
File manager: so�ware that presents an interface for managing filese.g. Nautilus, Dolphin
Desktop environment: an all-in-one integrated environment that presents a fulldesktop experience, integrating a window manager, toolbars, file manager, networkmanagement, web browsing, etc.
e.g. GNOME, KDE Plasma, Xfce, LXQt
Lecture 7: Potpourri 27 / 30
Putting it together from the ground upI'll be using virtual machines to illustrate the OS installation process
Virtual machines (in this context) are emulated computer systemsYou have virtual CPUs and virtual storage and virtual monitors for your virtualmachine
You can install operating systems on them and treat them like any other computer
Fun fact: the course server is running on a virtual machine
I'll first install Ubuntu Linux on a VM to illustrate the typical Linux installation process
I'll then install Arch Linux on a VM to illustrate putting together a personalized setuppiece by piece
It's relatively quick to install since it doesn't install much in the beginning
While I stan Arch, there's nothing wrong about other distros
Lecture 7: Potpourri 28 / 30
Putting it together from the ground upInstallation media
Setting up a VirtualBox VM
OS installationUbuntu
Arch
OS setup and customization
Lecture 7: Potpourri 29 / 30
top related