2023-05-31 16:19:06 +02:00
|
|
|
/* SPDX-FileCopyrightText: 2016 by Mike Erwin. All rights reserved.
|
|
|
|
|
*
|
|
|
|
|
* SPDX-License-Identifier: GPL-2.0-or-later */
|
2018-07-17 14:46:44 +02:00
|
|
|
|
2019-02-18 08:08:12 +11:00
|
|
|
/** \file
|
|
|
|
|
* \ingroup gpu
|
2018-07-17 14:46:44 +02:00
|
|
|
*/
|
|
|
|
|
|
2018-07-18 00:12:21 +02:00
|
|
|
#pragma once
|
2016-09-13 02:18:33 -04:00
|
|
|
|
2018-03-30 23:27:45 +02:00
|
|
|
#define PROGRAM_NO_OPTI 0
|
2021-04-30 11:20:39 -03:00
|
|
|
//#define GPU_NO_USE_PY_REFERENCES
|
2018-03-30 23:27:45 +02:00
|
|
|
|
2017-04-18 11:35:56 -04:00
|
|
|
#if defined(NDEBUG)
|
2018-07-19 16:06:37 +10:00
|
|
|
# define TRUST_NO_ONE 0
|
2017-04-20 10:59:28 +02:00
|
|
|
#else
|
2018-07-17 14:46:44 +02:00
|
|
|
/* strict error checking, enabled for debug builds during early development */
|
2018-07-19 16:06:37 +10:00
|
|
|
# define TRUST_NO_ONE 1
|
2017-04-18 11:35:56 -04:00
|
|
|
#endif
|
2016-09-13 02:18:33 -04:00
|
|
|
|
2020-03-19 09:33:03 +01:00
|
|
|
#include "BLI_sys_types.h"
|
2016-09-13 02:18:33 -04:00
|
|
|
#include <stdbool.h>
|
2016-09-13 03:21:16 -04:00
|
|
|
#include <stdint.h>
|
2016-09-13 02:18:33 -04:00
|
|
|
|
|
|
|
|
#if TRUST_NO_ONE
|
2018-07-19 16:06:37 +10:00
|
|
|
# include <assert.h>
|
2016-09-13 02:18:33 -04:00
|
|
|
#endif
|
2017-06-29 20:09:05 +10:00
|
|
|
|
2018-07-18 00:12:21 +02:00
|
|
|
/* GPU_INLINE */
|
2017-06-29 20:09:05 +10:00
|
|
|
#if defined(_MSC_VER)
|
2018-07-18 00:12:21 +02:00
|
|
|
# define GPU_INLINE static __forceinline
|
2017-06-29 20:09:05 +10:00
|
|
|
#else
|
2018-07-18 00:12:21 +02:00
|
|
|
# define GPU_INLINE static inline __attribute__((always_inline)) __attribute__((__unused__))
|
2018-06-08 14:55:47 +02:00
|
|
|
#endif
|