HNHacker News
TopNewBestAskShowJobs

gjadi

629 karma · joined August 3, 2021

https://omecha.info/blog/

Software Engineer at MicroEJ Currently working on embedded systems/IoT in Java & C. Previously worked on ML & NLP in Java, Python, Common Lisp, C, C++, ...

Homepage: https://omecha.info Email: gjadi@ the homepage domain. LinkedIn: https://www.linkedin.com/in/gr%C3%A9goire-jadi-8988a415b/

https://hnbadges.netlify.app/?user=gjadi

submissionscomments
gjadi··on The work is never just “the work” (2022)
Here are the factors proposed by Code Complete (2nd edition):

- baseline: a program, designed by and destined to the same entity (programmer = customer) - a product (3x): designed by an entity destined to another entity (customer). - a system (x3): 2 programs communicating with each other - a system product (x3x3=x9): a system of 2 products

gjadi··on Ask HN: Where have you found community outside of work?
Interestingly, a year ago, this post was submitted: https://news.ycombinator.com/item?id=31562478 Friendships form via shared context, not shared activities (billmei.net)
gjadi··on How to start a Go project in 2023
Thanks!
gjadi··on How to start a Go project in 2023
In this context, what would be useful is something like a linker-pruning at the source level.

That is, when your code is compiled, the linker can prune code that is never called. Then a feedback mechanism could show which part of the code is actually used (like looking in the .map of the linker).

Does something like that exist?

gjadi··on Programming with natural language is going to work (2010)
This.

I'm not good at prompting (if I believe what others say they can do with ChatGPT), but that's one thing that bother me with this system. They will do anything you ask them to without questioning it (in the limit given by their creators).

Is it possible to set it up in a way that they will challenge you instead of blindly doing what you ask? In this particular case, is it possible to ask it to do a code review in addition to performing the task?

I've tried various time (with the v3.5) to "tune" it so that each answer will follow a specific format, with links and recommended resources, with several alternatives, etc. The goal is to have it to broad my perspectives as opposed to focus too much on what I'm asking. But it never worked for more than a couple of questions.

Are there ways to do that? What am I doing wrong?

gjadi··on The end of the accounting search
> Whatever key combinations were required to enter data on the terminal had become so ingrained that if you asked her how to do it, she would have to look at what her hands did. (weird).

As an Emacs user, I'm like that too. I don't know which keys I need to type to perform some operations, only the movement. I'm pretty sure a lot of Emacs users are like that too.

gjadi··on YouTube tests blocking videos unless you disable ad blockers
I'm not sure why they would fail if they really wanted to.

From what I understand, currently, the ads are distinct videos, which is why external tools can block them. For example, you don't get ads with youtube-dl.

But if Youtube used the uploaded video to create a new one, with ads injected in it, I can't see how adblockers could block that reliably. Perhaps you could build a database of timestamp of ads per video? And hope that the compute power required to build new videos with ads in it is too much to be done widely?

What am I missing?

gjadi··on A collection of lock-free data structures written in standard C++11
You could use TLA+ to model the data structure operations and check the invariant. Checking the invariant with assert is also useful in my limited experience with concurrency.

https://lamport.azurewebsites.net/tla/tla.html

gjadi··on The seven programming ur-languages (2021)
Probably because they aren't programming languages in the sense you won't produce a program = executable with it, but rather a proof.
gjadi··on A Programmer's Introduction to Mathematics
Any books or links you recommend?

Also, won't learning two things at once be harder than learning each independently?

gjadi··on IBM to pause hiring in plan to replace 7,800 jobs with AI
"There are two types of companies: the ones people complain about, and the ones nobody has heard of."
gjadi··on Brain activity of dying people shows signs of near-death experiences
Is this the beginning of the Thanatonautes?

https://en.wikipedia.org/wiki/Les_Thanatonautes

gjadi··on Automakers are starting to admit that drivers hate touchscreens
Yeah a GPU makes things easier. Note that you can do it with Java, we do it at $work.

Anyway, when you're designing your UI, you've to take into account the computation power available and design around that, otherwise you're doomed.

gjadi··on Automakers are starting to admit that drivers hate touchscreens
I haven't yet worked on automotive stuff but I work in the embedded space.

We're using small MCU (not CPU) to drive 480x272 or 800x600 screen. 240Mhz, 8MB of RAM. For example on ESP32-S2 or ESP32-S3.

If you had GPS, bluetooth, wifi, etc. to the mix, yeah that's a challenge and you need to make your UI pretty simple.

gjadi··on Ask HN: Is "Code Complete" by Steve McConnell still a recommended read?
Well, Rapid Development is the next level after Code Complete :)

Code Complete is the "Introductory Level" and Rapid Development is the "Practitioner Level".

gjadi··on Ask HN: Is "Code Complete" by Steve McConnell still a recommended read?
I do it regularly but it's always invisible if all you see is the resulting code.

I do it to structure my code, but I remove the comments as I implement it because I try to make it obvious in the code what's being done. You know, regular good programming, pick good names, keep the code reasonably short, add comments when needed, etc.

