Details
-
AboutStudying Theoretical Physics
-
SkillsC++
-
Github
Joined devRant on 5/16/2017
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
-
Most of the code I write nowadays is for GPUs using a dialect of C. Anyways, due to the hardware of GPUs there is no convenient debugger and you can't just print to console neither.
Most bugs are solved staring at the code and using pen and paper.
I guess one could call that a quirk.11 -
You know your codebase is fucked beyond restoration when a one-dimensional array is indexed using two indices and this formula.
FUCK.8 -
The c++ 'Eigen' library. It is by far the best library if you're in need of maths constructs, speed wise. And the only maths library that has an API that isn't a pain to use.6
-
IOS 13 for my Ipad broke its battery indicator it's been stuck at 59% for the entire day. Just really hope it doesn't give up the ghost during the day...1
-
"Sorry, I heard you're good with maths can you just derive that equation for me real quick?"
90% of what we do is maths why are you here?2 -
Margaret Hamilton.
She was the director of the Software Engineering Division which developed the onboard flight software for NASA's Apollo space program.
(Here Wikipedia)
https://en.wikipedia.org/wiki/... -
Tl;Dr:
The new windows subsystem for Linux might severely slow compilation time for me.
Microsoft is releasing a preview of WSL 2 which works fundamentally different to WSL 1, which I currently use.
For those who don't know, WSL (or Windows Subsystem for Linux) used to be a compatibility layer, which "translated" Linux syscalls to Windows syscalls. This enables the execution of Linux applications on Windows. The new WSL (WSL 2) doesn't do any of that, instead, it is a highly optimised Virtual Machine.
So don't get me wrong from a performance point of view there is no Issue, RAM and CPU usage is truly astonishingly small and performance of Linux applications is much improved over WSL 1.
BUT, apparently, accessing files stored on Windows through Linux is now piss slow.
Great, truly outstanding.
Why is this a problem? Well, I use WSL to develop c++ Linux applications using CLion, the way this works is that you set up an ssh server in WSL, which CLion uses to do compilations.
One _needs_ to have the project files stored on Windows as otherwise CLion on Windows can't access them.
If I wanted a Linux VM I would have installed one.
Urgh.13 -
I've just managed to add the ability to call functions to my compiler. Currently, the capabilities are rather limited but I am pleased with it.
It keeps the schematics of the source code well enough that it can handle
recursive calls.
:D
On the Image, you can see the program's output (left), the generated x86_64 assembly, and the source code of the compiled program (bottom).6 -
Is anyone here living/working/studying/frequenting Singapore?
If yes, where you so kind as to explain why it is a good/bad place to study?1 -
I guess today I'm ranting about x64. I don't have any screaming into the void stuff but I am unhappy that some instructions can't have 64bit immediate
Really annoying.
That's all
~ cheers -
me: alright let me print this now.
*goes downstairs*
printer: *on the display* ... Printing ...
printer: *on the display* ... Printing ...
printer: *on the display* ... Printing ...
*no paper to be seen*
me: why isn't this working?
*checks computer upstairs.*
computer: *popup* We have an update scheduled for 17:40, we can install it then or, if you like, now.
me: oh, ok.1 -
Electron is so heavy on ram usage that they should just rename it to tau. Electron apps are also unstable so that would work too.4
-
I guess I'm taking the piss.
I just spend half an hour wondering why a unit test failed; turns out all calculations were done correctly, just that -5 + 3 was being calculated and the test expected the solution to be -1.
Well, -5 + 3 does not equal -1 and I'm too stupid to add.
Half an hour. (-_- )2 -
*Starts compile*
...
...
can't find function foo
ld exited with status code 1
*confused*
*Reruns qmake*
*Compiles again*
...
...
can't find function foo
ld exited with status code 1
*very confused*
*switches compilers*
*compiles*
...
...
Worked!
*dafuq*
*switches back to the first compiler*
*compiles*
...
...
Worked!
*tries not to cry*12 -
Allright, to settle a debate what is the more incorrect way of getting the last elememt of a std::vector?
Is it this:
auto i = myVec.at(myVec.begin() + myVec.size() - 1);
or:
auto i = *(&myVec.at(0) + (myVec.size() - 1));
I think the second method is better(worse) because it has more brackets and only works on Implementations where the vector's data is laid out concurrently (that is in the c++11 spec, but I've seen some shit)
My friend argues for the first method because it takes more time. (If IO is not a bottleneck)1 -
* Find something you don't really know or haven't used in your language of choice
* Push that feature in your architecture
* write shit code because the feature really shouldn't be there -
Screw the German Telekom!
I recently got a new home without internet so naturally, I went to an isp, Telekom. I went there a few weeks ago and was pleasantly surprised by the personal and the general competence. He told me they would send a technician to check my cable. So I thought great and went home. 1 A week passes, nobody shows up. I then went back to the shop and asked(someone different). He basically told me that such a service must be specifically asked for and a contract has to be signed. I then told
him his colleague told me no such thing, and that the technician should have checked up on my connection last week. He excuses him self and I signed the thingy.
Now you would imagine that this would have worked.
but.
NOOOoooo.
A week came and went and I got pissed. So I went back to the shop the guy from the first try was there. I Asked what happened, he types in his Computer. and. and. and. nothing. Apparently, the previous guy forgot, fucking forgot, to enter my request to their bloody System.
Now I asked if I can Just become a customer.
Guy: Sure, what speed is available in your region?
Me: I don't know...
Guy: Let me check
/Type/ /Type/
Guy: I can't see your speed the technician should have checked.
Me: Um, so, can he check?
Guy: Clearly you don't know what you want
Me:???
Guy:*leaves table*
(shorten but you get the Idea)
At this point, I really wanted to change isp so I went to Vodafone.
Lady comes up to me asks me a bunch of stuff and I explain I would want to change my phone, internet, tv, mobile and my friends mobile(I lost a bet once ^~^) to Vodafone.
What happened next I can't really explain, but she talked to her boss and "cheated" (how she calls it) on Vodafone and got me an AMAZING deal it is cheaper than Telekoms has waay more mobile data, faster Internet and I got a new phone :D.
And guess what she could fucking check, fucking check from here Computer my max internet speed.
I can only hope that the lady got a big fat commission for what she has done.6