News for hackers. Stuff that matters.
Re:Computer Science from the Bottom Up (2013) by kazinator on Saturday December 24, 2016 @10:42AM (#13250186)
If you have an audience that is even interested in C (they came specifically to learn about it) it is probably safe to assume that they are interested in lower levels of tech simply by the popular association between C and that.

People benefit from context. A "how stuff is made" tour might help. I would show the newbies all the steps: how we start with a piece of C source, and go to executable. Here is a simple program that adds two numbers. Okay, we pass it through this compiler and here it is in the processor-specific assembly language, which is quite different. The "plus" is being done by this ADD instruction here, which receives values from two internal data places in the processor called registers, which are a bit like the storage boxes in a pocket calculator. Then, assembly language is coded, nearly instruction by instruction, to machine code, which is these numbers here representing ones and zeros. This is a bit like sheet music for piano being translated to a punched paper piano roll, but even more direct.

Re:Computer Science from the Bottom Up (2013) by gravypod on Saturday December 24, 2016 @11:19AM (#13250333)
That is very top down. This is perfectly fine and the only reason why I think differently is because most of my peers are afraid of experimenting. They think everything they haven't seen is magic.... because well it seems that way. It's voodoo to them. When I see a compiler I just think "pfft, tokenizer, lexer, tree". When they see a compiler they think "I could never understand this in my life".

It's like when I go to my mechanic. I pop the hood, he looks at it, spouts off some Geordi LaForge-sounding nonsense, I pay him and I walk away feeling like I've made out like a bandit! "That moron! That stuffs so complciated this work was worth double that! Hahahaha!"

What's really happening is that my mechanic has touched under the hood and no matter the car he things "eh, I'll figure it out". Or "How hard could it be? I'f fixed thousands of cars and thousands of problems, I know what's wrong already!"

He gained that experiance from actually messing around under the hood. Not from driving the car at a high level like I have but from sticking his hands in and getting into the nitty gritty.

Going from the top down leaves people affraid to push further down into their machine. This is the fear of infinite complexity that they think is hiding under the surface. The truth is that all computer science material of of constant complexity when looked at on it's plane of theory. IF everything has been correctly abstracted and defined then nothing should be "complicated" but it should be "entierly understandable". Anyone who gets the basics should be able to go "eh, I'll figure it out" when referencing any part of the computer if it has been correctly implemented.

Re:Computer Science from the Bottom Up (2013) by qwertyuiop924 on Saturday December 24, 2016 @01:44PM (#13251072)
>When I see a compiler I just think "pfft, tokenizer, lexer, tree". When they see a compiler they think "I could never understand this in my life".

To be fair, they're probably more correct in this context. Even if you understand the basics of compilation (and by the way, if you're reading this comment and you don't have a basic understanding of how compilation works, you should go learn that. Like, right now, if you can) the chance of you actually understanding the entirety of GCC and/or Clang without taking three years to study them is pretty slim, AFAICT.

Re:Computer Science from the Bottom Up (2013) by gravypod on Saturday December 24, 2016 @08:06PM (#13252338)
The exercise isn't to put you ahead of everyone else. It is to get you to see where everyone else came from.

I could try and run a marathon but I'm very out of shape. One of my friends can try and run a marathon who isn't out of shape and while they won't win they can still do it and learn from the experiance. The goal isn't to win, it's to learn in this case.

Re:Computer Science from the Bottom Up (2013) by qwertyuiop924 on Saturday December 24, 2016 @09:25PM (#13252559)
That wasn't my point. My point is, even if you know the theory behind compilers, and maybe have written a few yourself, you probably will have difficulty understanding GCC, Clang, or another production compiler unless you've done work with such a compiler before.

That is, your friends' awe of the compiler is not only justified given their skill level, it's also likely justified at your skill level as well (although as I don't know you personally, I can't say for sure).

Re:Computer Science from the Bottom Up (2013) by Xenograph on Sunday December 25, 2016 @12:59PM (#13254847)
The awe you're describing and the "awe" of his friends are very different, AFAICT. What you describe is perfectly healthy and reasonable: GCC/etc are unquestionably complex systems that can't be fully understood without thorough long-term study and experience. Oversimplifying them would be reckless, and so the average user of them should possess a certain awe and respect for them.

But this is different from having no conception of how compilers work and how one might implement one. As complex as modern compilers are, the foundational principles still apply to them, and an understanding of these principles makes them much less awe-inspiring. I think that having a clear view of the big picture, rather than having certain areas of the picture blocked off entirely as magical black boxes, allows for better engineering choices.

Re:Computer Science from the Bottom Up (2013) by qwertyuiop924 on Sunday December 25, 2016 @01:25PM (#13254930)
I agree. So I suppose that awe is a bit different.