Follow @Openwall on Twitter for new release announcements and other news
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20260513111717.744ab815@inria.fr>
Date: Wed, 13 May 2026 11:17:17 +0200
From: Jₑₙₛ Gustedt <jens.gustedt@...ia.fr>
To: Florian Schmaus <florian.schmaus@...asip.com>
Cc: musl@...ts.openwall.com, dalias@...c.org, tg@...bsd.de
Subject: Re: [PATCH v2] qsort: align 'tmp' buffer to preserve CHERI
 capabilities

Florian,

on Wed, 13 May 2026 10:21:46 +0200 you (Florian Schmaus
<florian.schmaus@...asip.com>) wrote:

> ...

> By changing the buffer type to a union with a pointer member we force
> the compiler to align the stack allocation to the architectural
> pointer/capability alignment boundary. This ensures that capabilities
> stored in the buffer retain their tags and remain valid.

wouldn't it be simpler to us `_Alignas`? There seem already some
usages of that feature in musl, so that should not be a problem, I
guess.

Thanks
Jₑₙₛ

-- 
:: ICube :::::::::::::::::::::::::::::: deputy director ::
:: Université de Strasbourg :::::::::::::::::::::: ICPS ::
:: INRIA antenne de Strasbourg :::::::::::::::::: Camus ::
:: INRIA PIQ program Strasbourg :::::::::: piq.inria.fr ::
:: :::::::::::::::::::::::::::::::::::: ☎ +33 368854536 ::
:: https://icube-icps.unistra.fr/index.php/Jens_Gustedt ::

Powered by blists - more mailing lists

Confused about mailing lists and their use? Read about mailing lists on Wikipedia and check out these guidelines on proper formatting of your messages.