How Do Programs Do... Anything?? #programming #coding #lowcode

preview_player
Показать описание

How does code do anything? Isn't it all registers?📚🚀 #Cplusplus #CodingTips #OperatorOverloading #MatrixMultiplication #CodeTricks

🔥🔥🔥 SOCIALS 🔥🔥🔥
Рекомендации по теме
Комментарии
Автор

To be fair, this happens whenever I get an existential crisis midway through my coding session, and I've been coding for 10 odd years

uuu
Автор

I feel it's good to mention that the real answer to this question (how do programs do anything if all you're doing is moving data between memory and registers) is that some memory addresses are 🌟Magic🌟. That is, instead of being connected to a RAM chip, they connect to a USB hub, PCI bus, keyboard port, etc., and reading or writing to the address shares electrical signals with the device instead.

Some addresses are slightly less magic in that they're still RAM, but the RAM is shared with another device, such as a graphics or sound chip.

The syscall bit comes from the fact that these magic addresses are hidden from userspace programs, and the kernel has to poke them for us.

thehans
Автор

From just hearing the question "how do programs do anything" syscalls wouldn't have been the first thing I'd have thought they're asking about. Because "syscalls" as an answer will then just lead to the question of "but how do syscalls do anything".

sinom
Автор

Learning to program assembly on an 80s computer with no memory management hardware and all memory-mapped IO teaches you how everything works pretty quickly.

jamespilcher
Автор

Thank you youtube for recommending more code content

JalenF
Автор

was expecting you to explain how a syscall works under the hood, but ended up getting no explanation, lol nice

danny-jorb
Автор

I didn’t like my college education for being too theoretical, but I do appreciate being shown transistor up. I thought I would do electrical engineering like making the physical motherboards, but I’m ending up in software engineering more and more. It’s kind of cool to feel like an electrical wizard where I bend transistors to my will with words in a c file.

ryanquinn
Автор

part the process with me building a cpu in Minecraft was attaching registers to special memory addresses so it could actually do stuff :)

like, having a memory address that whenever set, sends the value to the binary to hex decoder and spits out a hex value, or another memory address that has 8 levers directly attached to its bits so it can read user input.

so ya similar concept, but definitely lower level since this is special memory registers rather than syscalls.

ThatJay
Автор

This is what trips up a lot of the functional programming "no side effects" mindset.

TreeLuvBurdpu
Автор

if you're a new programmer you should probably start out with an abstract programming language that gives you quick wins and keeps you interested and engaged while teaching you the core principles of programming.

nyxiom
Автор

For more information, try running strace on a program to know more which syscalls it makes for you.

ambuj.k
Автор

When you understand syscallw, context switch and interruptions, then you see how much a computer does without us noticing

David-lqck
Автор

How they even created the concept of computers is mind boggling to me

thirdworldrider
Автор

I used to program in assembly at school, in that time you have to use interrupts some calls for the BIOS and others for DOS.

hugoescarcega
Автор

the first application in any coding class after basic syntax should be a simple but relatively high abstraction from the bottom up. once you understand the scale of abstraction from the perspective of low level programming all systems and software architecture start to make sense.

first-thoughtgiver-of-will
Автор

I learned it, tried it, then promptly forgot all about it. Now I just accept that it works.

kkiimm
Автор

Man you don't know how much I love these!

chrismuga
Автор

It might seem unnecessary for someone who’s only writing the code and not messing with hardware, but if you’re curious about what’s actually happening or you’re confused about how it works then I recommend looking into a computer engineering course of some kind or even just minor YouTube tutorials like Ben Eater’s breadboard computer series. Plus you can use Sebastian Lague’s digital logic sim to work it out yourself alongside a tutorial. Learning how the physical computer handles anything even on a small scale like 8 bits will help you understand how the computer does anything. Just mentally scale it up from there, but it helps you understand how data is stored and moved, how the computer knows where to put it when you tell it to put it somewhere, how it knows to perform operations on the data, etc. With that in mind it can help understanding how assembly controls the computer and then you can also learn how your higher language compiles into assembly.

anthonycannet
Автор

Fantastic once again. Keep ‘em coming please!

jeffreyepiscopo
Автор

I thought he was going to talk about logic gates.😂 I think this how far you would have dug into this topic

calebwong
welcome to shbcf.ru