/* Copyright (C) 2008 - Ruben Niederhagen
 * This program is free software; you can redistribute it and/or
 * modify it under the terms of the GNU General Public License
 * as published by the Free Software Foundation; either version 3
 * of the License, or (at your option) any later version.
 *
 * This program is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * You should have received a copy of the GNU General Public License
 * along with this program; if not, you will find it online at
 * http://www.gnu.org/licenses/gpl.html
 */

#ifndef _IOLAOS_SRC_COMMON_H_
#define _IOLAOS_SRC_COMMON_H_

#include "include/types.h"

#ifdef __cplusplus
extern "C" {
#endif

typedef struct
{
    addr64_t global_data;
    addr64_t local_stores;
    addr64_t barrier_cacheline;

	uint16_t global_data_size;

    uint8_t spe_threads;

    uint8_t pad[64 - 3*8 - 2 - 1];
} global_parameters_t;

typedef struct
{
	addr64_t local_data;

	uint16_t local_data_size;

	uint8_t id;
	uint8_t pad[16 - 1*8 - 2 - 1];
} local_parameters_t;

#ifdef __cplusplus
}
#endif

#endif /* _IOLAOS_SRC_COMMON_H_ */

