gramineproject / gramine

A library OS for Linux multi-process applications, with Intel SGX support
GNU Lesser General Public License v3.0
551 stars 184 forks source link

[common] Update UBSan to be compatible with Clang 18 #1929

Open dimakuv opened 4 days ago

dimakuv commented 4 days ago

Description of the changes

Newer Clang versions added more UBSan checks, in particular:

This commit adds the scaffolding for the second (new) check plus fixes the places triggered by this check. This commit also fixes UBs found by the extended first check.

See:

How to test this PR?

CI is enough for older UBSan versions. To test newer UBSan versions, run on Ubuntu 24.04 (and default Clang version there, which is v18).


This change is Reviewable