240 likes | 249 Views
Welcome to CS447! This course covers computer organization, design, and the hardware-software interface. Learn about embedded systems, consumer-grade computers, servers, and mainframes. Grading is based on labs, projects, and exams. Expectations include respect for diversity and mutual support. Cheating is strictly prohibited. Engage in active learning and don't hesitate to seek help. Let's explore the fascinating world of computers together!
E N D
Welcome! CS/COE 0447 Jarrett Billingsley
Administrivia CS447
hi • you can just call me Jarrett • jarrett@cs.pitt.edu • pitt.edu/~jfb42 • I send announcements through courseweb which come thru email • announcements/grades are the only things I use courseweb for • everything else is on my site. • also computers suck and the people who work with computers suck and get out while you can. • go grow plants. CS447
Textbook (optional) • Computer Organization & Design (Patterson & Hennessy) • textbooks are a racket • pirate everything you can • 5th edition is stupid ("PostPC" crap) CS447
Grading • there is no such thing as attendance • labs: 10% • graded on effort/completion • projects: 50% • two in MIPS assembly language, one in Logisim • lowest grade worth 10%; other two worth 20% • exams: 40% • lowest grade worth 15%, other 25% CS447
Expectations • religious absences: contact me ASAP • students with disabilities: contact the DRS ASAP • jokes/comments about sex, gender, race, ethnicity, religion, etc. are inappropriate for class, emails, office hours, chats etc. • if someone is making you feel unwelcome/uncomfortable, please contact me or the TAs privately • if you are making someone feel unwelcome/uncomfortable the adult response is to accept responsibility and apologize • not to say "it was just a joke/meme" or "you're too sensitive" • have you considered being nice? • humans are rational and emotional. • consider others' happiness. • if you fail to acknowledge your own emotions, you are doomed to be controlled by them. CS447
Teaching philosophy • you are a student. you’re supposed to be confused. • I wanna help you understand! • No questions are dumb! • Never be afraid to ask them! • DON’T STRUGGLE IN SILENCE ON YOUR PROJECTS/LABS!!!!! • what is a university setting good for today? • focus, practice, and access to people who know stuff • in other words, me • it is my job to teach you, please let me do my job CS447
I can tell when you cheat :^) • first cheat, fail the assignment; second cheat, fail the class. • don't post your code on github • don't "help" your friends by giving them code CS447
That being said… • I trust you! • I try to be accommodating about extensions and such • I don’t think most cheaters are being lazy • but you’re an adult, and are responsible for your actions. • if you're confused, don't cheat, ask me for help. • again, that's what I'm here for?????????? • you can work with one partner on projects as long as… • you inform me ahead of time, • and you do not share code! CS447
Introduction and Context CS447
Goals of this course • ”447 tries to convince you that computers exist.” – Dr. Misurda • 447 and 449 teach some similar topics from different angles: • data representation • memory organization • how programs really run • the call stack and calling conventions • this course also establishes important fundamental skills: • numerical bases and representation • logical operations • understanding logic diagrams CS447
More goals • Java has poisoned your mind • ok it's fine for algorithms but it's too high level to explain computer • learning assembly is like a car mechanic learning how an engine runs CS447
Where does this material fit in with CS and EE? • the “hardware-software interface” • where CS and EE overlap • each layer affects/is affected by layers above and below • ISA: Instruction Set Architecture • Programmer's interface to the computer hardware • logic design • how we make rocks Do Stuff • doing Lots of Stuff (aka a CPU) more abstract more concrete CS447
Classes of computers: Embedded (Microcontrollers) • very cute • 8/16-bit architectures are still common • as little as 32 BYTES of memory! • almost always run one, built-in program • focus on ultra-low power, cost, and size • becoming more common every day • “Internet of Things” (IoT) • now your fridge can crash, your TV can crash, your dishwasher can crash, and your lightbulbs can be a botnet • what a stupid future CS447
Classes of computers: Consumer-grade (PC/Mobile) • 1-8 cores, 32/64-bit architectures, MB-GB of memory, GB-TB of persistent storage • multitaskingoperating systems • similar capabilities, different design goals • focus is real-time user interaction: productivity, media, browsing, games • despite what the book says, I really don’tthink we’re in a “Post-PC” era • who’s gonna do all their work on a touchscreen usinggimped sandboxed apps CS447
Classes of computers: Servers and Mainframes • from high end desktops to much more powerful machines or groups of machines • dozens of cores, 32GB+ of RAM, massive storage systems, very high-speed networking • focus on real-timedata delivery - either from storage or after processing • redundancy and hot-swappability • goal is 100% uptime • power and cooling become huge concerns CS447
Classes of computers: Supercomputers • cluster of hundreds to thousands of CPUs • focus on crunching ENORMOUS datasets non-interactively • science, research, design, and simulation • and now, stock trading and "cryptocurrencies"… CS447
General computer organization Memory Persistent Storage Control Registers Datapath Other Peripherals Other Computers Processor Input/OutputDevices Network CS447
Lost in translation • "high-level" programming languages like Java exist for us intdoSomething() {this.x = 10; returnblarf();} 100010011111010000000000001000110111111100000?????? computers can only follow instructions written in machine language. compilers and VMs turn HLLs into machine language. CS447
What is machine language? • a computer has a fixed set of things it can do. • machine language is a numerical encoding of those operations. you could write "programs" by listing the columns/rows of buttons to press in order: (2,2)(4,4)(3,1)(3,4) 5 + 9 = but if we used that same "program" on a different calculator… (2,2)(4,4)(3,1)(3,4) CE * MS 6 CS447
What is assembly? • assembly is a human-readable representation of machine code • so it gives us direct control over the hardware… • …but at the expense of so many useful things the CPU is no more "intelligent" than a hand which can listen to instructions and push buttons on a 4-function calculator. CS447
Is assembly language useful today? • “assembly is fast, so we should use it for everything!”no, • it's not great for writing large programs • it can be dangerous, like with the Therac-25 • still useful for debugging (like in 449!) • if you write a compiler, you have to generate it • since that's what a compiler does • good for extremely performance critical low-level code, like: • device drivers • some parts of operating systems • High Performance Computing (simulations etc.) • increasingly fewer parts of video games • and… CS447
Embedded systems • you would be amazed how many CPUs are in any given device • many of these are programmed largely or entirely in assembly • many people use C but they're wrong, CS447