2011-06-08 20:43:34 +02:00
|
|
|
/*
|
|
|
|
* Copyright (c) 2011 The WebM project authors. All Rights Reserved.
|
|
|
|
*
|
|
|
|
* Use of this source code is governed by a BSD-style license
|
|
|
|
* that can be found in the LICENSE file in the root of the source
|
|
|
|
* tree. An additional intellectual property rights grant can be found
|
|
|
|
* in the file PATENTS. All contributing project authors may
|
|
|
|
* be found in the AUTHORS file in the root of the source tree.
|
|
|
|
*/
|
|
|
|
|
|
|
|
|
2013-12-16 03:36:00 +01:00
|
|
|
#ifndef VPX_PORTS_ASM_OFFSETS_H_
|
|
|
|
#define VPX_PORTS_ASM_OFFSETS_H_
|
2011-06-08 20:43:34 +02:00
|
|
|
|
|
|
|
#include <stddef.h>
|
|
|
|
|
|
|
|
#define ct_assert(name,cond) \
|
2012-07-14 00:21:29 +02:00
|
|
|
static void assert_##name(void) UNUSED;\
|
|
|
|
static void assert_##name(void) {switch(0){case 0:case !!(cond):;}}
|
2011-06-08 20:43:34 +02:00
|
|
|
|
2012-11-02 23:39:14 +01:00
|
|
|
#if INLINE_ASM
|
|
|
|
#define DEFINE(sym, val) asm("\n" #sym " EQU %0" : : "i" (val))
|
2011-06-08 20:43:34 +02:00
|
|
|
#define BEGIN int main(void) {
|
|
|
|
#define END return 0; }
|
|
|
|
#else
|
2012-11-02 23:39:14 +01:00
|
|
|
#define DEFINE(sym, val) const int sym = val
|
2011-06-08 20:43:34 +02:00
|
|
|
#define BEGIN
|
|
|
|
#define END
|
|
|
|
#endif
|
|
|
|
|
2013-12-16 03:36:00 +01:00
|
|
|
#endif // VPX_PORTS_ASM_OFFSETS_H_
|