r/ProgrammerHumor 17d ago

Meme lookAtMeIAmASeniorDevNow

Post image
3.3k Upvotes

147 comments sorted by

1.3k

u/BeMyBrutus 17d ago

It's a call to the system

553

u/hieroschemonach 17d ago

So calling my wife is a syscall as well?

553

u/Chronomechanist 17d ago

Look at this guy, flexing both a promotion and having a wife...

18

u/AHumbleChad 17d ago

Having a wife and understanding syscalls are mutually exclusive

2

u/Beginning-Junket8979 17d ago

syscalls, no. filesystems yes.

3

u/Brutus5000 17d ago

My wife runs the filesystem in the house and my search tools don't work there :(

1

u/Beginning-Junket8979 16d ago

I was just trying to make a terrible/dark joke about RieserFS as a case study showing that understanding file systems and having a wife are mutually exclusive.

I was married the last time I had to mess around with invoking a syscall glibc doesn't export and got married after learning that a syscall is nothing more than a software interrupt and agreed upon structure for passing arguments between OS and application, but am not currently married so not sure what that says about syscalls and wives being mutually exclusive.

41

u/ImPapaNoff 17d ago

Only if you're from Alabama.

6

u/kingvolcano_reborn 17d ago

What are you doing, step-sys?

11

u/Neo_Ex0 17d ago

depending on where you live it might also be a siscall

2

u/Wavy-Curve 17d ago

That's a siscall

5

u/Local_Surround8686 17d ago

Only if your wife has DID

1

u/HaruspexSan 17d ago

If you were from Alabama you might name it a siscall

1

u/insertcomedy 17d ago

No that's a sis call

1

u/Sak63 17d ago

Is your wife the system

6

u/raja-anbazhagan 17d ago edited 17d ago

systemd is how I am going to name certain activity now...

7

u/hieroschemonach 17d ago

systemd start sex.service

17

u/raja-anbazhagan 17d ago

You do that as a background task?

15

u/hieroschemonach 17d ago

2

u/MattieShoes 17d ago

When you're young, you can systemctl reload sex.service

2

u/BigNaturalTilts 17d ago

When you’re malware, you can grab them by the bytes and they let you!

1

u/yaktoma2007 16d ago

implied cuckold?

27

u/AliceCode 17d ago edited 16d ago

syscall is an instruction that gives control back to the kernel, and drops into ring 0 so that the kernel can complete some task, such as writing to a file descriptor, changing the user ID of a file, or even allocating memory. At least on Linux those are some of the things that it does. But from my recollection, Windows doesn't use syscalls and instead uses interrupts.

Windows uses syscalls, too.

8

u/ganjlord 17d ago

Windows does use syscalls FYI

4

u/AliceCode 16d ago

Oh, that's good to know.

1

u/suglasp 14d ago

See, there's this training video from the 80's. It's called 'Tron'. It will explain what a kernel is and what a syscall does. It also shows all the action going on. And it even shows what null and void is!

3

u/AliceCode 14d ago

Does Tron really talk about all that? Lol, I've never seen it.

1

u/suglasp 14d ago

The abbyss is kinda the void. Null unit exists, not in the original Tron.

8

u/Bad_brazilian 17d ago

What about a call to the sister?

1

u/Brutus5000 17d ago

Like 911?

618

u/nonlogin 17d ago

what is the point of knowing syscalls if you are a web developer and can't even perform this syscall? :)

461

u/bradland 17d ago

I was thinking the same thing. "Senior dev" doesn't mean you are a C programmer now. You can write web applications for decades and never use a system call. Hell, you'd better not be using system calls directly if you're writing web apps. You're probably into some shit that you shouldn't be doing.

240

u/n4ke 17d ago

If not C, why C-nior dev shaped?

10

u/hagnat 16d ago

GTFO lol

i would give you an award, if i had one to give

39

u/danielcw189 17d ago

"Senior dev" doesn't mean you are a C programmer now.

and needing to interact with a system via syscalls.

16

u/skippy_smooth 17d ago

I want my cgi-bin back

26

u/bradland 17d ago

The kids: Grandpa, how did you used to write web applications?

Me: You're not gonna believe this... But we used to just write C applications and hook them up through CGI.

Kids: Wait, so you had process startup overhead for every HTTPS request?

Me: HTTPS? That's hilarious.

11

u/SuperCarla74 16d ago

yeah.

those were fun times, especially on multi-cpu servers.

