<?xml version="1.0" encoding="utf-8" standalone="yes"?><rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom"><channel><title>Welcome on David Álvarez Rosa | Personal Website</title><link>https://david.alvarezrosa.com/</link><description>Recent content in Welcome on David Álvarez Rosa | Personal Website</description><generator>Hugo</generator><language>en</language><lastBuildDate>Mon, 01 Jun 2026 10:55:00 +0100</lastBuildDate><atom:link href="https://david.alvarezrosa.com/index.xml" rel="self" type="application/rss+xml"/><item><title>Self-Hosting on the Dark Web</title><link>https://david.alvarezrosa.com/posts/self-hosting-on-the-dark-web/?utm_source=rss</link><pubDate>Mon, 01 Jun 2026 10:55:00 +0100</pubDate><guid>https://david.alvarezrosa.com/posts/self-hosting-on-the-dark-web/</guid><description>&lt;p&gt;This site is now reachable over Tor as a hidden service, at a &lt;code&gt;.onion&lt;/code&gt;
address that resolves only inside the Tor network.&lt;sup id="fnref:1"&gt;&lt;a href="#fn:1" class="footnote-ref" role="doc-noteref"&gt;1&lt;/a&gt;&lt;/sup&gt; &lt;a href="https://www.torproject.org/"&gt;Tor&lt;/a&gt; relays and
encrypts your traffic as it passes through thousands of volunteer-run
servers, so that no single party can link who you are to what you are
doing; a hidden service extends that anonymity to the server itself.&lt;/p&gt;
&lt;p&gt;It&amp;rsquo;s built by the nonprofit &lt;a href="https://www.torproject.org/"&gt;Tor Project&lt;/a&gt;, which advances human rights and
freedoms through free software and open networks, so that anyone can use
the internet free from tracking, surveillance, and censorship. The
network only works because people use it, so consider &lt;a href="https://donate.torproject.org/"&gt;supporting them&lt;/a&gt; or
running a relay&amp;mdash;your contribution helps millions stay safe and private
online every day.&lt;/p&gt;</description></item><item><title>First Steps on a New Server</title><link>https://david.alvarezrosa.com/posts/first-steps-on-a-new-server/?utm_source=rss</link><pubDate>Sun, 17 May 2026 17:26:00 +0100</pubDate><guid>https://david.alvarezrosa.com/posts/first-steps-on-a-new-server/</guid><description>&lt;p&gt;Over the last decade I&amp;rsquo;ve been playing with dozens of servers from
multiple providers. These are the steps I&amp;rsquo;ve been perfecting to get up
to speed fast and feel right at home on a new machine. Wrote it down
here mostly as a personal reference, but hopefully useful to someone
else too.&lt;/p&gt;
&lt;h2 id="hardware-distro-and-dns"&gt;
 Hardware, distro, and DNS
 &lt;a class="anchor" href="#hardware-distro-and-dns"&gt;&amp;sect;&lt;/a&gt;
&lt;/h2&gt;
&lt;p&gt;Clean Linux install with one large root partition plus big
swap.&lt;sup id="fnref:1"&gt;&lt;a href="#fn:1" class="footnote-ref" role="doc-noteref"&gt;1&lt;/a&gt;&lt;/sup&gt; While I run Arch on my laptop, Debian tends to be a better
fit for servers because of its stability and long support window.&lt;/p&gt;</description></item><item><title>Fundamental Theorem of Calculus</title><link>https://david.alvarezrosa.com/posts/fundamental-theorem-of-calculus/?utm_source=rss</link><pubDate>Wed, 22 Apr 2026 20:14:00 +0100</pubDate><guid>https://david.alvarezrosa.com/posts/fundamental-theorem-of-calculus/</guid><description>&lt;p&gt;Although the notion of area is intuitive, its mathematical treatment
requires a rigorous definition. This post introduces the Riemann
integral, and proves the fundamental theorem of calculus&amp;mdash;a beautiful
result that connects integrals and derivatives.&lt;/p&gt;
&lt;h2 id="riemann-integral"&gt;
 Riemann integral
 &lt;a class="anchor" href="#riemann-integral"&gt;&amp;sect;&lt;/a&gt;
&lt;/h2&gt;
&lt;p&gt;Given a bounded&lt;sup id="fnref:1"&gt;&lt;a href="#fn:1" class="footnote-ref" role="doc-noteref"&gt;1&lt;/a&gt;&lt;/sup&gt; function \(f\colon[a,b]\to\mathbb{R}\), we can approximate the
area under its graph by rectangles. Choose a partition of its domain&lt;/p&gt;
&lt;p&gt;\[
\mathcal{P}=\{x_0,x_1,\ldots,x_n\mid a=x_0&amp;lt;x_1&amp;lt;\cdots&amp;lt;x_n=b\}.
\]&lt;/p&gt;
&lt;p&gt;For each subinterval \([x_{k-1},x_k]\), define the width \(\Delta
x_k=x_k-x_{k-1}\), and let \(m_k\) and \(M_k\) denote the infimum and
supremum of \(f\) on that subinterval. The lower and upper sums are&lt;/p&gt;</description></item><item><title>Optimizing a Lock-Free Ring Buffer</title><link>https://david.alvarezrosa.com/posts/optimizing-a-lock-free-ring-buffer/?utm_source=rss</link><pubDate>Tue, 24 Mar 2026 11:51:00 +0000</pubDate><guid>https://david.alvarezrosa.com/posts/optimizing-a-lock-free-ring-buffer/</guid><description>&lt;p&gt;A single-producer single-consumer (SPSC) queue is a great example of how
far constraints can take a design. In this post, you will learn how to
implement a ring buffer from scratch: start with the simplest design,
make it thread-safe, and then gradually remove overhead while preserving
FIFO behavior and predictable latency. This pattern is widely used to
share data between threads in the lowest-latency environments.&lt;/p&gt;
&lt;h2 id="what-is-a-ring-buffer"&gt;
 What is a ring buffer?
 &lt;a class="anchor" href="#what-is-a-ring-buffer"&gt;&amp;sect;&lt;/a&gt;
