code: Add clang-format target and CI workflow (#82)

* code: Add clang format target, rules and CI workflow

* code: Run clang format on sources
This commit is contained in:
GPUCode
2024-02-23 22:57:57 +02:00
committed by GitHub
parent 32a5ff15bb
commit 6f4c6ae0bb
90 changed files with 2942 additions and 1941 deletions

View File

@@ -1,9 +1,9 @@
// SPDX-FileCopyrightText: Copyright 2020 yuzu Emulator Project
// SPDX-License-Identifier: GPL-2.0-or-later
#include "common/uint128.h"
#include "common/native_clock.h"
#include "common/rdtsc.h"
#include "common/uint128.h"
#ifdef _WIN64
#include <pthread_time.h>
#else
@@ -13,8 +13,8 @@
namespace Common {
NativeClock::NativeClock()
: rdtsc_frequency{EstimateRDTSCFrequency()}, ns_rdtsc_factor{GetFixedPoint64Factor(std::nano::den,
rdtsc_frequency)},
: rdtsc_frequency{EstimateRDTSCFrequency()}, ns_rdtsc_factor{GetFixedPoint64Factor(
std::nano::den, rdtsc_frequency)},
us_rdtsc_factor{GetFixedPoint64Factor(std::micro::den, rdtsc_frequency)},
ms_rdtsc_factor{GetFixedPoint64Factor(std::milli::den, rdtsc_frequency)} {}
@@ -40,4 +40,4 @@ u64 NativeClock::GetProcessTimeUS() const {
return ret.tv_nsec / 1000 + ret.tv_sec * 1000000;
}
} // namespace Common::X64
} // namespace Common