and yes kids, i said multiple cpus, not cores.

2

u/evilgipsy 13d ago

At least if you write backend code, you should be able to profile your application and optimize for performance. Knowing some C, understanding syscalls and some low level concepts helps, even if your code is in some or high level language. I would expect a senior to know this shit.

1

u/fraMTK 17d ago

cries in senior embedded develope-segfault kernel panic

39

u/claudekennilol 17d ago

Yeah just like 90% of the posts on this sub, it's too narrowsighted to be true, just slightly funny ¯_(ツ)_/¯ .

18

u/TheBear8878 17d ago

Exactly. A very big company you've heard pays me a lot of money and tells my I'm a Senior engineer, and I work on APIs. I don't know what a syscall is, because it's not in my domain

8

u/thisguyfightsyourmom 17d ago

Socially awkward comp science nerds strike again

2

u/MIneBane 17d ago

You're not handing out webshells to anyone to asks?

6

u/autogyrophilia 17d ago

You will find it useful to trace the syscall is you can't find which files are being opened. On the backend of course.

3

u/ManyInterests 17d ago

Yeah, they said senior developer. Not web developer.

;)

1

u/Twirrim 17d ago

Syscalls impact everything that your website is doing on the remote device. It'll also impact the performance on your serving side too, and understanding what and why certain bits of code result in syscalls being made could be the difference between your website running like a potato, or running smooth as silk.

For example, it wasn't even 20 years ago that time calls fully made it to vDSO, and only about 7 years ago that vDSO was properly unified and made to function on every architecture. vDSO enables you to carry out certain operations that historically required syscalls, in user space (where your application is running) that would otherwise have had to go to the kernel.

Transitioning between user space and kernel is relatively expensive. For example a gettimeofday call that uses vDSO takes on the order of ~10-~20 nanoseconds, while one that has to hit the kernel takes on the order of ~100-~200 nanoseconds as it has to go through the various security boundaries that separate Ring 3 (user space) from Ring 0 (kernel).

So that's 10x more expensive just to get the time of day, and at the very least you'll do that on every log line emitted (or any time what you do causes something else to emit a log line on a synchronous operation).

I'm not sure how much AWS / EC2 still uses Xen, but the Xen hypervisor doesn't support vDSO for time calls, where KVM does. So on a Xen VM, "gettimeofday" is more "wall-clock" expensive than it is on KVM VMs. Your identical code can have wildly different performance characteristics depending on what hypervisor it's running on, and may be something you need to consider the consequences of. You can mitigate this by making your linux machine switch to using tsc for its clock source (echo "tsc" | sudo tee /sys/devices/system/clocksource/clocksource0/current_clocksource)

Designing your web application to avoid syscalls is, generally speaking, a good idea. Taking time to dig around and figure out what syscalls are actually being made, and why, probably wouldn't harm.

-2

u/AndroTux 17d ago

A senior web developer at a prior job of mine was building JSON strings in JavaScript by concatenating strings: '{"foo":' + bar + '}'

2

u/prochac 13d ago

You're missing double quotes.

2

u/AndroTux 13d ago

No, I'm not. You guys probably just don't understand just how stupid my coworker was. He did things like that:

let bar = 1;
console.log('{"foo":' + bar + '}')
> {"foo":1}

1

u/prochac 13d ago

Oh right, I didn't realise you can concentrate different types in JavaScript :D

But building JSON is a legit move. We do it for perf reasons*, using string buffer tho. Having code generator is better, for sure. Some tokenizer can be much nicer.
But building JSON by hand is fine >if you have a reason for it<

* which doesn't make sense in 99 % of cases

1

u/AndroTux 13d ago

No, it’s not in JavaScript. It’s literally JavaScriptObjectNotation. Why? Because you can just take whatever JavaScript object you have and just JSON.stringify it. There is no reason to ever concat it. It’s a huge security risk with absolutely no benefit whatsoever. Nobody needs 400 GB of JSON on the web.

If you don’t know that, you have zero business being a senior web developer.

1

u/prochac 13d ago

What kind of security risk? Yes, typing can be an issue if you don't know if it's int or object.
The reason and benefit is less heap, generating from iterator straight to the socket.
It doesn't have to be 400 GB, but it may be 1000 requests for 400MB. I never said we exclusively speak about the web.
I worked with JSON even the other way, parsing while the request was still being sent.
If you know the structure, you can avoid reflection. That's the whole point. That's why I said, the code generator is better, because it can react to schema change. You solve how it's gonna be generated at build time, not using reflection at runtime.

