HNHacker News
TopNewBestAskShowJobs

rafa1981

18 karma · joined September 1, 2019

submissionscomments
rafa1981··on US plans to produce ‘Iberian’ ham in Texas and Georgia
If Texas has acorn, grass and a low humidity climate year around where the hams can be dried in optimal conditions, I can't see why they wouldn't succeed.

This is just about salting the right ham type and letting it dry at the right conditions. Not exactly rocket science.

rafa1981··on What we can learn from the 1918 flu pandemic
If he ran two marathons in one week then he was weakened/unrecovered IMO.
rafa1981··on Show HN: libcodr7 – fundamental collections in the spirit of C
Obviously not
rafa1981··on Show HN: libcodr7 – fundamental collections in the spirit of C
Intrusive lists are very different beasts than lists by value.

There are less allocations involved (perf and points of failure), values can be inserted on different lists without new allocations, deletion is O(1), elements can be heterogeneous (different sizes and types), etc

etc

I seldomly use linked lists, but most of the time i prefer them to be intrusive. There of course are intrusive list implementations on C++.

rafa1981··on Browser-based climate change simulation
Fighting environmentalv issues with extra consumption may not be a good idea. Manufacturing a vehicle pollutes a lot. Up to 50% of the enviromental costs of a vehicle seem to happen at manufacturing time.

https://archive.attn.com/stories/13637/hidden-environmental-...

rafa1981··on Browser-based climate change simulation
That we are polluting is beyond doubt. Deforestation, mining, nuclear accidents... all these are real problems that need no additional backing science or guvernamental panels, yet they hardly get the spotlight in mass media compared with Co2 levels. Co2 is reported as the worst problem by politicians to scare us, make us feel guilty and pay.

The degree of overconsumism rooted in our system is hardly environmentally friendly. Yet we want to be environmentally friendly by consuming a new generation of Co2 friendly products, which polluted the planet to be manufactured.

Consuming is the problem, not the solution, but who is going to say in a capitalist system backed by fiat money that is only sustainable by an ever increasing debt that we need to have negative growth and lose some comfort to decrease our footprint?

rafa1981··on Yocto: Tools for building a custom embedded Linux distribution
Example: PACKAGE_native_append += "something". "append" is a keyword, but the "native" is just a separate list of native packages, yet both are appended to a variable name separating it by underscores. They use the same "syntax". If my memory serves me correctly, if not in this example "+=" is required sometimes after "append", even if they seem redundant. Someone politely explains you why this works as it does, it makes sense, yet you wonder why you need to hit a gotcha when all you are doing is something as simple as adding an item to a list (as a space separated string).

And then the metadata is also funny, e.g. do_patch[depends] = "whatever:do_populate...". Variables are not just variables, they can contain metadata, sometimes important.

It feels like there are usage patterns, good practices and something more beautiful wanting to get out, but this is a domain where making a better build tool would break tons of recipes, so it feels like everytime they got a problem they added a quickfix and got forward without looking back.

The steep learning curve most of the time is unneeded, you are frenquently doing trivial to simple taks and hit one problem that gets you blocked for a while for things that you are easily able to do outside Yocto.

It is a shame that the good work they do is spoiled by the horrible "interface".

rafa1981··on Basic Social Skills Guide (2012)
Some people downvoting you may be lacking skills to detect that this, even if partly true, is a joke. For me it was good.
rafa1981··on Show HN: LuaJIT assembler/assembly language for direct bytecode programming
Notice that if I remember correctly, you can generate bytecode on the PC (by using the luajit command) and have the resulting bytecode loaded through the C API on your device as if it were a regular script.
rafa1981··on Show HN: LuaJIT assembler/assembly language for direct bytecode programming
I don't know if luajit runs in your device, but vanilla luajit supports generating and loading bytecode.

https://luajit.org/running.html

rafa1981··on We Stood Up to a Patent Troll and Won
I know about a small western company acquired by a big Chinese multinational where Linux firmware devs are working on Windows boxes with no internet. Firewalled.

The company policy is to not allow internet on machines connected to the company network. They say that it is very typical on China for companies to try to atract workers from the competition, and these take with them not only know-how, but internal files from the company they leave too. Hence the firewalling.

It's ridiculous because I'm speaking of consumer electronics, not the military. The team morale is super low because they are fighting against the environment, not the problem they want to solve.

Maybe they only want to crash the western subsidiary and get the prestigious brand name(?). Anyways it seems that they are getting a taste of their own medicine.

rafa1981··on Spleeter: Extract voice, piano, drums, etc. from any music track
Maybe the source was compressed audio instead of flac/wav?

Edit: the source is an mp3, which removes audio frequencies based on perception/masking with other frequencies. It's perfectly normal that it is showing artifacts. A better source is needed.

rafa1981··on Stuxnet was embarrassing, not amazing (2011)
Exactly. If it did the job why showing the enemy (and the world) all your cards, so they can learn your most advanced tricks? It's better to keep some advanced techniques for the next target than to expose them with no need.
rafa1981··on Opinion: Standard Time all year round is the healthy choice
The human and animals, when in nature, follow the night/day cycles, not an artificial clock time meant to synchronize an industrial society. IMO it's fine, and even natural, to have different time on winter and summer, but why does the change be one hour on every country and why changed all at once?

If health is the goal, e.g. a 20 minutes change each two months seems much easier to adapt to.

rafa1981··on NanoLog – a nanosecond scale logging system for C++
I did exactly the same on my two loggers, as a C literal is always read only and unique, passing a printf-like string is passing a pointer.

The it's just a matter of adding validation and passing the arguments in a compact way.

rafa1981··on NanoLog – a nanosecond scale logging system for C++
But worst case latency, the most interesting property of an async logger is still unaffected I guess...
rafa1981··on NanoLog – a nanosecond scale logging system for C++
Lack of knowledge on glog
rafa1981··on NanoLog – a nanosecond scale logging system for C++
Author of mini-async-log and mini-async-log-c here.

https://github.com/RafaGago/mini-async-log

https://github.com/RafaGago/mini-async-log-c

I wrote both some time ago and AFAIK they were the fastest, how does nanolog compare against them?

At least before the source file preprocessor Nanolog was slower.

Here I had a benchmark project with Nanolog on an old version, maybe you can PR an update:

https://github.com/RafaGago/logger-bench

rafa1981··on NanoLog – a nanosecond scale logging system for C++
Author of mini-async-log and its C variant here.

Some time ago I wrote a benchmark for different loggers, but it uses an old version of Nanolog.

https://github.com/RafaGago/logger-bench