SpiNNFrontEndCommon 7.1.1
Common support code for user-facing front end systems.
Loading...
Searching...
No Matches
data_specification.h
Go to the documentation of this file.
1/*
2 * Copyright (c) 2014 The University of Manchester
3 *
4 * Licensed under the Apache License, Version 2.0 (the "License");
5 * you may not use this file except in compliance with the License.
6 * You may obtain a copy of the License at
7 *
8 * https://www.apache.org/licenses/LICENSE-2.0
9 *
10 * Unless required by applicable law or agreed to in writing, software
11 * distributed under the License is distributed on an "AS IS" BASIS,
12 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 * See the License for the specific language governing permissions and
14 * limitations under the License.
15 */
16
25#ifndef _DATA_SPECIFICATION_H_
26#define _DATA_SPECIFICATION_H_
27
28#include <stdbool.h>
29#include "common-typedefs.h"
30
31typedef struct region_desc_t {
32 void *pointer;
34 uint32_t checksum;
36 uint32_t n_words;
38
52
62
74
82 uint32_t region, data_specification_metadata_t *ds_regions) {
83 return ds_regions->regions[region].pointer;
84}
85
86#endif
Data type definitions for SpiNNaker Neuron-modelling.
data_specification_metadata_t * data_specification_get_data_address(void)
Gets the location of the data for this core using the user0 entry of the SARK VCPU structure.
uint32_t n_words
The number of valid words in the region.
region_desc_t regions[]
The regions; as many as required.
uint32_t checksum
Simple checksum which is rounded 32-bit unsigned sum of words.
uint32_t magic_number
A magic number, used to verify that the pointer is sane.
uint32_t version
The version of the DSE data layout specification being followed.
bool data_specification_read_header(data_specification_metadata_t *ds_regions)
Reads the header from the address given and checks if the parameters are of the correct values.
static void * data_specification_get_region(uint32_t region, data_specification_metadata_t *ds_regions)
Gets the address of a region.
The central structure that the DSE writes.