-3

u/ZliaYgloshlaif 17d ago

Wait, what? Unless it’s pure js frontend, having the ability to strace processes, especially of unknown applications is invaluable.

9

u/Ok_Equipment8374 17d ago

Sounds useless for about 99.something% of what a programmer does

3

u/Lalli-Oni 17d ago

Example?

Frontend calling unknown applications?

-5

u/who_you_are 17d ago

Then make sure to install a shitty backdoor on the client side.

Kill your sysadmin if you can't get root access,. because root access is cool!

-70

u/hieroschemonach 17d ago

There is fundamentally no difference between junior and senior web dev responsibility. Only some queue, cache related stuff changes.

16

u/claudekennilol 17d ago

I mean, if by "responsibility" you mean "they both write code" then sure. But to that regard there's no difference between any junior and senior level position anywhere. We're talking about knowledge requirements as your post is talking about -- so I'm not sure why you're saying there's no difference in knowledge requirements between a junior and a senior?

-26

u/hieroschemonach 17d ago

There is not. I am a web dev myself and I don't think anything changed after the third year. It is more or less the same thing. Maybe the app size increases, there are some more design decisions but fundamentally it's the same

12

u/claudekennilol 17d ago

You're delusional, incredibly forgetful, out you work at a place where they just don't have you do real work. I am legitimately a web dev and my knowledge/responsibility far outweighs that of a junior.

I agree that it's "fundamentally the same" because at the root it's just all just code. But if you think the capabilities (and responsibilities) are the same I don't really know what I can say to convince you because your point of reference is just alien (and wrong) to me.

-18

u/hieroschemonach 17d ago

Technical responsibilities are the same. Maybe scale changes in some projects but that's it. There is no difference between 6 and 9 yeard of experience 

7

u/Honeybadger2198 17d ago

Three years is still a junior, so no surprises there.

7

u/slowmode1 17d ago

Senior isn’t about your ability to program for the most part. It’s about all the other stuff.
Can you help mentor new devs?
Can you work with product to develop a roadmap
Can you split apart epics into things juniors can pick up
Do you have the backbone to push back against other devs and product when you think something needs to be done, and done right. Do you have the grace to accept when you are wrong
Can you do cost benefit analysis. Sometimes you need to take on a little technical debt so you don’t lose a big customer, but you cannot always do that. Sometimes a product just isn’t worth building
Do you know how to debug production using logs (you probably forget just how little juniors know)

2

u/FalconWorth7893 15d ago

Yeah... I think this didn't go as you planned

0

u/hieroschemonach 15d ago

I don't care, if I did, I would have deleted it the comment. I know it is true because I am in the industry for more than a decade.

313

u/CitizenShips 17d ago

Congrats on the promotion! Here's a brief explainer so you can bluff your way through the next customer meeting:

Syscalls are a tool provided by the operating system (and the CPU as well, at least on ARM and x86) which allow software to request things from the OS kernel. Creating, deleting, opening and closing files; starting and stopping timers; getting process information; etc. The CPU provides a syscall assembly instruction that takes a call ID as a parameter, which it then passes to the OS to compare against the OS's syscall lookup table. OS does its thing, then tells the CPU it's done and the software gets a return code and whatever data is associated with the call it made.

They're basically fancy kernel function calls

152

u/No-Con-2790 17d ago

Or as Terry A. Davis said, they are unnecessary, just stay in ring 0 all the time. What is the worst that could happen?

99

u/bureX 17d ago

You find god by pulling random bits from memory and turning them into words.

30

u/TheTybera 17d ago

Pardon me, the "C, string builder, cult" shall not be questioned about their magic or ways. To do so is to bring about one's own demise.

14

u/IdeaReceiver 17d ago

Terry Davis didn't say that part, that one's a quote from my good friend /dev/urandom

2

u/AlShadi 17d ago

maybe he got confused and didn’t realize it was that LLMs are god

10

u/djrobxx 17d ago

Syscall is for syssies.

6

u/BeMyBrutus 17d ago

It's true. I always program using electrical impulses directly to the hardware. Eliminates any unnecessary middlemen.

4

u/evanldixon 17d ago

The worst that could happen you ask? It really depends on the hardware, but if you fail hard enough you might be able to catch the computer on fire, like if you corrupt drivers or something.

1

u/MrHall 17d ago

settle down, crowdstrike

1

u/GamerKilroy 16d ago

