<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: senozhatsky</title><link>https://news.ycombinator.com/user?id=senozhatsky</link><description>Hacker News RSS</description><docs>https://hnrss.org/</docs><generator>hnrss v2.1.1</generator><lastBuildDate>Wed, 15 Apr 2026 11:28:38 +0000</lastBuildDate><atom:link href="https://hnrss.org/user?id=senozhatsky" rel="self" type="application/rss+xml"></atom:link><item><title><![CDATA[New comment by senozhatsky in "My Favorite C++ Pattern: X Macros (2023)"]]></title><description><![CDATA[
<p>That's sort of how Linux kernel trace-events are implemented [1]. E.g.<p><pre><code>    DECLARE_EVENT_CLASS(sched_wakeup_template,
    
     TP_PROTO(struct task_struct *p),
    
     TP_ARGS(__perf_task(p)),
    
     TP_STRUCT__entry(
          __array( char, comm, TASK_COMM_LEN )
          __field( pid_t, pid   )
          __field( int, prio   )
          __field( int, target_cpu  )
     ),
    
     TP_fast_assign(
          memcpy(__entry->comm, p->comm, TASK_COMM_LEN);
          __entry->pid  = p->pid;
          __entry->prio  = p->prio; /* XXX SCHED_DEADLINE */
          __entry->target_cpu = task_cpu(p);
     ),
    
     TP_printk("comm=%s pid=%d prio=%d target_cpu=%03d",
          __entry->comm, __entry->pid, __entry->prio,
          __entry->target_cpu)
    );
