use [[gnu::...]] attributes

This commit is contained in:
Max Kellermann
2023-03-06 15:57:36 +01:00
parent 3b9aab0684
commit 42f6a0441c
101 changed files with 167 additions and 234 deletions

View File

@@ -2,7 +2,6 @@
// Copyright The Music Player Daemon Project
#include "Serial.hxx"
#include "Compiler.h"
#include <atomic>
#include <chrono>
@@ -13,7 +12,7 @@ int
GenerateSerial() noexcept
{
unsigned serial = ++next_serial;
if (gcc_unlikely(serial < 16)) {
if (serial < 16) [[unlikely]] {
/* first-time initialization: seed with a clock value,
which is random enough for our use */