26#include "platform/lf_atomic.h"
52#if defined(PLATFORM_ARDUINO)
53#include "platform/lf_arduino_support.h"
54#elif defined(PLATFORM_ZEPHYR)
55#include "platform/lf_zephyr_support.h"
56#elif defined(PLATFORM_NRF52)
57#include "platform/lf_nrf52_support.h"
58#elif defined(PLATFORM_PATMOS)
59#include "platform/lf_patmos_support.h"
60#elif defined(PLATFORM_RP2040)
61#include "platform/lf_rp2040_support.h"
62#elif defined(PLATFORM_FLEXPRET)
63#include "platform/lf_flexpret_support.h"
64#elif defined(WIN32) || defined(_WIN32) || defined(__WIN32__) || defined(__NT__)
66#include "platform/lf_windows_support.h"
69#include "platform/lf_macos_support.h"
72#include "platform/lf_linux_support.h"
75#include "platform/lf_POSIX_threads_support.h"
76#elif defined(_POSIX_VERSION)
78#include "platform/lf_POSIX_threads_support.h"
79#elif defined(__riscv) || defined(__riscv__)
81#error "RISC-V not supported"
83#error "Platform not supported"
89#define LF_SCHED_MAX_PRIORITY 99
90#define LF_SCHED_MIN_PRIORITY 0
94#if defined(LF_SINGLE_THREADED)
98typedef void* lf_mutex_t;
108int lf_disable_interrupts_nested(
void);
115int lf_enable_interrupts_nested(
void);
122int _lf_single_threaded_notify_of_event(
void);
307#if __STDC_VERSION__ >= 201112 && !defined __STDC_NO_THREADS__
308#define thread_local _Thread_local
309#elif defined _WIN32 && (defined _MSC_VER || defined __ICL || defined __DMC__ || defined __BORLANDC__)
310#define thread_local __declspec(thread)
312#elif defined __GNUC__ || defined __SUNPRO_C || defined __xlC__
313#define thread_local __thread
315#error "Cannot define thread_local"
384#define DEPRECATED(X) X __attribute__((deprecated))
385#elif defined(_MSC_VER)
386#define DEPRECATED(X) __declspec(deprecated) X
388#define DEPRECATED(X) X
int64_t instant_t
Time instant.
Definition tag.h:101
int64_t interval_t
Interval of time.
Definition tag.h:107
Execution environment.
Definition environment.h:52
lf_mutex_t mutex
Mutex for synchronizing access to the environment.
Definition environment.h:295
A struct supporting thread scheduling policies.
Definition low_level_platform.h:181
interval_t time_slice
Definition low_level_platform.h:184
lf_scheduling_policy_type_t policy
Definition low_level_platform.h:182
int priority
Definition low_level_platform.h:183
Time and tag definitions and functions for Lingua Franca.