</code></pre>
[1] <a href="https://web.git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/tree/include/trace/events/sched.h?h=v6.14" rel="nofollow">https://web.git.kernel.org/pub/scm/linux/kernel/git/torvalds...</a></p>
]]></description><pubDate>Wed, 26 Mar 2025 03:00:05 +0000</pubDate><link>https://news.ycombinator.com/item?id=43478422</link><dc:creator>senozhatsky</dc:creator><comments>https://news.ycombinator.com/item?id=43478422</comments><guid isPermaLink="false">https://news.ycombinator.com/item?id=43478422</guid></item><item><title><![CDATA[New comment by senozhatsky in "uBlock Origin is no longer available on Chrome web store"]]></title><description><![CDATA[
<p>I wish they offered a paid version of the browser that would have ublock enabled.</p>
]]></description><pubDate>Mon, 16 Sep 2024 13:41:24 +0000</pubDate><link>https://news.ycombinator.com/item?id=41555978</link><dc:creator>senozhatsky</dc:creator><comments>https://news.ycombinator.com/item?id=41555978</comments><guid isPermaLink="false">https://news.ycombinator.com/item?id=41555978</guid></item><item><title><![CDATA[New comment by senozhatsky in "Turbo Pascal Turns 40"]]></title><description><![CDATA[
<p>> meaning no local variables (still heavy usage of push/pop within a procedure, does this count as a local?)<p>Isn't it (push/pop) how locals basically work?</p>
]]></description><pubDate>Sun, 03 Dec 2023 05:52:24 +0000</pubDate><link>https://news.ycombinator.com/item?id=38505157</link><dc:creator>senozhatsky</dc:creator><comments>https://news.ycombinator.com/item?id=38505157</comments><guid isPermaLink="false">https://news.ycombinator.com/item?id=38505157</guid></item><item><title><![CDATA[Microsoft Was Betting on Unix]]></title><description><![CDATA[
<p>Article URL: <a href="https://twitter.com/unix_byte/status/1541202858518843392">https://twitter.com/unix_byte/status/1541202858518843392</a></p>
<p>Comments URL: <a href="https://news.ycombinator.com/item?id=31892729">https://news.ycombinator.com/item?id=31892729</a></p>
<p>Points: 1</p>
<p># Comments: 2</p>
]]></description><pubDate>Mon, 27 Jun 2022 10:44:05 +0000</pubDate><link>https://twitter.com/unix_byte/status/1541202858518843392</link><dc:creator>senozhatsky</dc:creator><comments>https://news.ycombinator.com/item?id=31892729</comments><guid isPermaLink="false">https://news.ycombinator.com/item?id=31892729</guid></item><item><title><![CDATA[New comment by senozhatsky in "The new Clang _ExtInt feature provides exact bitwidth integer types"]]></title><description><![CDATA[
<p>Knuth's MIX computer with its 6-bit bytes and 5-byte words (IIRC) came to my mind [0]<p>[0] <a href="https://en.wikipedia.org/wiki/MIX" rel="nofollow">https://en.wikipedia.org/wiki/MIX</a></p>
]]></description><pubDate>Thu, 23 Apr 2020 01:37:24 +0000</pubDate><link>https://news.ycombinator.com/item?id=22951995</link><dc:creator>senozhatsky</dc:creator><comments>https://news.ycombinator.com/item?id=22951995</comments><guid isPermaLink="false">https://news.ycombinator.com/item?id=22951995</guid></item><item><title><![CDATA[New comment by senozhatsky in "Let's Destroy C"]]></title><description><![CDATA[
<p>OK, understood. So what you meant was more like<p><pre><code>   puts()'s attack surface is smaller than printf()'s.
</code></pre>
This is not how your message appeared to me - "printf() is vulnerable to injections, use puts() instead". Both are vulnerable to "unintended read()-s".</p>
]]></description><pubDate>Thu, 30 Jan 2020 10:26:31 +0000</pubDate><link>https://news.ycombinator.com/item?id=22190340</link><dc:creator>senozhatsky</dc:creator><comments>https://news.ycombinator.com/item?id=22190340</comments><guid isPermaLink="false">https://news.ycombinator.com/item?id=22190340</guid></item><item><title><![CDATA[New comment by senozhatsky in "Let's Destroy C"]]></title><description><![CDATA[
<p>Looks even better!</p>
]]></description><pubDate>Thu, 30 Jan 2020 09:38:45 +0000</pubDate><link>https://news.ycombinator.com/item?id=22190127</link><dc:creator>senozhatsky</dc:creator><comments>https://news.ycombinator.com/item?id=22190127</comments><guid isPermaLink="false">https://news.ycombinator.com/item?id=22190127</guid></item><item><title><![CDATA[New comment by senozhatsky in "Let's Destroy C"]]></title><description><![CDATA[
<p>Good point.
I suppose that you are talking about overwriting terminating NUL, do I get it right? puts() is vulnurable in exactly same way.</p>
]]></description><pubDate>Thu, 30 Jan 2020 09:37:40 +0000</pubDate><link>https://news.ycombinator.com/item?id=22190123</link><dc:creator>senozhatsky</dc:creator><comments>https://news.ycombinator.com/item?id=22190123</comments><guid isPermaLink="false">https://news.ycombinator.com/item?id=22190123</guid></item><item><title><![CDATA[New comment by senozhatsky in "Let's Destroy C"]]></title><description><![CDATA[
<p>> No. You don't really want to do that. If you're doing that, use puts<p>This is not the case for RO strings, is it?</p>
]]></description><pubDate>Thu, 30 Jan 2020 09:25:25 +0000</pubDate><link>https://news.ycombinator.com/item?id=22190070</link><dc:creator>senozhatsky</dc:creator><comments>https://news.ycombinator.com/item?id=22190070</comments><guid isPermaLink="false">https://news.ycombinator.com/item?id=22190070</guid></item><item><title><![CDATA[New comment by senozhatsky in "Let's Destroy C"]]></title><description><![CDATA[
<p>I see. So when for a char pointer one needs to do<p><pre><code>        printf("%p\n", v);
</code></pre>
the Generic call must look like this<p><pre><code>        displayln((const void *)v);
</code></pre>
is it really better?</p>
]]></description><pubDate>Thu, 30 Jan 2020 09:18:51 +0000</pubDate><link>https://news.ycombinator.com/item?id=22190043</link><dc:creator>senozhatsky</dc:creator><comments>https://news.ycombinator.com/item?id=22190043</comments><guid isPermaLink="false">https://news.ycombinator.com/item?id=22190043</guid></item><item><title><![CDATA[New comment by senozhatsky in "Let's Destroy C"]]></title><description><![CDATA[
<p>Could be. But wouldn't then displayln() require the same string placeholder? Be it "%s", or "{1}" or someting else.</p>
]]></description><pubDate>Thu, 30 Jan 2020 08:55:35 +0000</pubDate><link>https://news.ycombinator.com/item?id=22189930</link><dc:creator>senozhatsky</dc:creator><comments>https://news.ycombinator.com/item?id=22189930</comments><guid isPermaLink="false">https://news.ycombinator.com/item?id=22189930</guid></item><item><title><![CDATA[New comment by senozhatsky in "Let's Destroy C"]]></title><description><![CDATA[
<p><p><pre><code>   > printf("%s\n", "Hello, World!");
   >
   > That's an awful lot of symbolic syntax.