&lt;/h2&gt;
&lt;p&gt; &lt;sup id="fnref:1"&gt;&lt;a href="#fn:1" class="footnote-ref" role="doc-noteref"&gt;1&lt;/a&gt;&lt;/sup&gt;You might have run into the term circular buffer, or perhaps
cyclic queue. These are simply other names for a &lt;em&gt;ring buffer:&lt;/em&gt; a queue
where a producer generates data and inserts it into the buffer, and a
consumer later pulls it back out, in first-in-first-out order.&lt;/p&gt;</description></item><item><title>Deriving Type Erasure</title><link>https://david.alvarezrosa.com/posts/deriving-type-erasure/?utm_source=rss</link><pubDate>Tue, 10 Mar 2026 09:46:00 +0000</pubDate><guid>https://david.alvarezrosa.com/posts/deriving-type-erasure/</guid><description>&lt;p&gt;Ever looked at &lt;code&gt;std::any&lt;/code&gt; and wondered what&amp;rsquo;s going on behind the
scenes? Beneath the intimidating interface is a classic technique
called type erasure: concrete types hidden behind a small, uniform
wrapper.&lt;/p&gt;
&lt;p&gt;Starting from familiar tools like virtual functions and templates, we&amp;rsquo;ll
build a minimal &lt;code&gt;std::any&lt;/code&gt;. By the end, you&amp;rsquo;ll have a clear
understanding of how type erasure works under the hood.&lt;/p&gt;
&lt;h2 id="polymorphism-with-interfaces"&gt;
 Polymorphism with interfaces
 &lt;a class="anchor" href="#polymorphism-with-interfaces"&gt;&amp;sect;&lt;/a&gt;
&lt;/h2&gt;
&lt;p&gt;The typical way to achieve polymorphism is to define an interface
consisting of pure-virtual methods you want to be able to call. Then,
for each implementation that you want to use polymorphically, you create
a subclass that inherits from the base class and implement those
methods.&lt;/p&gt;</description></item><item><title>Devirtualization and Static Polymorphism</title><link>https://david.alvarezrosa.com/posts/devirtualization-and-static-polymorphism/?utm_source=rss</link><pubDate>Wed, 25 Feb 2026 09:45:00 +0000</pubDate><guid>https://david.alvarezrosa.com/posts/devirtualization-and-static-polymorphism/</guid><description>&lt;p&gt;Ever wondered why your &amp;ldquo;clean&amp;rdquo; polymorphic design underperforms in
benchmarks? Virtual dispatch enables polymorphism, but it comes with
hidden overhead: pointer indirection, larger object layouts, and fewer
inlining opportunities.&lt;/p&gt;
&lt;p&gt;Compilers do their best to &lt;em&gt;devirtualize&lt;/em&gt; these calls, but it isn&amp;rsquo;t
always possible. On latency-sensitive paths, it&amp;rsquo;s beneficial to
manually replace dynamic dispatch with &lt;em&gt;static polymorphism&lt;/em&gt;, so calls
are resolved at compile time and the abstraction has effectively zero
runtime cost.&lt;/p&gt;</description></item><item><title>David Álvarez Rosa</title><link>https://david.alvarezrosa.com/about/?utm_source=rss</link><pubDate>Sat, 24 Jan 2026 12:31:00 +0000</pubDate><guid>https://david.alvarezrosa.com/about/</guid><description>&lt;style&gt;
 .signature { display: none; }
 sup { display: none; }
 .side img { max-width: 225px; box-shadow: none; margin-top: -26px;}
 @media (max-width: 860px) { .side img { margin-top: 0!important; } }
 main p:first-of-type::first-letter { float: revert; font-size: revert; font-family: revert; padding: revert; }
&lt;/style&gt;
&lt;p&gt; &lt;sup id="fnref:1"&gt;&lt;a href="#fn:1" class="footnote-ref" role="doc-noteref"&gt;1&lt;/a&gt;&lt;/sup&gt;Mathematician and engineer based in sunny Dublin, passionate
about low-latency, high-performance systems.&lt;/p&gt;
&lt;p&gt;Currently working in algorithmic trading at Susquehanna. Previously
designed and built systems at Amazon serving 10M+ monthly active
customers, developed semantic caching for LLMs at Sopra Steria, and
conducted quantitative cybersecurity risk analysis at Deloitte.&lt;/p&gt;</description></item><item><title>About this Site</title><link>https://david.alvarezrosa.com/posts/about-this-website/?utm_source=rss</link><pubDate>Fri, 11 May 2018 21:18:00 +0100</pubDate><guid>https://david.alvarezrosa.com/posts/about-this-website/</guid><description>&lt;p&gt;After nearly a decade, I&amp;rsquo;ve rebuilt my personal site from scratch&amp;mdash;a
blog on software, self-hosting, and lessons learned along the way. This
first post is backdated to when I originally launched a site on this
domain, back in 2018.&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;What?&lt;/strong&gt;&amp;mdash;A personal blog. Posts aim to be concise, practical, and
rigorous.&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Why?&lt;/strong&gt;&amp;mdash;To give back to the &lt;em&gt;libre&lt;/em&gt; software community. To keep a
record of my learning journey. To deepen my own understanding by
writing things down.&lt;sup id="fnref:1"&gt;&lt;a href="#fn:1" class="footnote-ref" role="doc-noteref"&gt;1&lt;/a&gt;&lt;/sup&gt;&lt;/p&gt;</description></item></channel></rss>