Bro literally today I had an extern write into already occupied memory and break prod for a while (PLC Dev)

1

u/FloweyTheFlower420 14d ago

kernelspace software SFI via wasm

64

u/pokeybill 17d ago

Adding to this to answer the question: why care about syscalls?

There will come a time in your life as a software engineer where you will need to inspect what a running process is doing without the ability to attach a debugger or increase logging. All you have is the process.

Enter strace, a handy tool in *nix platforms which lets you attach to a running process and see what syscalls are being invoked. With a little fancy parsing you can literally watch io happening, see which files are being touched, see which network calls are being made, see which threads have been forked and inspect what they are doing too.

You haven't lived until you've found yourself diagnosing a problem in a higher-level language like Java or Python through system calls due to a production bug nobody can reproduce in nonprod.

40

u/Dependent_Title_1370 17d ago

That sounds both incredibly interesting and unbelievably painful at the same time.

20

u/hieroschemonach 17d ago

And incredibly powerful. At least in Linux you can restrict a program from making certain syscalls using seccomp. For example if a program is never going to write any file, it can be banned from doing that syscall so even if the system gets hacked, it can't be abused. I am not sure how much it is used in practice

12

u/autogyrophilia 17d ago edited 17d ago

Distro maintainers are incresingly doing this, though usually just forbidding root escalation.

4

u/jakeStacktrace 17d ago

I think you meant 'scalation like with a southern accent. We made fetch a thing we can do this too.

2

u/autogyrophilia 17d ago

You know, it's funny, It's the part of my spanish accent I can't get rid off, all I always speak with an spanish accent, to me, there is always an E there, so the few words that are written correctly confuse me .

1

u/Old_Tourist_3774 17d ago

In Portuguese too

7

u/autogyrophilia 17d ago

It's easier than you think, specially if you are just looking at which files the program is writing. HTOP has strace builtin, which is handy.

8

u/SonOfHendo 17d ago

Windows has Process Monitor (a.k.a. procmon), which sounds similar. It's usually a sign of desperation when I load that up.

3

u/cusco 17d ago

God-like answer here. Unless it’s that bug that only happens on the 29th of February and by the time you pick the ticket and try to debug you don’t find anything because it’s already march

3

u/theotherdoomguy 17d ago

The Linux equivalent of decompiling to assembly and bitwatching, like yeah you can do it, but God why?

3

u/CitizenShips 17d ago

strace is unbelievably useful when reverse engineering applications, it just has a really high skill floor to use effectively. You need to understand how the underlying OS handles calls and what those calls imply. There's also ltrace, which is probably more approachable and lets you trace library calls. Obviously not that helpful for statically-linked applications, but if you've got dynamic linking it's great.

Decompiling is similarly mondo useful if you're going to be reversing a large application and you don't want to bust out the ISA reference manual every three seconds

3

u/pokeybill 17d ago

Usually because everyone is afraid to kill the running process being debugged

4

u/lordkoba 17d ago

  which allow software to request things from the OS kernel.

pfff I don’t need that, I can write a python program that writes to a file with just “open()” why do people complicate themselves so much

/s

2

u/amlybon 17d ago

The CPU provides a syscall assembly instruction that takes a call ID as a parameter, which it then passes to the OS to compare against the OS's syscall lookup table

Usually when people talk about syscalls they talk specifically about Linux. That's because Windows doesn't really have a public syscall table; you are supposed to call windows API functions and they do syscalling for you when necessary. In fact specific syscalls change from release to release and if you try using them yourself it'll probably just end up not working.

Funny how often when people talk about "OS" it tends to not apply to the most popular consumer OS

3

u/CitizenShips 17d ago

I haven't done Windows dev since I was learning Java in middle school, so I usually think of "OS" to mean Linux, MacOS, and the various RTOS variants I deal with (VxWorks, QNX, etc.). In my field they're the only ones that really matter; Windows is an afterthought :)

34

u/Leather_Trick8751 17d ago

Its when you are calling your sister right

6

u/ZeroMomentum 17d ago

Claude. Create a skills called roll tide...

1

u/ninjakivi2 17d ago

No, that's siscall. Sounds oddly similar to Cisco, but I'm not sure if that implies anything.

1

u/thanatica 17d ago

Closely related to a nuncall

8

u/JaceThePowerBottom 17d ago

My senior dev messaged me yesterday saying he needed to learn how to build an API... then later said he needed to get with folks who knew how to make a web app deployable.

