Details
-
SkillsC/++ Arm/Intel Assembly Embedded Systems Linux
Joined devRant on 11/22/2018
Join devRant
Do all the things like
++ or -- rants, post your own rants, comment on others' rants and build your customized dev avatar
Sign Up
Pipeless API
From the creators of devRant, Pipeless lets you power real-time personalized recommendations and activity feeds using a simple API
Learn More
-
It's the indexing that kills me every time, c_array[0] == lua_array[1] ...
-
Do you have tempfs activated and some application is dumping a load of files into the /tmp-Folder?
My rookie mistake with my first Linux was to unpack a bunch of files into /tmp and wonder why my ram shot up like that -
Just stay away from people trying to push Javascript for everything other then webstuff. They are usually deadly afraid of strongly typed programming languages.
If you truly understand C and how the compiler turns that into machine code, you pretty much can learn any other language. It's just memorizing the idiosyncracies of the new language.
I've been suggested to try out Rust overwhelmingly, even for embedded purposes.
If you, however, learn a language for learning sake, then I guess that it wouldn't hurt to diversify. Else use the language that seems most effective for the certain project. -
I'm an ardent believer in "the right tool for the right job". Javascript is great for webstuff, as it was originally created to enrich it.
Using JS for standalone desktop applications? Still can't understand the need, when we have so many established and arguably more efficient languages to use.
The only aspect I get however is the ease of understanding JS. This is imho the very best thing JS ever brought us: A low starting difficulty for peeps to learn it. Even kids can cobble something together using it, as I did back in my days. It's a gateway-drug for programmers.
My gripe is that most people don't know how to think algorithmically, partially because they never learned how the low-level stuff works. That is okay in the web-world, as you don't want to have less abstract things to worry about. Using a language for things it was never envisioned for just brings in new problems with more complex environments to support it.
Right tool, right problems. Don't be a tool, use Assembly. -
ARM Assembly all the way, with x86 coming as a close second.
I dunno, I just love how structured and simple arm asm can be and the fact that I don't need to do stupid jumps for a line or two of conditional commands is just <3
But don't get me wrong, Intel has some pretty nifty commands that do like a gazillion things in just one cycle (however you want to define a cycle).
The next layer up would be C. Yes, it takes 10x more lines of code to do a simple thing compared to any scripting language, but I like my power that I have with C. The instant you try to take away my power to dereference an arbitrary address that I previously declared to be anything the fuck I want, is the moment I lose interest in that language. C++ comes dangerously close to that threshold with some default compiler warnings though... -
Yes sry but HR wants to read all the Bling-Bling buzzwords to even consider giving you a chance to explain yourself.
So if you have to list all the buzzwords, you obviously do it. Most of the time you wouldn't even need a fraction of those in your day to day job.
Everything to get me an interview appointment with a lead dev, before who I wouldn't lie for obvious reasons.
Current hot buzzword: AI -
The sad thing is: most of the bachelor-graduates of cs can't even code, all they can do is copy-paste stackoverflow-answers.
So, yea, I wouldn't call myself a chef just because I can cook a mean omelette. -
Easy.
Everything that is labeled as bad practice because it's a gcc only thing.
Makes me rock hard if it's particular to a specific version of gcc. -
Happens to me all the time because I left the wrong Target-IP in my debuggers' settings and was debugging an application on a device nothing was connected to.
The first time this happened I had to enlist two other devs to help me out and after 1~2h later we even began desoldering microswitches because we thought it was a hardware problem.
Until someone noticed the LEDs on a device at the far end of the room light up every time we started debugging.
🤦♂️
We vowed to never talk about that ever again to each other. -
@M1sf3t
My former professor once called that "Flashlight-Debugging", as to you are in a dark room (Blackbox) and the only way to discern your bearings is to flash a light here and there in Hope of finding the exit.
Using text output as a way of debugging. That hurts my head. Immensely. -
I don't know man, in my more than 10 years of Programming I've never once been bound to use M$ Office products, as I had LaTeX for my documents.
Never had to work with customers who were hell bent on using MS Products either.
So making Office the biggest issue on why not to use Linux seems very obtuse to me.
And what usability or user experience goes, MS can't even come close to what I can do in Linux or how I can change the experience to my liking from the most basic things to the most complex ones due to the customizability of Linux distros.
The compatibility stuff on different platforms. Yes, that could be better. Different packagemanagers do make it hard to manage dependencies.
Then again, I prefer to have just ONE copy of the same library in my system opposed to either static copies in the deployed application or a redistributable (which destroys the compatibility claim all together).
Why use Linux? Ask that the peeps that do server or low-level stuff. They'll tell ya. -
Instead of
#include "header.h"
use
#include <header.h>
and change the include-paths in the projects settings (cmake/make) according to the current platform.
As long as the header-files are named the same, all you have to do is change the path to them.
In gcc the corresponding flag is -I. -
Just waiting for someone to post a link to or just outright invent an esoteric programming language called "cancer", so we could end these discussions.
Everybody knows that Assembly is the way to go.
Pff, people with their "variables" and typesafety and whatnot... -
Debugging challenges you to slow down and think step-by-step, going down to the variables, threads and hardware and how they interact with your code.
That's quite technical.
Most people loathe technical stuff.
And if you pair that with bugs that force you to open a memory view of your objects or - God forbid - the assembly-code, then people will freak out.
I keep observing that pattern in 4/5 devs I encounter. -
I'm pretty sure that these cringy programmer-speak-merchandise-thingies are either made by non-programmers or just god-aweful ones, the likes you'd immediately fire after their first code-review.
-
Yep, did a similar rant few days back, but the impact of -O is just magic.
I mean if you check the assembly code produced with -O0, you'd see that almost every line of code actually accesses the memory even for the most mundane things. That slows down your programs by a friggin lot.
One more reason why I can't part with C/++ <3 -
@dakkarant
I don't really understand what power refers to here.
If it's speed and/or memory usage, C++ quite easily stomps NodeJS into the ground. Less Cpu usage overall for same task. Sure, way more code to type to get the result.
Everytime someone claims that "this or that language is as fast as C++", I usually check several benchmarks.
It never holds true. Never did.
Disclaimer: I personally don't even like C++... -
@Ranchu Well I only ever used it with gcc, so I wouldn't know if it works with other compilers - at least with this specific flag.
I'm pretty sure that all C/++ compilers worth their name have some sort of optimization routines built in, one just has to find out how to use them.
Microsoft's has it, as you can change it through the properties of the project or with the corresponding flag (I think it was /O).
Another tidbit: When using an IDE without a makefile, usually choosing Debug-Mode will compile with O0 and choosing Release-Mode will compile with O3. You can spot this in the compilers' output :) -
@Ranchu correct, you can specify an optimization-level (-O) with which the compiler tries to optimize for a specific goal (using less memory, faster code, smaller [code]size etc).
Well, at least can with gcc and mvc, guess llvm does support it as well, not sure though.
Higher levels can lead to bugs if you like to use aliasing or type punning though, so most devs are discouraged to even use them (according to the "if you don't know what it does, don't use it" addage).
Only works if you have access to the compiler flags though. If you're in a project with a makefile managed by someone else, it gets quite exhausting to argue about compiler flags....
And don't get me started about the volatile keyword. Even less devs know about it and when and how to use it. But I guess it's embedded specific so it stands to reason that it's not known by many :) -
#1 dev tool with a slightly better user rating then "meh".
Way to go! -
Well at least they were lucky they used a signed integer type instead of an unsigned one.
And with lucky I mean lazy. -
Wow, first of all: thanks for all the helpful stories! It's really interesting hearing from people being in the field and what they had to endure.
I do have an intimate relationship with Oscilloscopes, as I had to hw-debug a lot of chips with no real documentation. Had to rely on LEDs to show me states more often than I would like.
I can read schematics of circuits just fine, would struggle to engineer my own pcb's though.
I really wasn't considering avionics, trains etc, those fields really skipped my mind. Now that I think about it, those are prime examples where you need people with special knowledge.
At one time I considered going into robotics, as I did several projects with industrial robot arms.
Has a good mix of low level programming, ee, applied maths and my love for big, powerful tools that can snap your neck if you accidentally swapped the axis in your program.
I guess my problem is the fact that I did too much and can't decide what to specialize in my specialization. -
Ah c'mon people, it's not that hard!
All you have to do is pressing the escape button on your keyboard, typing in a colon, slitting your arteries open to use your blood in a satanic ritual to summon an ancient demon to grant you immortality as you'll need it to figure out how to exit vim.
Wasn't so hard as it's made to be, rite? -
I just registered only to express my heartfelt chuckles :)
Considering the low comment count, it seems we don't have many ranters with intel x64-assembly knowledge in the house? Or do we just have a weird sense of humor?