[*] eepy
This commit is contained in:
parent
6037d14674
commit
7b59cab36e
@ -14,22 +14,24 @@ namespace Aurora::Async
|
||||
virtual AuSPtr<IWorkItem> WaitFor(const AuSPtr<IWorkItem> &pWorkItem) = 0;
|
||||
virtual AuSPtr<IWorkItem> WaitFor(const AuList<AuSPtr<IWorkItem>> &workItems) = 0;
|
||||
|
||||
// do not schedule a loop-source more than once
|
||||
// you may ILoopSource::WaitOn arbitrarily; however, you must not attach it to the threads loopqueue more than once.
|
||||
virtual AuSPtr<IWorkItem> SetSchedByLoopSource(const AuSPtr<IO::Loop::ILoopSource> &pLoopSource) = 0;
|
||||
|
||||
// ms = time relative to the current time
|
||||
// ms = time relative to the current time in milliseconds
|
||||
virtual AuSPtr<IWorkItem> SetSchedTime(AuUInt32 ms) = 0;
|
||||
|
||||
// ns = Aurora::Time::CurrentClockMS() + relativeMs
|
||||
virtual AuSPtr<IWorkItem> SetSchedTimeAbs(AuUInt32 ms) = 0;
|
||||
|
||||
// ns = time relative to the current time
|
||||
// ns = time relative to the current time in nanoseconds
|
||||
virtual AuSPtr<IWorkItem> SetSchedTimeNs(AuUInt64 ns) = 0;
|
||||
|
||||
// ns = Aurora::Time::CurrentClockNS() + relativeNs
|
||||
// ms = wall time (AuTime::CurrentClockMS()) in milliseconds
|
||||
virtual AuSPtr<IWorkItem> SetSchedTimeAbs(AuUInt32 ms) = 0;
|
||||
|
||||
// ns = wall time (AuTime::CurrentClockNS()) in nanoseconds
|
||||
virtual AuSPtr<IWorkItem> SetSchedTimeNsAbs(AuUInt64 ns) = 0;
|
||||
|
||||
// ns = Aurora::Time::SteadyClockNS() + relativeNs
|
||||
virtual AuSPtr<IWorkItem> SetSchedSteadyTimeNsAbs(AuUInt64 ns) = 0;
|
||||
// ns = steady time (AuTime::SteadyClockNS()) in nanoseconds
|
||||
virtual AuSPtr<IWorkItem> SetSchedSteadyTimeNsAbs(AuUInt64 ns) = 0;
|
||||
|
||||
// ms = time relative to the time at which the work item would otherwise dispatch
|
||||
virtual AuSPtr<IWorkItem> AddDelayTime(AuUInt32 ms) = 0;
|
||||
@ -42,7 +44,7 @@ namespace Aurora::Async
|
||||
|
||||
virtual AuSPtr<IWorkItem> Dispatch() = 0;
|
||||
|
||||
virtual void SetPrio(EWorkPriority prio) = 0;
|
||||
virtual void SetPrio(EWorkPriority prio) = 0;
|
||||
|
||||
virtual bool BlockUntilComplete() = 0;
|
||||
virtual bool HasFinished() = 0;
|
||||
|
@ -52,12 +52,9 @@ namespace Aurora::IO::Loop
|
||||
virtual bool SourceRemove(const AuSPtr<ILoopSource> &source) = 0;
|
||||
|
||||
/**
|
||||
* @brief Updates the OS watchdog list cache concept after Source[Remove/Add[WithTimeout]]
|
||||
* @brief Updates the OS watch list after Source[Remove/Add[WithTimeout]]
|
||||
* Commits may occur while another thread is waiting on the loop queue.
|
||||
* In those circumstances, they are internally preempted and rescheduled.
|
||||
* WaitAnd has undefined behaviour across MT commit. Linux *might* work.
|
||||
* NT wont until an APC-as-a-preempt-signal hack is implemented.
|
||||
* Rare edge case for all i care - it'll remain a blocking edge case for.now.
|
||||
* @return
|
||||
* @note thread safe
|
||||
*/
|
||||
|
@ -28,7 +28,7 @@ namespace Aurora::RNG
|
||||
AUKN_SYM double RngDecimal();
|
||||
AUKN_SYM float RngNumber(float min, float max);
|
||||
AUKN_SYM AuUInt32 RngIndex(AuUInt32 count /* = max + 1*/);
|
||||
|
||||
AUKN_SYM uuids::uuid RngUUID();
|
||||
|
||||
// Note: it is conceivable that someone may want the following templates for some cryptographic purpose
|
||||
|
||||
|
@ -224,7 +224,7 @@ namespace Aurora
|
||||
AuUInt64 bPreferLinuxAdaptiveSpin : 1 { true }; // (&&)
|
||||
AuUInt64 bPreferOldWin32AdaptiveSpin : 1 { false }; // (&&)
|
||||
AuUInt64 bPreferNewWin32AdaptiveSpin : 1 { true }; // (&&)
|
||||
AuUInt64 uAdaptiveSpinCUCnt0 : 4 { 0 } ;
|
||||
AuUInt64 uAdaptiveSpinCUCnt0 : 4 { 0 };
|
||||
AuUInt64 uAdaptiveSpinCUCnt4 : 4 { 2 };
|
||||
AuUInt64 uAdaptiveSpinCUCnt8 : 4 { 2 };
|
||||
AuUInt64 uAdaptiveSpinCUCnt16 : 4 { 4 };
|
||||
|
@ -14,7 +14,7 @@
|
||||
|
||||
namespace Aurora::Threading::Primitives
|
||||
{
|
||||
static const auto kDefaultPrimitiveSize64 = 128;
|
||||
static const auto kDefaultPrimitiveSize64 = 32;
|
||||
|
||||
// Define all the sizes of the primitives on each platform by word-size, preprocessed to filter irrelevant/unknown architectures:
|
||||
#if defined(AURORA_ARCH_X64) || defined(AURORA_ARCH_X86)
|
||||
|
@ -67,4 +67,9 @@ namespace Aurora::RNG
|
||||
{
|
||||
return gFastDevice->NextIndex(uCount);
|
||||
}
|
||||
|
||||
AUKN_SYM uuids::uuid RngUUID()
|
||||
{
|
||||
return gFastDevice->NextUUID();
|
||||
}
|
||||
}
|
Loading…
Reference in New Issue
Block a user