</code></pre>
Well... Because it should have been<p><pre><code>    printf("Hello, World!\n");
</code></pre>
in the first place?<p>One can do something like<p><pre><code>    printf("%s,%s%c\n", "Hello", "World", '!');
</code></pre>
and claim that C is awful and that<p><pre><code>    displayln("Hello, World!");
</code></pre>
is so much better.</p>
]]></description><pubDate>Thu, 30 Jan 2020 08:49:07 +0000</pubDate><link>https://news.ycombinator.com/item?id=22189902</link><dc:creator>senozhatsky</dc:creator><comments>https://news.ycombinator.com/item?id=22189902</comments><guid isPermaLink="false">https://news.ycombinator.com/item?id=22189902</guid></item><item><title><![CDATA[New comment by senozhatsky in "Hyundai Motor Group, Aptiv to set up $4B self-driving car venture"]]></title><description><![CDATA[
<p>I think Hyundai/Kia had self driving systems in development for the past, what, 5 years? Kia debuted its DriveWise in 2016. So they don't start from scratch.</p>
]]></description><pubDate>Tue, 24 Sep 2019 02:29:50 +0000</pubDate><link>https://news.ycombinator.com/item?id=21055916</link><dc:creator>senozhatsky</dc:creator><comments>https://news.ycombinator.com/item?id=21055916</comments><guid isPermaLink="false">https://news.ycombinator.com/item?id=21055916</guid></item><item><title><![CDATA[New comment by senozhatsky in "Everything I googled in a week as a professional software engineer"]]></title><description><![CDATA[
<p>I pretend that '-s' stands for "source", not "symbolic"; and source file follows -s(ource) option.
IOW `ln -s A B' is `link source A to B'.</p>
]]></description><pubDate>Sat, 07 Sep 2019 12:49:54 +0000</pubDate><link>https://news.ycombinator.com/item?id=20903452</link><dc:creator>senozhatsky</dc:creator><comments>https://news.ycombinator.com/item?id=20903452</comments><guid isPermaLink="false">https://news.ycombinator.com/item?id=20903452</guid></item><item><title><![CDATA[New comment by senozhatsky in "On-disk format robustness requirements for new filesystems"]]></title><description><![CDATA[
<p>Somehow reminds me of this conversation [0]:<p><pre><code>  > Al Viro asked if there is a plan to allow mounting hand-crafted XFS or ext4
  > filesystem images. That is an easy way for an attacker to run their own code
  > in ring 0, he said. The filesystems are not written to expect that kind of
  > (ab)use. When asked if it really was that easy to crash the kernel with a
  > hand-crafted filesystem image, Viro said: "is water wet?" 
