Add define for Kirk Smith's USR Courier driver. Change default baud
[unix-history] / usr / src / usr.bin / f77 / libF77 / range.c
CommitLineData
eaef4d9b 1/*
be6e3ddf
RE
2 * Copyright (c) 1980 Regents of the University of California.
3 * All rights reserved. The Berkeley software License Agreement
4 * specifies the terms and conditions for redistribution.
eaef4d9b 5 *
bb3ec388
RE
6 * @(#)range.c 5.2 %G%
7 *
eaef4d9b
DW
8 * routines to return extreme values
9 * VERY MACHINE DEPENDENT
10 */
11
12union fi
13{ float f;
14 long i;
15} ;
16
17union dj
18{ double d;
19 long j[2];
20} ;
21
22float
23flmax_()
24{
25 union fi n;
775a163d 26#if pdp11
eaef4d9b 27 n.i = 0x7fffffffL;
775a163d
DW
28#else pdp11
29#if vax
eaef4d9b 30 n.i = 0xffff7fff;
775a163d
DW
31#else vax
32 UNKNOWN MACHINE!
33#endif vax
34#endif pdp11
eaef4d9b
DW
35 return(n.f);
36}
37
38double
39dflmax_()
40{
41 union dj n;
775a163d 42#if pdp11
eaef4d9b
DW
43 n.j[0] = 0x7fffffffL;
44 n.j[1] = 0xffffffffL;
775a163d
DW
45#else pdp11
46#if vax
eaef4d9b
DW
47 n.j[0] = 0xffff7fff;
48 n.j[1] = 0xffffffff;
775a163d
DW
49#else vax
50 UNKNOWN MACHINE!
51#endif vax
52#endif pdp11
eaef4d9b
DW
53 return(n.d);
54}
55
56float
57flmin_()
58{
59 union fi n;
775a163d 60#if pdp11
eaef4d9b 61 n.i = 0x00800000L;
775a163d
DW
62#else pdp11
63#if vax
eaef4d9b 64 n.i = 0x00000080;
775a163d
DW
65#else vax
66 UNKNOWN MACHINE!
67#endif vax
68#endif pdp11
eaef4d9b
DW
69 return(n.f);
70}
71
72double
73dflmin_()
74{
75 union dj n;
775a163d 76#if pdp11
eaef4d9b
DW
77 n.j[0] = 0x00800000L;
78 n.j[1] = 0;
775a163d
DW
79#else pdp11
80#if vax
eaef4d9b
DW
81 n.j[0] = 0x00000080;
82 n.j[1] = 0;
775a163d
DW
83#else vax
84 UNKNOWN MACHINE!
85#endif vax
86#endif pdp11
eaef4d9b
DW
87 return(n.d);
88}
89
90long int
91inmax_()
92{
775a163d 93 return(0x7fffffffL);
eaef4d9b
DW
94}
95
775a163d
DW
96
97float
98ffrac_()
99{
100 union fi n;
101#if pdp11
102 n.i = 0x35000000L;
103#else pdp11
104#if vax
105 n.i = 0x00003500;
106#else vax
107 UNKNOWN MACHINE!
108#endif vax
109#endif pdp11
110 return(n.f);
111}
112
113double
114dffrac_()
115{
116 union dj n;
117#if pdp11
118 n.j[0] = 0x25000000L;
119 n.j[1] = 0;
120#else pdp11
121#if vax
122 n.j[0] = 0x00002500;
123 n.j[1] = 0;
124#else vax
125 UNKNOWN MACHINE!
126#endif vax
127#endif pdp11
128 return(n.d);
129}