<rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:atom="http://www.w3.org/2005/Atom"><channel><title>Hacker News: taintegral</title><link>https://news.ycombinator.com/user?id=taintegral</link><description>Hacker News RSS</description><docs>https://hnrss.org/</docs><generator>hnrss v2.1.1</generator><lastBuildDate>Sat, 18 Apr 2026 22:52:36 +0000</lastBuildDate><atom:link href="https://hnrss.org/user?id=taintegral" rel="self" type="application/rss+xml"></atom:link><item><title><![CDATA[New comment by taintegral in "SQLite JSON at full index speed using generated columns"]]></title><description><![CDATA[
<p>(I made rkyv) I took a look at lite3/tron because I was interested in seeing how it approached some of the issues I ran into with rkyv. I ended up with some additional information related to points 1 and 2 I figured I'd write down:<p>1) You're correct, rkyv uses a B-tree with a default branching factor of 6 [1]. I don't think I've ever implemented a binary tree in any version of rkyv - maybe one of the earliest versions used a sorted vec instead of a B-tree? I hate the B-tree map implementation because it is so complicated, even though it actually used to be even worse in 0.7 when it was implemented as a B+ tree. Sorry for making you read any of it!<p>2) Arbitrary mutations would definitely be an improvement on rkyv, and I was most interested to see what kind of approach lite3/tron took! Unfortunately growing the buffer is not supported [2] and freed memory isn't reclaimed [3]. These are the two actually difficult problems standing in the way of rkyv getting more comprehensive mutation support, so unfortunately I think there's nothing valuable to take away here.<p>The issue with growing the buffer is that you invalidate any pointers into the buffer and have to manually fix them up (e.g. by re-crawling the buffer). There's not a decent approach I'm aware of which manages these pointer fixups in a way that limits complexity and avoids really nasty API surfaces.<p>The issue with memory reclamation is that you effectively have to add an allocator to your buffer, and that allocator has to also be persistable. I actually got this part working in rel while that was still a project worth hacking on [4]. I just ran out of steam and willingness to play the type-tac-toe required to get a safe API out of it. The main problem I ran into there was related to value branding, since you shouldn't be allowed to make references to objects which cross between contiguous buffers.<p>This project is neat, but it does basically just look like an rkyv-converted `BTreeMap<String, JsonValue>`.<p>[1]: <a href="https://github.com/rkyv/rkyv/blob/main/rkyv/src/collections/btree/map/mod.rs" rel="nofollow">https://github.com/rkyv/rkyv/blob/main/rkyv/src/collections/...</a>
[2]: <a href="https://github.com/fastserial/lite3/blob/main/src/lite3.c#L545-L549" rel="nofollow">https://github.com/fastserial/lite3/blob/main/src/lite3.c#L5...</a>
[3]: <a href="https://lite3.io/design_and_limitations.html#autotoc_md29" rel="nofollow">https://lite3.io/design_and_limitations.html#autotoc_md29</a> (see note at end of section)
[4]: <a href="https://github.com/rkyv/rel/blob/main/rel_example/src/main.rs" rel="nofollow">https://github.com/rkyv/rel/blob/main/rel_example/src/main.r...</a></p>
]]></description><pubDate>Tue, 16 Dec 2025 20:05:15 +0000</pubDate><link>https://news.ycombinator.com/item?id=46293682</link><dc:creator>taintegral</dc:creator><comments>https://news.ycombinator.com/item?id=46293682</comments><guid isPermaLink="false">https://news.ycombinator.com/item?id=46293682</guid></item><item><title><![CDATA[New comment by taintegral in "The Policy Puppetry Prompt: Novel bypass for major LLMs"]]></title><description><![CDATA[
<p>> 'AI safety' is a meaningless term<p>I disagree with this assertion. As you said, safety is an attribute of action. We have many of examples of artificial intelligence which can take action, usually because they are equipped with robotics or some other route to physical action.<p>I think whether providing information counts as "taking action" is a worthwhile philosophical question. But regardless of the answer, you can't ignore that LLMs provide information to _humans_ which are perfectly capable of taking action. In that way, 'AI safety' in the context of LLMs is a lot like knife safety. It's about being safe _with knives_. You don't give knives to kids because they are likely to mishandle them and hurt themselves or others.<p>With regards to censorship - a healthy society self-censors all the time. The debate worth having is _what_ is censored and _why_.</p>
]]></description><pubDate>Fri, 25 Apr 2025 16:02:31 +0000</pubDate><link>https://news.ycombinator.com/item?id=43795115</link><dc:creator>taintegral</dc:creator><comments>https://news.ycombinator.com/item?id=43795115</comments><guid isPermaLink="false">https://news.ycombinator.com/item?id=43795115</guid></item><item><title><![CDATA[How to sort your library in exactly 51,271 steps]]></title><description><![CDATA[
<p>Article URL: <a href="https://david.kolo.ski/blog/sort-library-steps-mtg/">https://david.kolo.ski/blog/sort-library-steps-mtg/</a></p>
<p>Comments URL: <a href="https://news.ycombinator.com/item?id=41403719">https://news.ycombinator.com/item?id=41403719</a></p>
<p>Points: 94</p>
<p># Comments: 27</p>
]]></description><pubDate>Fri, 30 Aug 2024 19:25:07 +0000</pubDate><link>https://david.kolo.ski/blog/sort-library-steps-mtg/</link><dc:creator>taintegral</dc:creator><comments>https://news.ycombinator.com/item?id=41403719</comments><guid isPermaLink="false">https://news.ycombinator.com/item?id=41403719</guid></item><item><title><![CDATA[New comment by taintegral in "Rkyv: A zero-copy deserialization framework for rust"]]></title><description><![CDATA[
<p>Mixing milliseconds down to picoseconds made the columns too wide. All of the benchmark data is also available as JSON in the benchmark_results directory if you wanted to drop it into sheets or some other analysis.</p>
]]></description><pubDate>Sat, 13 Jan 2024 17:38:02 +0000</pubDate><link>https://news.ycombinator.com/item?id=38982359</link><dc:creator>taintegral</dc:creator><comments>https://news.ycombinator.com/item?id=38982359</comments><guid isPermaLink="false">https://news.ycombinator.com/item?id=38982359</guid></item><item><title><![CDATA[New comment by taintegral in "Rkyv: A zero-copy deserialization framework for rust"]]></title><description><![CDATA[
<p>Author here, you’re correct. You can customize your validation context for your specific needs. For example, if you don’t have allocation available (i.e. `#![no_std]` without the alloc crate) then you’ll probably need to write your own mapping system to handle shared pointers. Or you can just not use them if that works better for you. That’s also a large part of why rkyv uses generics so heavily.<p>If your data is read-only then pointing to the same object from two locations is (usually) fine. But rkyv also supports in-place mutability, which requires validating that no two pointers will overlap each other. Otherwise you could have simultaneous mutable borrows to the same value which is UB.</p>
]]></description><pubDate>Sat, 13 Jan 2024 17:35:20 +0000</pubDate><link>https://news.ycombinator.com/item?id=38982310</link><dc:creator>taintegral</dc:creator><comments>https://news.ycombinator.com/item?id=38982310</comments><guid isPermaLink="false">https://news.ycombinator.com/item?id=38982310</guid></item><item><title><![CDATA[New comment by taintegral in "When no one can afford to live in America anymore"]]></title><description><![CDATA[
<p>> 6) Morality will degrade. Prostitution, drug use, nihilism, and degeneracy of every sort will explode.<p>> 7) America’s military will weaken dramatically as the quality of recruits plunges and we no longer have the money to properly maintain and supply our forces.<p>Tried and true right-wing media strategy: sucker people by talking about economic stress on the middle class (real issue), and gradually transition to moral hand-wringing and pumping the military-industrial complex (fake issues).<p>> 12) The government will institute a wealth tax. It will be sold as something to target the rich, but in practice, over time, they will be taking large amounts of money from people no one considers rich.<p>Interesting that they start by talking about how Campbell's soup is expensive and finish by talking about how the real threat is a wealth tax...</p>
]]></description><pubDate>Thu, 17 Aug 2023 15:34:14 +0000</pubDate><link>https://news.ycombinator.com/item?id=37163275</link><dc:creator>taintegral</dc:creator><comments>https://news.ycombinator.com/item?id=37163275</comments><guid isPermaLink="false">https://news.ycombinator.com/item?id=37163275</guid></item><item><title><![CDATA[Google open-sources Rust crate audits]]></title><description><![CDATA[
<p>Article URL: <a href="https://opensource.googleblog.com/2023/05/open-sourcing-our-rust-crate-audits.html">https://opensource.googleblog.com/2023/05/open-sourcing-our-rust-crate-audits.html</a></p>
<p>Comments URL: <a href="https://news.ycombinator.com/item?id=36047202">https://news.ycombinator.com/item?id=36047202</a></p>
<p>Points: 256</p>
<p># Comments: 48</p>
]]></description><pubDate>Tue, 23 May 2023 16:59:54 +0000</pubDate><link>https://opensource.googleblog.com/2023/05/open-sourcing-our-rust-crate-audits.html</link><dc:creator>taintegral</dc:creator><comments>https://news.ycombinator.com/item?id=36047202</comments><guid isPermaLink="false">https://news.ycombinator.com/item?id=36047202</guid></item><item><title><![CDATA[New comment by taintegral in "Pointers Are Complicated III, or: Pointer-integer casts exposed"]]></title><description><![CDATA[
<p>If you can't track provenance to un-restrict the pointers because it's infeasible, then you have to give up on at least one of the optimization passes. In this case, the optimizations used are very fundamental and giving up on any one of them unilaterally would be catastrophic for performance. The provenance models being suggested add more nuance to the model (pointer provenance) so that we can keep all of the optimization passes while preventing these cases from being optimized incorrectly. Weak provenance says we can't optimize away the pointer to integer cast, strict provenance says we must provide provenance for integer to pointer casts. Weak provenance is broadly compatible with existing code (compiler semantics change) whereas strict provenance is not (language semantics change). The tradeoff is that strict provenance leads to better optimization in general.</p>
]]></description><pubDate>Fri, 15 Apr 2022 16:09:42 +0000</pubDate><link>https://news.ycombinator.com/item?id=31041858</link><dc:creator>taintegral</dc:creator><comments>https://news.ycombinator.com/item?id=31041858</comments><guid isPermaLink="false">https://news.ycombinator.com/item?id=31041858</guid></item><item><title><![CDATA[New comment by taintegral in "Pointers Are Complicated III, or: Pointer-integer casts exposed"]]></title><description><![CDATA[
<p>This analysis is correct but the solution is not feasible. Changing a modification through `x` to a modification through `y` does indeed violate the semantics of `restrict`. The problem is that in order to detect this situation, we'd have to track the provenance of integers. In this specific example, we'd have to know that replacing `xaddr` with `y2addr` affects `x` and `y`. There is general consensus that tracking provenance for integers causes many more problems than it solves, so although this would solve the problem it is not feasible. This is why weak and strict provenance are being pursued instead.</p>
]]></description><pubDate>Fri, 15 Apr 2022 15:29:46 +0000</pubDate><link>https://news.ycombinator.com/item?id=31041304</link><dc:creator>taintegral</dc:creator><comments>https://news.ycombinator.com/item?id=31041304</comments><guid isPermaLink="false">https://news.ycombinator.com/item?id=31041304</guid></item><item><title><![CDATA[New comment by taintegral in "Pointers Are Complicated III, or: Pointer-integer casts exposed"]]></title><description><![CDATA[
<p>`restrict` pointers have nothing to do with the underlying "object" they point into (an array in this case). `restrict` lets the compiler assume that reads through a restricted pointer or any pointer expressions derived from it are only affected by writes through that pointer or expressions derived from it. There are only two writes in this example: `*x = 0`, which is trivially correct; and `*ptr = 1`, where `ptr` is derived from `x` (via `ptr = (int *)(uintptr_t)x`) so this is also correct. However, it's now easy to see that the optimization replacing `xaddr` with `y2addr` causes undefined behavior since it changes `ptr` to be derived from `y`. The post addresses this in "The blame game" and mentions that integers could carry provenance but that it's infeasible to actually do this.<p>The weak provenance solution is to ban optimizing the pointer to integer casts since they have a (conceptual) side-effect. The strict provenance proposal points out that the side effect is only observable if the integer is cast back to a pointer, so we can keep optimizing pointer to integer casts and instead ban integer to pointer casts. For example, an operation like `(int *)xaddr` is banned under strict provenance. Instead, we provide a casting operation that includes the pointer to assume the provenance of; something like `(int * with x)xaddr`. With this new provenance-preserving cast, we can see that the final optimization of replacing `*x` with its previously assigned value of `0` is no longer possible because the code in between involves `x`.</p>
]]></description><pubDate>Fri, 15 Apr 2022 14:24:46 +0000</pubDate><link>https://news.ycombinator.com/item?id=31040606</link><dc:creator>taintegral</dc:creator><comments>https://news.ycombinator.com/item?id=31040606</comments><guid isPermaLink="false">https://news.ycombinator.com/item?id=31040606</guid></item><item><title><![CDATA[People are digging through their trash and reusing Target’s pill bottles (2016)]]></title><description><![CDATA[
<p>Article URL: <a href="https://qz.com/796794/clearrx-people-are-digging-through-their-trash-to-save-targets-well-designed-prescription-pill-bottles/">https://qz.com/796794/clearrx-people-are-digging-through-their-trash-to-save-targets-well-designed-prescription-pill-bottles/</a></p>
<p>Comments URL: <a href="https://news.ycombinator.com/item?id=29907076">https://news.ycombinator.com/item?id=29907076</a></p>
<p>Points: 2</p>
<p># Comments: 0</p>
]]></description><pubDate>Wed, 12 Jan 2022 14:54:29 +0000</pubDate><link>https://qz.com/796794/clearrx-people-are-digging-through-their-trash-to-save-targets-well-designed-prescription-pill-bottles/</link><dc:creator>taintegral</dc:creator><comments>https://news.ycombinator.com/item?id=29907076</comments><guid isPermaLink="false">https://news.ycombinator.com/item?id=29907076</guid></item><item><title><![CDATA[New comment by taintegral in "Solving NP-hard puzzles with the oldest trick in the book"]]></title><description><![CDATA[
<p>Really not sure why the state space would only grow as n^k / k!. As well as what n and k are in this case. Adding more tiles or more actors would both dramatically increase the size of the state space for that input.</p>
]]></description><pubDate>Fri, 15 Oct 2021 23:17:21 +0000</pubDate><link>https://news.ycombinator.com/item?id=28884231</link><dc:creator>taintegral</dc:creator><comments>https://news.ycombinator.com/item?id=28884231</comments><guid isPermaLink="false">https://news.ycombinator.com/item?id=28884231</guid></item><item><title><![CDATA[New comment by taintegral in "Solving NP-hard puzzles with the oldest trick in the book"]]></title><description><![CDATA[
<p>I would really enjoy a proof that it is not!</p>
]]></description><pubDate>Fri, 15 Oct 2021 23:08:21 +0000</pubDate><link>https://news.ycombinator.com/item?id=28884171</link><dc:creator>taintegral</dc:creator><comments>https://news.ycombinator.com/item?id=28884171</comments><guid isPermaLink="false">https://news.ycombinator.com/item?id=28884171</guid></item><item><title><![CDATA[New comment by taintegral in "Solving NP-hard puzzles with the oldest trick in the book"]]></title><description><![CDATA[
<p>I gave the thought some idle time, but it's been so long since I've constructed a proper hardness proof. If I do, I'll definitely make a post about it!</p>
]]></description><pubDate>Thu, 14 Oct 2021 15:10:51 +0000</pubDate><link>https://news.ycombinator.com/item?id=28865377</link><dc:creator>taintegral</dc:creator><comments>https://news.ycombinator.com/item?id=28865377</comments><guid isPermaLink="false">https://news.ycombinator.com/item?id=28865377</guid></item><item><title><![CDATA[New comment by taintegral in "Solving NP-hard puzzles with the oldest trick in the book"]]></title><description><![CDATA[
<p>This is a great idea, and the low-level optimization tips are all excellent ones I have used in the past. I want to talk a little bit more about using bidirectional A* though, because I think it's very interesting. It's a great strategy in general, but this may be a case where it doesn't do as well.<p>Working backwards for this particular puzzle is very difficult because on each turn an actor may or may not move. This effectively increases the branching factor from 4 (one for each direction) to 4 * 2^n (for each of four directions, each actor may or may not have moved). In practice it would be lower than that upper bound, but it could still be significantly higher than the forward branching factor. A nice visualization for this to think of your start and end states as points in space, and your A* searches as cones emitting from one point and growing toward the other. The angle of the cone would be roughly approximate of your branching factor, and when your cones meet each other or a point the search is done. If your branching factor is the same forwards and backwards, you can travel through much less space by searching forwards and backwards simultaneously. However, if your backwards branching factor is higher then the cone from the end state will be much broader. This could travel through much more space than just doing a forward search.<p>This kind of behavior is very evocative one-way functions, and makes me think it might be related to NP-hardness in some way. I'm really not qualified to prove these kinds of statements though. Maybe someone else can offer a more rigorous mathematical perspective?</p>
]]></description><pubDate>Thu, 14 Oct 2021 13:42:01 +0000</pubDate><link>https://news.ycombinator.com/item?id=28864081</link><dc:creator>taintegral</dc:creator><comments>https://news.ycombinator.com/item?id=28864081</comments><guid isPermaLink="false">https://news.ycombinator.com/item?id=28864081</guid></item><item><title><![CDATA[New comment by taintegral in "Solving NP-hard puzzles with the oldest trick in the book"]]></title><description><![CDATA[
<p>This is fixed now.</p>
]]></description><pubDate>Thu, 14 Oct 2021 12:37:33 +0000</pubDate><link>https://news.ycombinator.com/item?id=28863425</link><dc:creator>taintegral</dc:creator><comments>https://news.ycombinator.com/item?id=28863425</comments><guid isPermaLink="false">https://news.ycombinator.com/item?id=28863425</guid></item><item><title><![CDATA[New comment by taintegral in "Solving NP-hard puzzles with the oldest trick in the book"]]></title><description><![CDATA[
<p>In my experience, the only way to make meaningful progress on performance from here on out is to:<p>- Squeeze out more entropy (for example, rotating states for symmetric boards)<p>- Make the heuristic function smarter (for example, by calculating the assignment bottleneck)<p>I wrote a Carcassonne solver once and found many little optimization opportunities by detecting fail states early for example. Avoiding dead ends saves a massive amount of time.</p>
]]></description><pubDate>Thu, 14 Oct 2021 07:55:12 +0000</pubDate><link>https://news.ycombinator.com/item?id=28861595</link><dc:creator>taintegral</dc:creator><comments>https://news.ycombinator.com/item?id=28861595</comments><guid isPermaLink="false">https://news.ycombinator.com/item?id=28861595</guid></item><item><title><![CDATA[New comment by taintegral in "Solving NP-hard puzzles with the oldest trick in the book"]]></title><description><![CDATA[
<p>That would definitely work, and I’d be interested in the performance impact. This was written so that the state size would scale with the number of actors rather than the size of the grid. There is a degenerate case where a massive mostly empty grid becomes difficult not only to store in memory, but also to transition on move. The transition function would take time proportional to the size of the grid rather than the number of actors.</p>
]]></description><pubDate>Thu, 14 Oct 2021 06:03:37 +0000</pubDate><link>https://news.ycombinator.com/item?id=28860983</link><dc:creator>taintegral</dc:creator><comments>https://news.ycombinator.com/item?id=28860983</comments><guid isPermaLink="false">https://news.ycombinator.com/item?id=28860983</guid></item><item><title><![CDATA[New comment by taintegral in "Solving NP-hard puzzles with the oldest trick in the book"]]></title><description><![CDATA[
<p>Bounding the maximum number of actors is just an optimization for the cases we want to solve. Of course if you wanted to really solve any case you would need infinite space, and that’s not achievable either. If you desired, you can also just omit that particular optimization. :) I think a better way to phrase it is that we are writing a solver for a reasonable subset of inputs to an NP-hard problem.</p>
]]></description><pubDate>Thu, 14 Oct 2021 06:00:09 +0000</pubDate><link>https://news.ycombinator.com/item?id=28860955</link><dc:creator>taintegral</dc:creator><comments>https://news.ycombinator.com/item?id=28860955</comments><guid isPermaLink="false">https://news.ycombinator.com/item?id=28860955</guid></item><item><title><![CDATA[New comment by taintegral in "Solving NP-hard puzzles with the oldest trick in the book"]]></title><description><![CDATA[
<p>Done! Thanks for the boost, I appreciate it very much. :)</p>
]]></description><pubDate>Thu, 14 Oct 2021 05:28:45 +0000</pubDate><link>https://news.ycombinator.com/item?id=28860798</link><dc:creator>taintegral</dc:creator><comments>https://news.ycombinator.com/item?id=28860798</comments><guid isPermaLink="false">https://news.ycombinator.com/item?id=28860798</guid></item></channel></rss>