[*] Linux/Clang fixerinos/improvements

This commit is contained in:
Reece Wilson 2023-08-28 16:34:21 +01:00
parent 55c02d4aa0
commit 0d759f85f8
3 changed files with 11 additions and 5 deletions

View File

@ -12,6 +12,12 @@
#include "AuIngestableReadBase.inl"
#include "AuBaseStream.hpp"
#if defined(AURORA_COMPILER_CLANG)
// warning: non-void function does not return a value in all control paths [-Wreturn-type]
#pragma clang diagnostic ignored "-Wreturn-type"
// one of my no returns is broken :(
#endif
namespace Aurora::Compression
{
AuStreamReadWrittenPair_t BaseStream::ReadEx(const AuMemoryViewWrite &/*optional/nullable*/destination,

View File

@ -142,7 +142,7 @@ namespace Aurora::Threading::Primitives
AuUInt32 uWaitCount {};
AuUInt32 uWaiters {};
while (uWaiters = AuAtomicLoad(&this->uWaiters_))
while ((uWaiters = AuAtomicLoad(&this->uWaiters_)))
{
this->s_.Unlock(uWaiters);
uWaitCount = uWaiters;

View File

@ -421,12 +421,12 @@ namespace Aurora::Time
#endif
ADD_CLOCK_FAMILY(Process, Process, (ullUser.QuadPart + ullKernel.QuadPart), CLOCK_PROCESS_CPUTIME_ID, (false, EPseudoPosixClock::eAll));
ADD_CLOCK_FAMILY(Process, Process, (ullUser.QuadPart + ullKernel.QuadPart), /*CLOCK_PROCESS_CPUTIME_ID*/ 0, (false, EPseudoPosixClock::eAll));
ADD_CLOCK_FAMILY(ProcessKernel, Process, (ullKernel.QuadPart), 0, (false, EPseudoPosixClock::eKernel));
ADD_CLOCK_FAMILY(ProcessUser, Process, (ullUser.QuadPart), CLOCK_PROCESS_CPUTIME_ID, (false, EPseudoPosixClock::eUser));
ADD_CLOCK_FAMILY(Thread, Thread, (ullUser.QuadPart + ullKernel.QuadPart), CLOCK_THREAD_CPUTIME_ID, (true, EPseudoPosixClock::eAll));
ADD_CLOCK_FAMILY(ProcessUser, Process, (ullUser.QuadPart), /*CLOCK_PROCESS_CPUTIME_ID*/0, (false, EPseudoPosixClock::eUser));
ADD_CLOCK_FAMILY(Thread, Thread, (ullUser.QuadPart + ullKernel.QuadPart), /*CLOCK_THREAD_CPUTIME_ID*/0, (true, EPseudoPosixClock::eAll));
ADD_CLOCK_FAMILY(ThreadKernel, Thread, (ullKernel.QuadPart), 0, (true, EPseudoPosixClock::eKernel));
ADD_CLOCK_FAMILY(ThreadUser, Thread, (ullUser.QuadPart), CLOCK_THREAD_CPUTIME_ID, (true, EPseudoPosixClock::eUser));
ADD_CLOCK_FAMILY(ThreadUser, Thread, (ullUser.QuadPart), /*CLOCK_THREAD_CPUTIME_ID*/0, (true, EPseudoPosixClock::eUser));
AUKN_SYM AuInt64 ConvertAuroraToUnixMS(AuInt64 in)
{