24 ms·
Computer Science from the Bottom Up (2016)
- dillonmckay 7y agoThis seems more for OS fundamentals than full-on CS, still good, though.
- monoideism 7y agoLooks like a decent resource for Unix OS / system programming, but it's definitely not computer science.
- lbatx 7y agoAgreed. I don't see how you can leave out (among other things) databases, Big O notation, networking, and call it a computer science primer. Good for what it is, but misnamed.
- delsarto 7y agoAuthor here ... Yes as pointed out many times not "computer science" and I somewhat regret the name. However, it came out of me being a teaching assistant for people doing computer science degrees. A surprising number of people got to 3rd year operating systems courses without realising things like 2^10 is a kilobyte, 2^20 is a megabyte, etc. Let alone how a program was linked and loaded. I hope for this to be helpful, there are plenty of similar resources but sometimes the way one person says something resonates more than another. I deliberately wanted to avoid x86-only to illustrate for similar reasons. Unfortunately Itanium proved to be a poor choice, ARM would have been better, but it gives me something to update if I get time! However, much of the basic content still remains relevant many years on.
- dang 7y agoWhat year should we put up there?
- yellow_lead 7y agoLooks like someone has vandalized your guide. > Reordering > This bit is crap
- delsarto 7y agoYes, it has some rough edges. One lesson you can learn is probably not to write things like this, and just let what you have stand as it is, and incrementally improve it.
- yellow_lead 7y agoThanks for the guide nonetheless. Going to be refreshing myself on a lot of this.
- solidasparagus 7y agoIs there a mechanism to submit fixes? This is a wonderful resource, but the deeper I get, the more I find it needs a little proofreading. I'd be happy to open PRs/whatever with typo/grammatical fixes. Also, thanks for writing this - I've had to deal with more and more of these concepts recently and this is the first resource I've found that has helped me understand how the parts fit together and why they exist.
- acbart 7y agoIsn't it amazing how people pass courses, even perhaps demonstrate mastery at a point in time, but manage to get to later courses without fully understanding things? Students end up with a very strange mental framework by the time they graduate, and it seems like most students actually know shockingly little. I don't know that there's a solution, or even that it's an issue. To me, this is simply a reflection of how people learn. Regardless, this seems like a nice little document for those 20% of students who are still willing to read supplementary materials. Then again, this is short and clear enough that if it were properly chunked within a course and had graded assignments attached, many students would probably actually skim it. If you ever want to develop this some more, I hope you'll consider something like Runestone[0], in order to give it some auto-graded questions along the way! [0] https://runestone.academy/runestone/default/user/login?_next=/runestone/default/index https://runestone.academy/runestone/default/user/login?_next...
- henrikschroder 7y agoWhen I did my CS programme decades ago, we all started with Scheme, which is very high-level, and forced everyone to focus on the algorithms, the math of it, instead of what the hardware is doing, or how the Scheme interpreter is implemented. It gets you going, thinking about values and execution and iteration and recursion. Starting with bits and bytes and hardware would be pretty goddamn boring, I think. You'd lose a lot of students that way. That said, in the third year we had a course in analog electronics, which was basically transistors and logic gates. Following that course was one in digital electronics, where we all built our own little toy 8-bit computer, wiring the CPU ourselves, writing the microcode ourselves. I'll never forget the a-ha moment when you realize that your instruction set are just binary patterns representing which wires to put a current on, which units to toggle on and off. The instruction to move a value from a register to an address in RAM has to look like this, because you need to toggle the read input on the correct register, and the write input on the RAM unit, and everything else has to be off. Blew my mind at the time. The clock was manual if you wanted to, so you could step through and watch your little CPU run a program, or you could set it to like 1Hz and watch the thing go. And from there, you can sort of get how a modern computer works, it's just a matter of going from 1Hz to 1GHz, wider buses, wider instruction sets, but it's no longer "magic" how the CPU works, it's all ones and zeroes, for a reason, and you now know that reason.
- zelly 7y ago*kibibyte
- diego898 7y agoHello, thanks for releasing this! Are there any plans to release chapter 10?
- delsarto 7y agoIt is written in DocBook, which has become increasingly annoying to publish with and I think is, unfortunately, unmaintained now. I have been considering some parts on containers and virtualisation which isn't covered at all. The Itanium and PowerPC examples probably haven't aged well. There is no question that Itanium is a very interesting architecture with many interesting features, but now it is dead it's like deciphering hieroglyphs. I think I have to update these to ARM, or maybe even RISC-V to be more relevant moving forward. So that would be my plans, as they were :)
- userbinator 7y agoI actually think "bottom up" is more of a misnomer than "computer science" as a title for this material, since when I think of "bottom up" I think of things like nand2tetris and Petzold's book. This looks more like "selected topics in operating systems" with some review of computer architecture basics mixed in.
- delsarto 7y agoThis was really seeded for me when trying to teach people taking computer science courses who were trying to do practical things like integrate C libraries into their higher level projects, but didn't really understand how things were working under the hood and getting themselves into a mess. If they understood a little more about how their program was built and run ... from the bottom up, as it were :) ... they would have had less pain. Of course, it just shows as usual the hardest problem in computer science is indeed, naming! Edit: BTW you're right, "Code" by Petzold should be required reading http://www.charlespetzold.com/code/index.html http://www.charlespetzold.com/code/index.html
- absorber 7y agoPerhaps adding a "Prerequisites" chapter might further help in getting the intended audience across? I associate "from the bottom up" approach with something being explained by starting from the very basics and aimed towards someone completely unfamiliar with the subject.
- Exuma 7y agoHey, so this is a great work you did. One thing perhaps you can explain... I've stared at this example now for like 30 minutes... https://www.bottomupcs.com/chapter01.xhtml https://www.bottomupcs.com/chapter01.xhtml Section on "Masking" How do you get 0x09 or 0x90? I get how using <memory> & <mask> = <extracted data>... so: 10100101 & 11110000 = 10100000 But I have yet to see how this is 0x90 or 0x09, perhaps I'm misunderstanding. I'm trying to understand the 'shift' piece of it
- 314 7y agoIt’s a typo: he meant 0xa0 or 0x0a and the shift is the four positions to the right to extract the top nybble of the byte.
- Exuma 7y agoAwesome, thank you... I thought I was going insane. So you shift 4 times correct?
- delsarto 7y agoThanks, I believe this should be clearer with https://github.com/ianw/bottomupcs/commit/d8dfd3dc6be5795f4b0dc15147f24049eea28367 https://github.com/ianw/bottomupcs/commit/d8dfd3dc6be5795f4b...
- 314 7y agoGreat resource - very detailed and your style is clear and readable. I'd happily recommend this to anybody who is studying an OS course (and in fact emailed a link to some people who teach similar courses to see if they would use it as background reading).
- Exuma 7y agoIt appears this section might be incomplete: Branch Prediction pipeline flush, predict taken, predict not taken, branch delay slots
- smitty1e 7y agoSeems an excellent place to mention http://linuxfromscratch.org/ http://linuxfromscratch.org/
- yellow_lead 7y agoThis looks like a great resource. I wish I had it for my OS class.
- yters 7y agoWhile not technically all of what's covered in CS, in my experience with a PhD in Comp. Eng., 8 years as an AF comm officer, and 3.5 years in the commercial sector as a soft. eng., this is vastly more useful than most of what's covered in a CS curriculum. The CS curriculum probably made more sense back in the day when everyone was essentially an embedded developer. But nowadays, the most useful knowledge I have is the low level mechanics of how things like the OS and networking protocols work. S/W eng. classes are a bit useful, but mostly knowing how to write in C++, Java, and now Python has gotten me most of the way. As it is, I have almost never run into a situation where most of my CS classes have been relevant. And, where they are relevant, it can be covered by a week course in the basics. I feel the CS curriculum would be much better service for students if it covered more of the knowledge of how to get things done. And not in a faddish, framework du jour manner, but there are constant elements throughout all the fads that a good developer should learn cold, and are not covered very well, at least in my 8 years in CS academia. IMHO the real problem with CS is that it's driven by AI envy, and much of what is considered important only makes sense in light of the assumption the human mind is basically a computer, and CS is all about how to recreate a human mind. However, almost none of that line of thought matters in the real world, and is most likely false.
- acbart 7y agoI'm assuming you have some concrete curriculum in mind, but I'm curious how what you're thinking of compares to something like the learning objectives spelled out in the CS Curricula 2013[0]? Personally, going through OP's site, I was nodding my head and comparing it to what I learned in my undergraduate CS degree. Some of it is dated, but most of it connects to the Architecture and Operating System classes I took. [0] https://www.acm.org/binaries/content/assets/education/cs2013_web_final.pdf https://www.acm.org/binaries/content/assets/education/cs2013...
- gumby 7y agoThat would be an engineering program not a science program. 40 years ago there wasn’t much difference but the field has moved on since then! A number of schools have split the tracks, or offer only a computer engineering program.
- 7y ago
- gumby 7y agoHere’s a slightly different take: starts with a practical set of things and then ends with some survey overviews for people who want to know more. A complement, not really an alternative, to this pdf.
- m10i 7y agoI have this favorited/bookmarked for the foreseeable future. Thank you for working on this (I hope it's still an active project if readers point out discrepancies)
- Thorentis 7y ago> "This bit is crap" (https://www.bottomupcs.com/chapter02.xhtml https://www.bottomupcs.com/chapter02.xhtml under "Reordering") Might want to proofread some of this and remove the ... proof-reading notes? Not sure what you thought was crap about this section?
- delsarto 7y agoI think in my mind at the time I was comparing it to Hennessy and Patterson; something that is obviously playing a in a completely different league! Over time I have become a bit more realistic :) I've stopped worrying if it's better or worse than anything else. As long as it's factually correct, I think a rising tide floats all boats so the more we all write and read others work, the better off we'll be.
- barbs 7y agoRelated: nand2tetris: https://www.nand2tetris.org/ https://www.nand2tetris.org/. "This site supports a course and a textbook that guide students and self-learners through the construction of a modern, full-scale computer system - hardware and software - from the ground up."
- gumby 7y agoHere’s a slightly different take: The Secret Life of Programs (https://nostarch.com/foundationsofcomp https://nostarch.com/foundationsofcomp ). It starts with a practical set of things and then ends with some survey overviews for people who want to know more. A complement, not really an alternative, to this pdf. (I fumble fingered this the first time and left out the link! Unfortunately I can't delete the confusing comment but fortunately it is being downvoted away)
- arm1c 7y agoDoes anyone know if there's a book like this? Basically intro to OS but conceptual stuff only - for someone who didn't take it in school and wants to learn the high level details, not to the level normally covered in a college course.
- FiberBundle 7y agoComputer Systems - a Programmer's Perspective
- userbinator 7y agoPrevious discussions: https://news.ycombinator.com/item?id=13249675 https://news.ycombinator.com/item?id=13249675 https://news.ycombinator.com/item?id=7611093 https://news.ycombinator.com/item?id=7611093
- TwoNineFive 7y agoI remember reading this a few years back. I stopped reading at some point because there were so many errors, unfinished bits, and just flat-out garbage. Sorry to the author but this needs to improve. It's a good start, but you need to invite fixes and implement them. Put your email address on every single page and invite fixes and then implement them. This could be an awesome resource, but right now it's too full of errors to be useful. Nobody should be recommending this. Nobody who had actually reviewed it all would recommend it.
- delsarto 7y agoEveryone who tries to create something eventually comes up against being told their work is flat-out garbage. Unfortunately I don't think there is a vaccination for it, and one must just take their chances and hope to build a mental immunity so it doesn't ruin your day. It's sad to say that many don't develop a resistance, and I think we lose many good contributors that way.
- outoftheabyss 7y agoIt's always good to take constructive criticism but when the negative commenter contributes little of worth, both in the comment and to the wider community, I think it is safe to ignore. Thanks for sharing
- JohnL4 7y agoAs has been said before: ignore the boos. They usually come from the cheap seats.
- rodneyzeng 7y agoCall it Information industry corners from bottom up.
- quocble 7y agoNot very good to be honest. Nothing about schedulers, bootstrap, and most of it is very general information. it doesn't give actual clear picture how everything comes together, and it is very system specifics (unix). CS should be agnostic to any system architecture. You do cover binary , but the more fundamental question what is the foundation of binary mathematics. It goes back to Turing machine, and how transistors are built and how you compose them into bigger units, and then you talk about CPU architecture, the adder, multiplexer, the PLU, etc.
- malandrew 7y agoCan you recommend one or more resources that you think do a better job achieving a bottom up approach to CS?
- hootbootscoot 7y agoThis is great. It covers a pretty wide range of stuff one is presumed to know and allows for both a big picture view and sufficient detail for some "hole-filling" and connection between ideas. I would consider this an interesting lecture series.
- viyider491 7y agoFREE SPINS 1coinmaster.com COIN MASTER FREE SPINS 1coinmaster.com COIN MASTER FREE SPINS 1coinmaster.com COIN MASTER FREE SPINS 1coinmaster.com COIN MASTER FREE SPINS 1coinmaster.com COIN MASTER FREE SPINS 1coinmaster.com COIN MASTER FREE SPINS 1coinmaster.com COIN MASTER FREE SPINS 1coinmaster.com COIN MASTER FREE SPINS 1coinmaster.com COIN MASTER FREE SPINS 1coinmaster.com COIN MASTER FREE SPINS 1coinmaster.com COIN MASTER FREE SPINS 1coinmaster.com COIN MASTER FREE SPINS 1coinmaster.com COIN MASTER FREE SPINS 1coinmaster.com COIN MASTER FREE SPINS 1coinmaster.com COIN MASTER FREE SPINS 1coinmaster.com COIN MASTER FREE SPINS 1coinmaster.com COIN MASTER FREE SPINS 1coinmaster.com COIN MASTER FREE SPINS 1coinmaster.com COIN MASTER FREE SPINS 1coinmaster.com COIN MASTER FREE SPINS 1coinmaster.com COIN MASTER FREE SPINS 1coinmaster.com COIN MASTER FREE SPINS 1coinmaster.com COIN MASTER FREE SPINS 1coinmaster.com COIN MASTER FREE SPINS 1coinmaster.com COIN MASTER FREE SPINS 1coinmaster.com COIN MASTER FREE SPINS 1coinmaster.com COIN MASTER