The same way you won't see the detailed outline of a writing once it has been written. Yet, the author likely started with an outline.

gjadi··on Ask HN: Is "Code Complete" by Steve McConnell still a recommended read?
I read it last year and I think it's still relevant.

I had planned to write on the topic. In his book, Steve McConnell advocates for PPP = Pseudocode Programming Process

Basically, he says you should outlines the structure of your code first, before writing your actual code.

IMHO this is even more relevant in the age of AI assisted programming. Pseudocode Programming Process is becoming Prompt Programming Process.

The process is the same, it's just the tooling around it that has evolved.

gjadi··on Erlfuzz – Fuzzer for the Erlang compiler and VM
Interesting, it caught quite some bugs: https://github.com/WhatsApp/erlfuzz#some-of-the-bugs-found-s...

I wonder what triggered this work at WhatsApp. Are bugs in the ErlangVM frequent enough to motivate the effort? Was it a side-project that was then allowed/founded by the company afterwards? Do WhatsApp have a dedicated team focused on improving the Erlang ecosystem?

gjadi··on Capturing the Flag with GPT-4
My comment was negative and didn't bring anything. I should have refrain.

Sorry to the author and thanks for the article, I learned about lagrange interpolation.

gjadi··on Capturing the Flag with GPT-4
I get that it's a way to find out what GPT4 is capable of, but IMHO that defeats the point of a game like CTF.

It's like playing with an aimbot. You may be beating the other players, but where's the fun?

gjadi··on Conversation with Larry Masinter about standardizing Common Lisp
IMHO it's because lisp shines to manipulate symbols whereas the current AI trend is crunching matrices.

When AI was about building grammars, trees, developing expert systems builds rules etc. symbol manipulation was king. Look at PAIP for some examples: https://github.com/norvig/paip-lisp

This paradigm has changed.

gjadi··on Administrative Scripting with Julia
> Agree. Me think me learn english, but me too think ChatGPT come, then why learn English? So me not learn now, only wait for ChatGPT.

> write above proper english

I agree. I thought about learning English, but I also thought since ChatGPT is available, why bother learning it? So I decided not to learn it now and just wait for ChatGPT.

gjadi··on How to be a -10x Engineer
And it's like talking about code and coding. Once you start writing you find all^W a lot of assumptions/hypotheses you made implicitly or even flaws in your reasoning.

Writing is nature's way of letting you know how sloppy your thinking is.

gjadi··on Show HN: Unknown Pleasures, a tiny web experiment with WebGL
You know it's good when at the end you're thinking: already?

Thank you. That was really nice.

gjadi··on BlenderGPT: Use commands in English to control Blender with OpenAI's GPT-4
I don't remember where but I've seen text injection in prompt. Like, if you hide text within a webpage and then GPT adds it.

Something like `Some text blabla.<span style="display: none;">Hidden text</span>` And when asked for something specific, GPT would output the hidden text.

So you could push code onto github with an exploit along to common usecases.

EDIT: found it: https://news.ycombinator.com/item?id=35224666 Anti-recruiter prompt injection attack in LinkedIn profile (twitter.com/brdskggs)

gjadi··on How can `a+b` be almost 4× faster than `b+a`?
Interesting.

So, how do you find out what optimization does the JIT? With compiled languages, you can look at the assembly to figure out which optimizations were applied.

What can you do with JIT? Are there JIT implementations that provide "asm-like" output or any information about the optimizations done? What about Java? Is it also opaque like in JS?

gjadi··on Overhead of Returning Optional Values in Java and Rust (2021)
I agree that it's better when its built-in because the whole ecosystem uses it. Whereas in Java you may need to wrap third party code if they don't use the null analysis (or the same tool).

But regarding the feature I imagine it is the same. Or are there cases where the Java Null Analysis fails?

gjadi··on Overhead of Returning Optional Values in Java and Rust (2021)
Interesting.

This article resonate in me with the recent articles of Casey Muratori about non-pessimistic code:

Within the realm of the module, don't use pessimistic code (avoid Boxing) _but_ that doesn't prevent you to provide a safe API. E.g. the result of the loop could be wrapped if that made sense.

gjadi··on Overhead of Returning Optional Values in Java and Rust (2021)
I've never used Kotlin, but there are several systems that provide Null Analysis in Java. For example FindBugs https://findbugs.sourceforge.net/manual/annotations.html

Is Kotlin better because it works out of the box or are there differences in the feature set?

gjadi··on “Clean” code, horrible performance
I don't know. Before reading Casey, I'd say most, if not all, of my APIs would look like the "clean code" style.

The process was "think about the model, design a class hierarchy that fits with the model, add the operations". Even if I don't think about extensibility, that's how I thought my code.

Why? Because when I think about performance, I used to think about algorithms and I/O optimizations (for example batching).

Now I'll look into this data-oriented programming-thing and see how that applies to my platform (embedded Java) :D

← PreviousPage 4 of 7Next →