1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
|
/* $OpenBSD: infinity.c,v 1.2 2004/02/01 05:40:52 drahn Exp $ */
/* $NetBSD: infinity.c,v 1.3 2002/02/19 20:08:19 bjh21 Exp $ */
/*
* IEEE-compatible infinity.c -- public domain.
*/
#include <sys/types.h>
#include <math.h>
#include <machine/endian.h>
char __infinity[] __attribute__((__aligned__(sizeof(double)))) =
#if BYTE_ORDER == BIG_ENDIAN
{ { 0x7f, 0xf0, 0, 0, 0, 0, 0, 0} };
#else
#ifdef __VFP_FP__
{ { 0, 0, 0, 0, 0, 0, 0xf0, 0x7f} };
#else
{ { 0, 0, 0xf0, 0x7f, 0, 0, 0, 0} };
#endif
#endif
|