Hacker News new | past | comments | ask | show | jobs | submit | gudzpoz's comments login

> Emojis are terrible

Not just emojis. Recently I've had some fun trying weird Unicode characters in different terminals (e.g. š’«):

- QTerminal/Konsole: Tofu

- Xfce terminal: Results in overlaps with characters that comes after it.

- Alacritty: Similar to Xfce terminal, but glitches when the cursor/glyph moves.

- COSMIC term: No overlapping glyphs, except that the line then wraps only after it grows out of screen.

- Kitty/WezTerm: Scales the glyph to fit it into a single column. (Barely legible.)

I don't even known what to expect. It is indeed a mess over there.


I once tried to use sql.js [1] on a static site for full text search. It worked, but the resulting database size for that site was too large for the web, even with things like detail=none and content='' applied, and requiring the user to download a database each time was just no go. (I guess things should work better for sites with less content or those not requiring a trigram tokenizer.)

I switched to Pagefind [2] afterwards before finding out a sql.js-httpvfs [3] fork of sql.js that removes exactly the need to fully download a database (with HTTP range requests). I haven't got the chance to test sql.js-httpvfs out though, but it looks pretty sound and could be much more flexible than Pagefind. (Previously discussed at https://news.ycombinator.com/item?id=27016630 .)

[1] https://github.com/sql-js/sql.js/

[2] https://pagefind.app/

[3] https://github.com/phiresky/sql.js-httpvfs


I've been wondering if these magical registry things are documented anywhere... Searching, for example, "site:microsoft.com DisableSearchBoxSuggestions", only leads me to tons of forum posts.

I would love a configuration system with centralized database and centralized documentation, but no OS currently seems to be able to achieve that, and Windows' missing documentation appears even worse than obscure but documented config files.


NixOS system configuration is centralised and documented.


The GIFs look good and I like how it lets the user diff between original code and AI-generated ones. But still, I would like to quote from an article on Thread (well, this Thread is a network stack) [1]:

> No, seriously. Can we please not name new things using terms that are already widely used? I hate that I have to specify whether Iā€™m talking about sewing, screwing, parallel computing, a social network from Meta, or a networking stack. Stop it.

[1] https://overengineer.dev/blog/2024/05/10/thread/#user-conten...


Hahahah point taken, in all fairness, I only knew about Threads (the social media app) when I posted and so I thought it wouldn't overlap. I was worried the word `thread` might overlap in a parallelism sense though wasn't aware of the networking stack. Anyways I appreciate the feedback :)


    git diff -U --word-diff --no-index -- <(curl -s https://www.gnu.org/licenses/gpl-3.0.txt) <(curl -s https://tom7.org/bovex/JCOPYING)
It seems some sentences are totally trimmed off though. But otherwise it is really a sweet, sweet eye candy.


Posted 10 hours ago:

Llama3V is suspected to have been stolen from the MiniCPM-Llama3-v2.5 project - https://news.ycombinator.com/item?id=40559746 (6 comments)


ah nice, did not see this because I searched for `llama-3-v`


> ... but Lua still creates issues now and then. Like if you forget return, the return value is that of the last expression.

Is this true? Or was it true for some Lua 2.X versions? Because it does not seem to be the case for Lua 3.0 and on: [1]

> If control reaches the end of a function without a return instruction, then the function returns with no results.

As to the idea of using an emulator for scripting, it seems a bit similar to approaches using WebAssembly. But looking into the benchmarks [2] provided by libriscv, it is quite interesting to see it outperforms luajit and wasm3 (in its "hand-picked" tests, at the very least).

[1] https://www.lua.org/manual/3.0/manual.html [2] https://github.com/fwsGonzo/libriscv?tab=readme-ov-file#benc...


I've forgotten `return` plenty of times and to the best of my recollection it's always returned `nil` to the caller.

Maybe he's talking about something else than pure lua? Something with the game's bindings?


Maybe I'm old now. I'll remove it from the article! Reading back on it, it seems like I'm writing negatively about Lua, despite using it for many years. I think highly of Lua, and especially think it has made so many things easier for people over the years. I actually chose Nelua as one of the examples (Part 3) because of it!


I spent a lot of time on those benchmarks. I think my conclusion is just that because WASM isn't a register-machine architecture, you basically have to implement a register allocator to be really fast. wasmtime uses a complex allocator to great success. wasm3 has done it too, but it's just a basic one and it won't be able to compete with GCC or Clang. I could be wrong here, but what else is there? During my testing, it was never in question if libriscv was faster.

I used my usual benchmarks: STREAM (memory) and CoreMark (CPU).


Posted a few hours ago: Wasmi 0.32 performs a register-based translation which gets great benchmark results. https://news.ycombinator.com/item?id=40499130


I saw that. Keep in mind that libriscv is 35% faster than wasm3, and it looks like wasmi is not as fast as wasm3 yet. But they are making good progress.


There is a library called jnigen [1], mainly used by the libGDX framework [2]. But I don't see it used in many other projects though. Personally I use it to maintain a set of Lua C API bindings for some platforms [3] and it works sort of OK once you manage to somehow set up a workflow for building and testing the binaries.

> It works but it is a pain if anything ever changes or a new platform needs to be brought up. Checking in binaries always feels icky but is necessary if not all targets can be built on a single machine.

It is definitely a pain when you cannot test all changes on a single local machine. But I would argue that it is true whenever multiple platforms (or maybe even multiple glibc versions) are involved, regardless of what languages/libraries/tools you use.

[1] https://libgdx.com/wiki/utils/jnigen [2] https://github.com/libgdx/libgdx [3] https://github.com/gudzpoz/luajava


I think the author is confusing two things here:

1. User-space threads / Green threads

2. Structured concurrency

The former one is an advantage of async/await, but is not unique to it (see Go or Java Loom for examples that involves no function coloring problem). And the latter one can be implemented with both OS threads and green threads (see Structured concurrency JEPS for Java [1]).

[1] https://openjdk.org/jeps/462


If you use Emacs, there is also jq-mode. But jnv's filter auto-completion is really a killer feature for me.

[1] https://github.com/ljos/jq-mode


Consider applying for YC's W25 batch! Applications are open till Nov 12.

Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: