Snitch Runtime
Loading...
Searching...
No Matches
sync_decls.h
1// Copyright 2023 ETH Zurich and University of Bologna.
2// Licensed under the Apache License, Version 2.0, see LICENSE for details.
3// SPDX-License-Identifier: Apache-2.0
4
5#pragma once
6
7#include <stdint.h>
8
9typedef struct {
10 uint32_t volatile cnt;
11 uint32_t volatile iteration;
13
14extern volatile uint32_t _snrt_mutex;
15extern volatile snrt_barrier_t _snrt_barrier;
16extern volatile uint32_t _reduction_result;
17
18inline volatile uint32_t *snrt_mutex();
19
20inline void snrt_mutex_acquire(volatile uint32_t *pmtx);
21
22inline void snrt_mutex_ttas_acquire(volatile uint32_t *pmtx);
23
24inline void snrt_mutex_release(volatile uint32_t *pmtx);
25
26inline void snrt_cluster_hw_barrier();
27
28inline void snrt_global_barrier();
29
30inline uint32_t snrt_global_all_to_all_reduction(uint32_t value);
Definition sync_decls.h:9