med-mastodon.com is one of the many independent Mastodon servers you can use to participate in the fediverse.
Medical community on Mastodon

Administered by:

Server stats:

359
active users

#kqueue

0 posts0 participants0 posts today
Felix Palmen :freebsd: :c64:<p>Please help me spread the link to <a href="https://mastodon.bsd.cafe/tags/swad" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>swad</span></a> 😎</p><p><a href="https://github.com/Zirias/swad" rel="nofollow noopener noreferrer" translate="no" target="_blank"><span class="invisible">https://</span><span class="">github.com/Zirias/swad</span><span class="invisible"></span></a></p><p>I really need some users by now, for those two reasons:</p><p>* I'm at a point where I fully covered my own needs (the reasons I started coding this), and getting some users is the only way to learn about what other people might need<br>* The complexity "exploded" after supporting so many OS-specific APIs (like <a href="https://mastodon.bsd.cafe/tags/kqueue" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>kqueue</span></a>, <a href="https://mastodon.bsd.cafe/tags/epoll" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>epoll</span></a>, <a href="https://mastodon.bsd.cafe/tags/eventfd" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>eventfd</span></a>, <a href="https://mastodon.bsd.cafe/tags/signalfd" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>signalfd</span></a>, <a href="https://mastodon.bsd.cafe/tags/timerfd" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>timerfd</span></a>, <a href="https://mastodon.bsd.cafe/tags/eventports" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>eventports</span></a>) and several <a href="https://mastodon.bsd.cafe/tags/lockfree" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>lockfree</span></a> implementations based on <a href="https://mastodon.bsd.cafe/tags/atomics" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>atomics</span></a> while still providing fallbacks for everything that *should* work on any <a href="https://mastodon.bsd.cafe/tags/POSIX" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>POSIX</span></a> systems ... I'm definitely unable at this point to think of every possible edge case and test it. If there are <a href="https://mastodon.bsd.cafe/tags/bugs" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>bugs</span></a> left (which is somewhat likely), I really need people reporting these to me</p><p>Thanks! 🙃</p>
Felix Palmen :freebsd: :c64:<p>Unfortunately, I had to do a bugfix release: <a href="https://mastodon.bsd.cafe/tags/swad" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>swad</span></a> 0.8</p><p>Although I didn't observe any obvious misbehavior on my own installation for several days, I discovered two very relevant bugs just after release of 0.7 🤦‍♂️ -- one of them (only affecting <a href="https://mastodon.bsd.cafe/tags/kqueue" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>kqueue</span></a>, for example on <a href="https://mastodon.bsd.cafe/tags/FreeBSD" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>FreeBSD</span></a>) even critical because it could trigger "undefined behavior".</p><p>Both bugs are regressions from new (performance) improvements added, one from trying to queue as many writes as possible when sending HTTP responses, one from using kqueue to provide timers and signals.</p><p>See release notes for 0.8. Don't use 0.7. Sorry 🤪 </p><p><a href="https://github.com/Zirias/swad" rel="nofollow noopener noreferrer" translate="no" target="_blank"><span class="invisible">https://</span><span class="">github.com/Zirias/swad</span><span class="invisible"></span></a></p>
Felix Palmen :freebsd: :c64:<p>Now that <a href="https://mastodon.bsd.cafe/tags/swad" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>swad</span></a> 0.7 is released, it's time to prepare a new release of <a href="https://mastodon.bsd.cafe/tags/poser" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>poser</span></a>, my own lib supporting <a href="https://mastodon.bsd.cafe/tags/services" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>services</span></a> on <a href="https://mastodon.bsd.cafe/tags/POSIX" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>POSIX</span></a> systems, following a <a href="https://mastodon.bsd.cafe/tags/reactor" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>reactor</span></a> with <a href="https://mastodon.bsd.cafe/tags/threadpool" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>threadpool</span></a> design.</p><p>During development of swad, I moved poser from using strictly only POSIX APIs (with the scalability limits of e.g. <a href="https://mastodon.bsd.cafe/tags/select" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>select</span></a>) to auto-detected support for <a href="https://mastodon.bsd.cafe/tags/kqueue" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>kqueue</span></a>, <a href="https://mastodon.bsd.cafe/tags/epoll" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>epoll</span></a>, <a href="https://mastodon.bsd.cafe/tags/eventports" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>eventports</span></a>, <a href="https://mastodon.bsd.cafe/tags/signalfd" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>signalfd</span></a> and <a href="https://mastodon.bsd.cafe/tags/timerfd" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>timerfd</span></a> (so now it could, in theory(!), "compete" with e.g. libevent). I also fixed quite some hidden bugs, and added more base functionality, like a <a href="https://mastodon.bsd.cafe/tags/dictionary" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>dictionary</span></a> using nested hashtables internally, or <a href="https://mastodon.bsd.cafe/tags/async" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>async</span></a> tasks mimicking the async/await pattern known from e.g, <a href="https://mastodon.bsd.cafe/tags/csharp" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>csharp</span></a>. I also deprecated two features, the periodic and global "service tick" (superseded by individual timers) and the "resolve hosts" property of a "connection" (superseded by a separate resolve class).</p><p>I'll have to decide on a few things, e.g. whether I'll remove the deprecated stuff immediately and bump the major version of the "posercore" lib. I guess I'll do just that. I'd also like to add all the web-specific stuff (http 1.0/1.1 server) that's currently part of the swad code as a "poserweb" lib. This would get a major version of 0, indicating a generally unstable API/ABI as of now....</p><p>And then, I'd have to decide where certain utility classes belong to. The rate limiter is probably useful for things other than web, so it should probably go to core. What about url encoding/decoding, for example? 🤔</p><p>Stay tuned, something will come here, maybe helping you to write a nice service in plain <a href="https://mastodon.bsd.cafe/tags/C" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>C</span></a> 😎:</p><p><a href="https://github.com/Zirias/poser" rel="nofollow noopener noreferrer" translate="no" target="_blank"><span class="invisible">https://</span><span class="">github.com/Zirias/poser</span><span class="invisible"></span></a></p>
Felix Palmen :freebsd: :c64:<p>The next release of <a href="https://mastodon.bsd.cafe/tags/swad" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>swad</span></a> will probably bring not a single new feature, but focus on improvements, especially regarding <a href="https://mastodon.bsd.cafe/tags/performance" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>performance</span></a>. Support for using <a href="https://mastodon.bsd.cafe/tags/kqueue" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>kqueue</span></a> (<a href="https://mastodon.bsd.cafe/tags/FreeBSD" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>FreeBSD</span></a> et al) to handle <a href="https://mastodon.bsd.cafe/tags/signals" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>signals</span></a> is a part of it (which is done and works). Still unsure whether I'll also add support for <a href="https://mastodon.bsd.cafe/tags/Linux" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>Linux</span></a>' <a href="https://mastodon.bsd.cafe/tags/signalfd" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>signalfd</span></a>. Using kqueue also as a better backend for <a href="https://mastodon.bsd.cafe/tags/timers" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>timers</span></a> is on the list.</p><p>Another hopefully quite relevant change is here:</p><p><a href="https://github.com/Zirias/poser/commit/798f23547295f89fa0c751f0e707c3474b5c689c" rel="nofollow noopener noreferrer" translate="no" target="_blank"><span class="invisible">https://</span><span class="ellipsis">github.com/Zirias/poser/commit</span><span class="invisible">/798f23547295f89fa0c751f0e707c3474b5c689c</span></a></p><p>In short, so far my <a href="https://mastodon.bsd.cafe/tags/poser" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>poser</span></a> lib was always awaiting readiness notification (from kqueue, or <a href="https://mastodon.bsd.cafe/tags/epoll" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>epoll</span></a> on Linux, or select/poll for other platforms) before doing any read or write on a socket. This is the ideal approach for reads, because in the common case, a socket is NOT ready for reading ... our kernel must have received something from the remote end first. But for writes, it's not so ideal. The common case is that a socket IS ready to write (because there's space left in the kernel's send buffers). So, just try it, and only register for notifications if it ever fails, makes more sense. Avoids pointless waiting and pointless events, and e.g. with epoll, even unnecessary syscalls. 😉</p>
Felix Palmen :freebsd: :c64:<p>Still working on <a href="https://mastodon.bsd.cafe/tags/swad" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>swad</span></a>, and currently very busy with improving quality, most of the actual work done inside my <a href="https://mastodon.bsd.cafe/tags/poser" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>poser</span></a> library.</p><p>After finally supporting <a href="https://mastodon.bsd.cafe/tags/kqueue" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>kqueue</span></a> and <a href="https://mastodon.bsd.cafe/tags/epoll" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>epoll</span></a>, I now integrated <a href="https://mastodon.bsd.cafe/tags/xxhash" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>xxhash</span></a> to completely replace my previous stupid and naive hashing. I also added a more involved <a href="https://mastodon.bsd.cafe/tags/dictionary" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>dictionary</span></a> class as an alternative to the already existing <a href="https://mastodon.bsd.cafe/tags/hashtable" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>hashtable</span></a>. While the hashtable's size must be pre-configured and collissions are only ever resolved by storing linked lists, the new dictionary dynamically nests multiple hashtables (using different bits of a single hash value). I hope to achieve acceptable scaling while maintaining also acceptable memory overhead that way ...</p><p><a href="https://mastodon.bsd.cafe/tags/swad" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>swad</span></a> already uses both container classes as appropriate.</p><p>Next I'll probably revisit poser's <a href="https://mastodon.bsd.cafe/tags/threadpool" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>threadpool</span></a>. I think I could replace <a href="https://mastodon.bsd.cafe/tags/pthread" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>pthread</span></a> condition variables by "simple" <a href="https://mastodon.bsd.cafe/tags/semaphores" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>semaphores</span></a>, which should also reduce overhead ... </p><p><a href="https://github.com/Zirias/swad" rel="nofollow noopener noreferrer" translate="no" target="_blank"><span class="invisible">https://</span><span class="">github.com/Zirias/swad</span><span class="invisible"></span></a></p><p><a href="https://mastodon.bsd.cafe/tags/c" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>c</span></a> <a href="https://mastodon.bsd.cafe/tags/coding" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>coding</span></a></p>
Felix Palmen :freebsd: :c64:<p>Well, tried it. Works! 🥳</p><p>Accepting a whole list of changes (so you can buffer them during an event loop iteration) and then even submitting them in the same call that receives events (with the changes already applied) is *indeed* a pretty cool thing with <a href="https://mastodon.bsd.cafe/tags/kqueue" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>kqueue</span></a>.</p><p><a href="https://github.com/Zirias/poser/commit/4630d6a8b87284da21097c30ea8a6ba02cc40df6" rel="nofollow noopener noreferrer" translate="no" target="_blank"><span class="invisible">https://</span><span class="ellipsis">github.com/Zirias/poser/commit</span><span class="invisible">/4630d6a8b87284da21097c30ea8a6ba02cc40df6</span></a></p>
Felix Palmen :freebsd: :c64:<p>First change since <a href="https://mastodon.bsd.cafe/tags/swad" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>swad</span></a> 0.2 will actually be a (huge?) improvement to my <a href="https://mastodon.bsd.cafe/tags/poser" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>poser</span></a> lib. So far, it was hardwired to use the good old <a href="https://mastodon.bsd.cafe/tags/POSIX" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>POSIX</span></a> <a href="https://mastodon.bsd.cafe/tags/select" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>select</span></a> call. This is perfectly fine for handling around up to 100 (or at least less than 1000, YMMV) clients.</p><p>Some <a href="https://mastodon.bsd.cafe/tags/select" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>select</span></a> implementations offer defining the upper limit for checked file descriptors. Added support for that.</p><p>POSIX also specifies <a href="https://mastodon.bsd.cafe/tags/poll" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>poll</span></a>, which has very similar <a href="https://mastodon.bsd.cafe/tags/scalability" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>scalability</span></a> issues, but slightly different. Added support for this as well.</p><p>And then, I went on to add support for the <a href="https://mastodon.bsd.cafe/tags/Linux" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>Linux</span></a>-specific <a href="https://mastodon.bsd.cafe/tags/epoll" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>epoll</span></a> and <a href="https://mastodon.bsd.cafe/tags/BSD" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>BSD</span></a>-specific <a href="https://mastodon.bsd.cafe/tags/kqueue" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>kqueue</span></a> (<a href="https://mastodon.bsd.cafe/tags/FreeBSD" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>FreeBSD</span></a>, <a href="https://mastodon.bsd.cafe/tags/NetBSD" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>NetBSD</span></a>, <a href="https://mastodon.bsd.cafe/tags/OpenBSD" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>OpenBSD</span></a>, ...) which are both designed to *solve* any scalability issues 🥳 </p><p>A little thing that slightly annoyed me about kqueue was that there's no support for temporarily changing the signal mask, so I had to do the silly dance shown in the screenshot. OTOH, it offers changing event filters and getting events in a single call, which I might try to even further optimize ... 😎</p><p><a href="https://mastodon.bsd.cafe/tags/C" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>C</span></a> <a href="https://mastodon.bsd.cafe/tags/coding" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>coding</span></a></p>
Stephan Lichtenauer | נח סתו<p><a href="https://mastodon.africa/tags/FreeBSD30" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>FreeBSD30</span></a> timeline - a few things that happened during these 30 <a href="https://mastodon.africa/tags/FreeBSD" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>FreeBSD</span></a> years:</p><p><a href="https://mastodon.africa/tags/UNIX" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>UNIX</span></a> <a href="https://mastodon.africa/tags/BSD" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>BSD</span></a> <a href="https://mastodon.africa/tags/MULTICS" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>MULTICS</span></a> <a href="https://mastodon.africa/tags/1BSD" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>1BSD</span></a> <a href="https://mastodon.africa/tags/2BSD" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>2BSD</span></a> <a href="https://mastodon.africa/tags/42BSD" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>42BSD</span></a> <a href="https://mastodon.africa/tags/43BSD" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>43BSD</span></a> <a href="https://mastodon.africa/tags/386BSD" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>386BSD</span></a> <a href="https://mastodon.africa/tags/ipfw" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>ipfw</span></a> <a href="https://mastodon.africa/tags/FreeBSDCon" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>FreeBSDCon</span></a> <a href="https://mastodon.africa/tags/BSDCON" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>BSDCON</span></a> <a href="https://mastodon.africa/tags/ports" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>ports</span></a> <a href="https://mastodon.africa/tags/jails" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>jails</span></a> <a href="https://mastodon.africa/tags/FreeBSDFoundation" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>FreeBSDFoundation</span></a> <a href="https://mastodon.africa/tags/kqueue" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>kqueue</span></a> <a href="https://mastodon.africa/tags/EuroBSDCon" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>EuroBSDCon</span></a> <a href="https://mastodon.africa/tags/CoreTeam" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>CoreTeam</span></a> <a href="https://mastodon.africa/tags/AsiaBSDCon" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>AsiaBSDCon</span></a> <a href="https://mastodon.africa/tags/BSDCAN" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>BSDCAN</span></a> <a href="https://mastodon.africa/tags/pf" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>pf</span></a> <a href="https://mastodon.africa/tags/OpenBSD" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>OpenBSD</span></a> <a href="https://mastodon.africa/tags/ZFS" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>ZFS</span></a> <a href="https://mastodon.africa/tags/DTrace" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>DTrace</span></a> <a href="https://mastodon.africa/tags/VNET" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>VNET</span></a> <a href="https://mastodon.africa/tags/Capsicum" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>Capsicum</span></a> <a href="https://mastodon.africa/tags/Cheri" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>Cheri</span></a> <a href="https://mastodon.africa/tags/Poudriere" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>Poudriere</span></a> <a href="https://mastodon.africa/tags/clang" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>clang</span></a> <a href="https://mastodon.africa/tags/llvm" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>llvm</span></a> <a href="https://mastodon.africa/tags/subversion" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>subversion</span></a> <a href="https://mastodon.africa/tags/OpenZFS" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>OpenZFS</span></a> <a href="https://mastodon.africa/tags/git" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>git</span></a></p><p><a href="https://mastodon.africa/tags/FreeBSDDay" class="mention hashtag" rel="nofollow noopener noreferrer" target="_blank">#<span>FreeBSDDay</span></a> </p><p><a href="https://freebsdfoundation.org/freebsd/timeline/" rel="nofollow noopener noreferrer" target="_blank"><span class="invisible">https://</span><span class="ellipsis">freebsdfoundation.org/freebsd/</span><span class="invisible">timeline/</span></a></p>