</code></pre>
[0] <a href="https://lwn.net/Articles/718639/" rel="nofollow">https://lwn.net/Articles/718639/</a></p>
]]></description><pubDate>Tue, 20 Aug 2019 07:57:11 +0000</pubDate><link>https://news.ycombinator.com/item?id=20744715</link><dc:creator>senozhatsky</dc:creator><comments>https://news.ycombinator.com/item?id=20744715</comments><guid isPermaLink="false">https://news.ycombinator.com/item?id=20744715</guid></item><item><title><![CDATA[New comment by senozhatsky in "Richard Sorge: The Soviet Union’s Master Spy"]]></title><description><![CDATA[
<p>From the article - "No other agent had served Moscow for so well or so long."<p>That's very questionable. No one knows who the greatest spy was/is.</p>
]]></description><pubDate>Mon, 19 Aug 2019 05:10:10 +0000</pubDate><link>https://news.ycombinator.com/item?id=20735037</link><dc:creator>senozhatsky</dc:creator><comments>https://news.ycombinator.com/item?id=20735037</comments><guid isPermaLink="false">https://news.ycombinator.com/item?id=20735037</guid></item><item><title><![CDATA[New comment by senozhatsky in "The Linux kernel's inability to gracefully handle low memory pressure"]]></title><description><![CDATA[
<p>Yeah. OOM-kill handling wants to be a silver bullet, sort of. For instance, Linux kernel provides
a number of I/O schedulers or net schedulers, etc. to pick from, but OOM kill is "one size fits all".
And it doesn't really look like things are going to change [1][2][3].<p>[1] <a href="https://lore.kernel.org/lkml/alpine.DEB.2.21.1810221406400.120157@chino.kir.corp.google.com/" rel="nofollow">https://lore.kernel.org/lkml/alpine.DEB.2.21.1810221406400.1...</a><p>[2] <a href="https://lore.kernel.org/lkml/20181024155454.4e63191fbfaa0441f2e62f56@linux-foundation.org/" rel="nofollow">https://lore.kernel.org/lkml/20181024155454.4e63191fbfaa0441...</a><p>[3] <a href="https://lore.kernel.org/lkml/20181023055655.GM18839@dhcp22.suse.cz/" rel="nofollow">https://lore.kernel.org/lkml/20181023055655.GM18839@dhcp22.s...</a></p>
]]></description><pubDate>Tue, 06 Aug 2019 02:53:57 +0000</pubDate><link>https://news.ycombinator.com/item?id=20621678</link><dc:creator>senozhatsky</dc:creator><comments>https://news.ycombinator.com/item?id=20621678</comments><guid isPermaLink="false">https://news.ycombinator.com/item?id=20621678</guid></item><item><title><![CDATA[New comment by senozhatsky in "The Linux kernel's inability to gracefully handle low memory pressure"]]></title><description><![CDATA[
<p>lkml.org has been unstable for the past few... umm years, so The Linux Foundation runs its own lkml archive - lore.kernel.org/lkml/<p>Alternative link, just in case:
<a href="https://lore.kernel.org/lkml/d9802b6a-949b-b327-c4a6-3dbca485ec20@gmx.com/" rel="nofollow">https://lore.kernel.org/lkml/d9802b6a-949b-b327-c4a6-3dbca48...</a></p>
]]></description><pubDate>Tue, 06 Aug 2019 01:09:22 +0000</pubDate><link>https://news.ycombinator.com/item?id=20621050</link><dc:creator>senozhatsky</dc:creator><comments>https://news.ycombinator.com/item?id=20621050</comments><guid isPermaLink="false">https://news.ycombinator.com/item?id=20621050</guid></item><item><title><![CDATA[New comment by senozhatsky in "The brain avoids looking at glassy skyscrapers"]]></title><description><![CDATA[
<p>Maybe. But I can count something like 6 or 7 buildings on that pic which look glassy to me.
I'd say there are several glassy (which reflect sky and water) buildings there [1][2].<p>[1] <a href="https://www.shutterstock.com/video/clip-7263112-panning-timelapse-video-victoria-harbour-hong-kong" rel="nofollow">https://www.shutterstock.com/video/clip-7263112-panning-time...</a><p>[2] <a href="https://www.shutterstock.com/video/clip-27791884-victoria-harbor-hong-kong-14-june-2017" rel="nofollow">https://www.shutterstock.com/video/clip-27791884-victoria-ha...</a><p>Edit: added more links.</p>
]]></description><pubDate>Mon, 05 Aug 2019 08:51:53 +0000</pubDate><link>https://news.ycombinator.com/item?id=20612440</link><dc:creator>senozhatsky</dc:creator><comments>https://news.ycombinator.com/item?id=20612440</comments><guid isPermaLink="false">https://news.ycombinator.com/item?id=20612440</guid></item><item><title><![CDATA[New comment by senozhatsky in "The brain avoids looking at glassy skyscrapers"]]></title><description><![CDATA[
<p>I like glassy buildings. Can stare at them for minutes; the article makes little sense to me.
E.g. Hong Kong Harbour skyline, which is quite "glassy". Many people travel to take a look at it.<p>[1] <a href="https://www.tripsavvy.com/thmb/SPLQhcPHF_u06LNEFd1qIc4p_3Q=/950x0/filters:no_upscale():max_bytes(150000):strip_icc()/GettyImages-586892388-5c7b646fc9e77c0001d19d3b.jpg" rel="nofollow">https://www.tripsavvy.com/thmb/SPLQhcPHF_u06LNEFd1qIc4p_3Q=/...</a></p>
]]></description><pubDate>Mon, 05 Aug 2019 06:47:54 +0000</pubDate><link>https://news.ycombinator.com/item?id=20611844</link><dc:creator>senozhatsky</dc:creator><comments>https://news.ycombinator.com/item?id=20611844</comments><guid isPermaLink="false">https://news.ycombinator.com/item?id=20611844</guid></item></channel></rss>