466
|
1 <preface>
|
|
2 <title>Differences between Versions 1.1 and 1.0</title>
|
612
|
3 <caution>
|
|
4 <title>Important Notice - Please Read Carefully</title>
|
466
|
5 <para>
|
|
6 This package contains the OS-9 C Compiler Version 1.1. Many
|
|
7 improvements and bug fixes have been incorporated since the V1.0
|
468
|
8 release. If you are upgrading from V1.0, be <emphasis>absolutely sure</emphasis>
|
|
9 to all <emphasis>all</emphasis> the files from the V1.1 disks. None of the
|
|
10 compiler sections or the library is compatible with V1.0 files. Any ".r" or
|
|
11 ".a" files produced by the V1.0 compiler should not be assembled or
|
|
12 linked with any ".a" or ".r" files produced by the V1.1 compiler.
|
|
13 To be safe, recompile/reassemble <emphasis>all</emphasis> ".a" and ".r"
|
|
14 files with V.1.1.
|
466
|
15 </para>
|
|
16 <para>
|
468
|
17 This update include appendices for the C Compiler User's Guide
|
|
18 describing the compiler error messages, compiler phase command
|
|
19 lines, interfacing C functions to BASIC09, and an overview of the
|
|
20 relocating macro assembler.
|
466
|
21 </para>
|
|
22 <para>
|
|
23 The remainder of this notice describes the changes made since V1.0.
|
|
24 </para>
|
612
|
25 </caution>
|
468
|
26
|
|
27 <variablelist>
|
|
28 <varlistentry><term>General:</term>
|
|
29 <listitem>
|
|
30 <para>
|
|
31 The compiler code generator and c.opt have been improved to
|
|
32 produce even smaller object code. This, and improved source
|
|
33 coding, has resulted in a 1 page decrease in the size of c.comp
|
|
34 and a 4 page decrease in c.pass1.
|
|
35 </para>
|
|
36 </listitem>
|
|
37 </varlistentry>
|
|
38
|
532
|
39 <varlistentry><term>Executives (cc1 and cc2):</term>
|
|
40 <listitem>
|
|
41 <para>
|
612
|
42 -x appearing on the cc1 command line causes the compiler to
|
|
43 make the c.com command file but not execute it. -q on the cc2
|
|
44 command line causes the compiler to suppress filename and
|
|
45 compiler phase messages.
|
532
|
46 </para>
|
|
47 </listitem>
|
|
48 </varlistentry>
|
|
49
|
|
50 <varlistentry><term>Preprocessor (c.prep):</term>
|
|
51 <listitem>
|
|
52 <para>
|
655
|
53 C.prep now prints a fatal error if a line exceeds 255 bytes.
|
532
|
54 </para>
|
|
55 </listitem>
|
|
56 </varlistentry>
|
|
57
|
|
58 <varlistentry><term>Compiler (c.comp, c.pass1, c.pass2):</term>
|
|
59 <listitem>
|
|
60 <para>
|
612
|
61 C.pass1 float/double conversion is now done properly rather
|
|
62 than reporting error 7.
|
|
63 </para>
|
|
64 <para>
|
|
65 Direct and static direct storage classes may now be
|
|
66 initialized.
|
|
67 </para>
|
|
68 <para>
|
|
69 Sizeof operator now reports an error when applied to an
|
|
70 undefined identifier. Sizeof now allows any expression inside
|
|
71 of parenthesis. Previously, only primaries were allowed.
|
|
72 </para>
|
|
73 <para>
|
|
74 Various code generation problems involving certain long and
|
|
75 floating operations have been fixed.
|
532
|
76 </para>
|
|
77 </listitem>
|
|
78 </varlistentry>
|
|
79
|
|
80 <varlistentry><term>Optimizer (c.opt):</term>
|
|
81 <listitem>
|
|
82 <para>
|
|
83 C.opt has been improved to use much less dynamic memory while
|
|
84 performing optimizations.
|
|
85 </para>
|
|
86 <para>
|
|
87 Some branches were erroneously converted to short branches
|
|
88 when they should have been long.
|
|
89 </para>
|
|
90 </listitem>
|
|
91 </varlistentry>
|
|
92
|
|
93 <varlistentry><term>Assembler (c.asm):</term>
|
|
94 <listitem>
|
|
95 <para>
|
612
|
96 C.asm can now handle direct-page initialized data.
|
|
97 </para>
|
|
98 <para>
|
|
99 Some out-of-range short branches were not detected.
|
|
100 </para>
|
|
101 <para>
|
|
102 VSECT syntax changed to allow direct-page initializers. This
|
|
103 make V1.0 assembly file incompatible with V1.1.
|
|
104 </para>
|
|
105 <para>
|
|
106 Macro and repeat block facilities have been added.
|
532
|
107 </para>
|
|
108 </listitem>
|
|
109 </varlistentry>
|
|
110
|
|
111 <varlistentry><term>Linker (c.link):</term>
|
655
|
112 <listitem><para>
|
532
|
113 C.link can now handle direct-page initialized data.
|
|
114 </para>
|
|
115 <para>
|
|
116 C.link will now report if the direct page allocations exceeds 256 bytes.
|
|
117 </para>
|
|
118 <para>
|
|
119 C.link is about three times faster using the improved V1.1 standard library.
|
|
120 </para>
|
|
121 <para>
|
|
122 C.link can now output modules that can be entered by the BASIC09 "RUN" command.
|
|
123 </para>
|
|
124 </listitem>
|
|
125 </varlistentry>
|
|
126
|
|
127 <varlistentry><term>Library (clib.l):</term>
|
655
|
128 <listitem><para>
|
612
|
129 The standard library FILE structure has been changed to allow
|
|
130 specification of buffersize for a file. In V1.0, the
|
|
131 buffersize was fixed at 256 bytes. A new element of the FILE
|
|
132 struct (_bufsiz) contains the desired buffer size. This may be
|
|
133 used as follows:
|
|
134 <programlisting>
|
|
135 main()
|
|
136 {
|
|
137 FILE *fp;
|
|
138
|
|
139 fp=fopen("file","r");
|
|
140 fp->_bufsiz = 1024;
|
|
141
|
|
142 .....
|
|
143 }
|
|
144 </programlisting>
|
|
145 A few restrictions exist on the use of this parameter.
|
|
146 Initially the _bufsiz value is 0. The library routines will
|
|
147 assign a buffer of 256 bytes to the file upon initial read
|
|
148 or write. If the value is non-zero and the fp has not
|
|
149 previously been accessed, that value is used as the
|
|
150 buffersize. Note that due to the way the library routines
|
|
151 work, once a buffer of a given size is allocated to an fp, a
|
|
152 larger size cannot be used, even if the file is closed. Note
|
|
153 that the buffers are allocated from the ibrk() so enough extra
|
|
154 memory must be allocated by the linker to handle the bigger
|
|
155 buffers.
|
|
156 </para>
|
|
157 <para>
|
|
158 Since the size of the _iobuf struct (FILE) in stdio.h has
|
|
159 changed, all .r files must be re-compiled using the new header
|
|
160 file.
|
|
161 </para>
|
|
162 <para>
|
|
163 Cstart.r can now handle direct page data initialization.
|
|
164 </para>
|
|
165 <para>
|
|
166 Fseek() now does not cause the buffer to be re-filled if the
|
|
167 seek destination is already in the buffer.
|
|
168 </para>
|
|
169 <para>
|
|
170 Getc() now does "I$READ" on unbuffered SCF devices rather than
|
|
171 "I$READLN".
|
|
172 </para>
|
|
173 <para>
|
|
174 Getc() performed on "stdin" flushes the "stdout" buffer.
|
|
175 </para>
|
|
176 <para>
|
|
177 Printf() has been changed to not flush the "stdout" buffer
|
|
178 before returning.
|
|
179 </para>
|
|
180 <para>
|
|
181 Chown() has been fixed to not wipe out disks.
|
|
182 </para>
|
|
183 <para>
|
|
184 Toascii() has been added to stdio.h
|
|
185 </para>
|
|
186 <para>
|
|
187 Calls to scanf() now do not cause the linker to reports
|
|
188 unresolved references to toupper() and tolower().
|
|
189 </para>
|
|
190 <para>
|
|
191 The floating point routines now report errors 40, 41, and 42
|
|
192 for floating point over/underflow, divide by zero, and
|
|
193 float/long conversion instead of error #007.
|
532
|
194 </para>
|
|
195 </listitem>
|
|
196 </varlistentry>
|
468
|
197
|
|
198 </variablelist>
|
466
|
199 </preface>
|