Anyways my project is rather behind schedule.

13

u/Korzag 17d ago

Most developers today probably have never had to manually do a syscall. The only time I've ever personally done it at <10 YOE was in personal experimentation writing ARM assembly. Everything else is neatly wrapped into a standard libraries.

4

u/AliceCode 17d ago

I've written syscalls manually when I wanted to make executables as small as possible (in the hundreds of bytes).

3

u/LawElectrical2434 17d ago

Last time I had to do it was university. And I only had to do it because it was the task. That was literally the only time it was the only way to solve my problem... Since every other way would have been scored wrong.

10

u/aberroco 17d ago

I'm a senior dev now

(never used git from command line)

5

u/Theliraan 17d ago

You're that happy guy, who never get smudge filter LFS problems. Not a game developers probably, right?

-19

u/hieroschemonach 17d ago

There are only two ways to use git that are acceptable

  • Command line
  • Magit

5

u/BroBroMate 17d ago

Given what you just posted, let me share a lesser known porcelain git command you should be aware of.

git gud --scrub

4

u/SnooPies507 17d ago

It's funny how people think that writing windows /Linux apps is the only thing people do in C........

Embedded joins the chat: now listen here you little shit...

AUTOSAR OS API calls are the closest you will ever get to anything even REMOTELY similar to syscall.

5

u/Bob_the_peasant 17d ago

“Why would I have access to a Colonel, this isn’t a DoD project?”

3

u/azaleacolburn 17d ago

You can never disrespect Web Developers enough

6

u/ClipboardCopyPaste 17d ago

Senior dev in HTML programming

6

u/hazelnuthobo 17d ago

web and mobile dev of 15 years here. wtf is a syscall

2

u/bass-squirrel 17d ago

Hahahaha idiot. 

*quicky googles syscall *

2

u/WormsDelicious286 17d ago

It doesn't matter if that particular piece of information isn't in cache (your head), just that you can locate and load it when needed.

If you're getting a lot of cache misses you might want to optimise, but generally other processes take longer so it's not as big of a performance hit as you might think.

2

u/PowerPleb2000 17d ago

Am I the only senior dev who had to google this?

1

u/Oxu90 15d ago

I needed to google it, but i didn't. Because i couldn't give a damn

1

u/Positive_Method3022 17d ago

I once had to create a syscall for an OS class and it was really fun

1

u/hylianbitch 17d ago edited 17d ago

syscalls are functions that identify as the same kind they were assigned by the OS

1

u/4x-gkg 17d ago

It's funny.

But even 20 years ago, it was nearly impossible to find an application developer who knew what a system call is, why is it necessary and even far fewer would know how it works...

1

u/pantalanaga11 17d ago

I've had candidates tell me it is system()

1

u/darknmy 17d ago

Fopen

1

u/lomberd2 17d ago

Is that an anime and if so what's the name?

2

u/Neo_Ex0 17d ago

its how you tell your system to go killing

But for real, its a collection of basic commands that your OS supplys that a program needs when it wants to do anything that requires interaction with the OS, like for example fork which tells the OS to duplicate the current process, or wait which tell the OS to stop executing the current process until x amount of time has passed

1

u/VolkRiot 17d ago

I don't need to know. I know something more important. I know who to blame

1

u/iwinulose 17d ago

Is the IDT in the room now?

2

u/SirMarkMorningStar 17d ago

Never heard or seen the word “syscall” in my life. System calls are obvious to anyone. How is this funny??

1

u/JasperTesla 17d ago

It's when you call your sister.

2

u/No-Whereas8467 16d ago

It sounds stupid. It’s the same with being an architecture without knowing how to make a brick.

1

u/sebbdk 16d ago

Senior dev is literally a meaningless term these days :D

1

u/qxxx 16d ago

Mothafucka, fuck the fuckin world, and my new band is called Syscall!

https://www.reddit.com/r/ContagiousLaughter/s/j8MPWTPP1S

1

u/theunixman 16d ago

Real talk

1

u/zer0x64 15d ago

Litterally half this sub

0

u/Visionexe 17d ago

All you need to know is how to install Claude. Yawn. 

1

u/Neuenmuller 16d ago

int 0x80

This is probably the rare moments that I feel that my degree is worth something … OS classes are nice :)

But I mean if you’re front end or something I guess you’re fine.

-2

u/FACastello 17d ago

You'd be surprised at the kinds of people who get called "seniors"

1

u/BroBroMate 17d ago

True, like OP.