Conversation started Nov 1, 2016 at 6:10.
Nov 1, 2016 06:15
For a few years I used C and compilers and treated them like black boxes, ie I knew what X did but not how it did it.
Languages don't really exist in a sense, they are interpreted (run in a virtual machine) or they are converted back to bytecode for the computer to run them linearly.
So your fancy loops and generators and closures in your high level language are for your ease of use. When the compiler is finished with it all the computers sees is 00 FA EC etc
it only gets complicated when you start looking at larger numbers, you make full adders, start adding 8 bit numbers etc, basic computer, add a timer (because these things run fast)
So yes, when Intel makes their processors they write in something called microcode and there is something even below that I think
at the core your cpu executes stuff linearly, your program of bytes is loaded into memory and the cpu executes the instructions in order, functions are simple jumps to another set of memory then back using the stack
that is easy for us to read, the computer as output from that will get whatever the OPCODE that stems from the MICROCODE corresponds to and perform some toggling of bits inside the cpu
you can optimize your code directly via assembly, gcc -S file.c you will get assembly output, intel syntax is nice
python is an interpreter, it also has its own special instruction set that then maps to a C runtime methinks
use python's
dis
module to get "assembly" output of your code, ever notice .pyc files? these are bytecode that ur file gets converted to to run very fast
Once you get the connection everything you've ever read or learnt falls into place, logic gates, algebra, circuits etc
swipe you turn on some and this motion gets translated into some movement that then uses to execute some motion
php is in itself a framework already for C in a sense so PHP frameworks are already on a framework layer
For anyone who has seen the matrix, when Neo understands and starts seeing the matrix for what it is, a simulation/code. That is how your eyes will open when you understand that everything computing is 1s and 0s.
schrodinger, time crystals? maybe some space civilization out there with there advanced tech uses 10 base digits instead of 2
Quick fact, did you know you can have a pointer to a pointer to a pointer ... int ***a, uses are not so useful tho.
this means that if present is changed, the address will remain the same regardless, it already has its position in memory on the stack.
when you run your program there is a part of it that has space for your declared vars and that is limited
Conversation ended Nov 1, 2016 at 7:01.
iKlsR's Rant on Low Level Computing
Nov '161
Participants
- iKlsR 95%
- gandalf3 4%
all times are UTC