OSDN Git Service

1412b0b980dd4c522dd6867949c39cb22f3dbbdd
[pf3gnuchains/gcc-fork.git] / libgfortran / ChangeLog
1 2009-07-30  Kaz Kojima  <kkojima@gcc.gnu.org>
2
3         * configure.host: Define ieee_flags and set it to -mieee for sh.
4         * configure.ac: Set IEEE_FLAGS with ieee_flags.
5         * Makefile.am: Add IEEE_FLAGS to AM_CFLAGS.
6         * configure: Regenerate.
7         * Makefile.in: Regenerate.
8
9 2009-07-30  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
10
11         * configure.ac (_AC_ARG_VAR_PRECIOUS): Use m4_rename_force.
12
13 2009-07-27  Tobias Burnus  <burnus@net-b.de>
14
15         PR fortran/40863
16         * c99_functions.c: Define complex I, if not defined.
17         Create prototypes for C99 functions to silence warnings.
18         * gfortran.map: Add missing functions to GFORTRAN_C99_1.0
19         and new GFORTRAN_C99_1.1.
20
21 2009-07-25  Tobias Burnus  <burnus@net-b.de>
22
23         PR fortran/33197
24         * intrinsics/c99_functions.c (cacosf,cacos,cacosl,casinf,
25         casin,casind,catanf,catan,catanl,cacoshf,cacosh,cacoshl,
26         casinhf,casinh,casinhf,catanhf,catanh,catanhl): New functions.
27         * c99_protos.h: Add prototypes for those.
28
29 2009-07-24  Jakub Jelinek  <jakub@redhat.com>
30
31         PR fortran/40643
32         PR fortran/31067
33         * libgfortran.h (GFC_REAL_4_INFINITY, GFC_REAL_8_INFINITY,
34         GFC_REAL_10_INFINITY, GFC_REAL_16_INFINITY, GFC_REAL_4_QUIET_NAN,
35         GFC_REAL_8_QUIET_NAN, GFC_REAL_10_QUIET_NAN, GFC_REAL_16_QUIET_NAN):
36         Define.
37         * m4/iparm.m4 (atype_inf, atype_nan): Define.
38         * m4/ifunction.m4: Formatting.
39         * m4/iforeach.m4: Likewise.
40         (START_FOREACH_FUNCTION): Initialize dest to all 1s, not all 0s.
41         (START_FOREACH_BLOCK, FINISH_FOREACH_FUNCTION,
42         FINISH_MASKED_FOREACH_FUNCTION): Run foreach block inside a loop
43         until count[0] == extent[0].
44         * m4/minval.m4: Formatting.  Handle NaNs and infinities.  Optimize.
45         * m4/maxval.m4: Likewise.
46         * m4/minloc0.m4: Likewise.
47         * m4/maxloc0.m4: Likewise.
48         * m4/minloc1.m4: Likewise.
49         * m4/maxloc1.m4: Likewise.
50         * generated/maxloc0_16_i16.c: Regenerated.
51         * generated/maxloc0_16_i1.c: Likewise.
52         * generated/maxloc0_16_i2.c: Likewise.
53         * generated/maxloc0_16_i4.c: Likewise.
54         * generated/maxloc0_16_i8.c: Likewise.
55         * generated/maxloc0_16_r10.c: Likewise.
56         * generated/maxloc0_16_r16.c: Likewise.
57         * generated/maxloc0_16_r4.c: Likewise.
58         * generated/maxloc0_16_r8.c: Likewise.
59         * generated/maxloc0_4_i16.c: Likewise.
60         * generated/maxloc0_4_i1.c: Likewise.
61         * generated/maxloc0_4_i2.c: Likewise.
62         * generated/maxloc0_4_i4.c: Likewise.
63         * generated/maxloc0_4_i8.c: Likewise.
64         * generated/maxloc0_4_r10.c: Likewise.
65         * generated/maxloc0_4_r16.c: Likewise.
66         * generated/maxloc0_4_r4.c: Likewise.
67         * generated/maxloc0_4_r8.c: Likewise.
68         * generated/maxloc0_8_i16.c: Likewise.
69         * generated/maxloc0_8_i1.c: Likewise.
70         * generated/maxloc0_8_i2.c: Likewise.
71         * generated/maxloc0_8_i4.c: Likewise.
72         * generated/maxloc0_8_i8.c: Likewise.
73         * generated/maxloc0_8_r10.c: Likewise.
74         * generated/maxloc0_8_r16.c: Likewise.
75         * generated/maxloc0_8_r4.c: Likewise.
76         * generated/maxloc0_8_r8.c: Likewise.
77         * generated/maxloc1_16_i16.c: Likewise.
78         * generated/maxloc1_16_i1.c: Likewise.
79         * generated/maxloc1_16_i2.c: Likewise.
80         * generated/maxloc1_16_i4.c: Likewise.
81         * generated/maxloc1_16_i8.c: Likewise.
82         * generated/maxloc1_16_r10.c: Likewise.
83         * generated/maxloc1_16_r16.c: Likewise.
84         * generated/maxloc1_16_r4.c: Likewise.
85         * generated/maxloc1_16_r8.c: Likewise.
86         * generated/maxloc1_4_i16.c: Likewise.
87         * generated/maxloc1_4_i1.c: Likewise.
88         * generated/maxloc1_4_i2.c: Likewise.
89         * generated/maxloc1_4_i4.c: Likewise.
90         * generated/maxloc1_4_i8.c: Likewise.
91         * generated/maxloc1_4_r10.c: Likewise.
92         * generated/maxloc1_4_r16.c: Likewise.
93         * generated/maxloc1_4_r4.c: Likewise.
94         * generated/maxloc1_4_r8.c: Likewise.
95         * generated/maxloc1_8_i16.c: Likewise.
96         * generated/maxloc1_8_i1.c: Likewise.
97         * generated/maxloc1_8_i2.c: Likewise.
98         * generated/maxloc1_8_i4.c: Likewise.
99         * generated/maxloc1_8_i8.c: Likewise.
100         * generated/maxloc1_8_r10.c: Likewise.
101         * generated/maxloc1_8_r16.c: Likewise.
102         * generated/maxloc1_8_r4.c: Likewise.
103         * generated/maxloc1_8_r8.c: Likewise.
104         * generated/maxval_i16.c: Likewise.
105         * generated/maxval_i1.c: Likewise.
106         * generated/maxval_i2.c: Likewise.
107         * generated/maxval_i4.c: Likewise.
108         * generated/maxval_i8.c: Likewise.
109         * generated/maxval_r10.c: Likewise.
110         * generated/maxval_r16.c: Likewise.
111         * generated/maxval_r4.c: Likewise.
112         * generated/maxval_r8.c: Likewise.
113         * generated/minloc0_16_i16.c: Likewise.
114         * generated/minloc0_16_i1.c: Likewise.
115         * generated/minloc0_16_i2.c: Likewise.
116         * generated/minloc0_16_i4.c: Likewise.
117         * generated/minloc0_16_i8.c: Likewise.
118         * generated/minloc0_16_r10.c: Likewise.
119         * generated/minloc0_16_r16.c: Likewise.
120         * generated/minloc0_16_r4.c: Likewise.
121         * generated/minloc0_16_r8.c: Likewise.
122         * generated/minloc0_4_i16.c: Likewise.
123         * generated/minloc0_4_i1.c: Likewise.
124         * generated/minloc0_4_i2.c: Likewise.
125         * generated/minloc0_4_i4.c: Likewise.
126         * generated/minloc0_4_i8.c: Likewise.
127         * generated/minloc0_4_r10.c: Likewise.
128         * generated/minloc0_4_r16.c: Likewise.
129         * generated/minloc0_4_r4.c: Likewise.
130         * generated/minloc0_4_r8.c: Likewise.
131         * generated/minloc0_8_i16.c: Likewise.
132         * generated/minloc0_8_i1.c: Likewise.
133         * generated/minloc0_8_i2.c: Likewise.
134         * generated/minloc0_8_i4.c: Likewise.
135         * generated/minloc0_8_i8.c: Likewise.
136         * generated/minloc0_8_r10.c: Likewise.
137         * generated/minloc0_8_r16.c: Likewise.
138         * generated/minloc0_8_r4.c: Likewise.
139         * generated/minloc0_8_r8.c: Likewise.
140         * generated/minloc1_16_i16.c: Likewise.
141         * generated/minloc1_16_i1.c: Likewise.
142         * generated/minloc1_16_i2.c: Likewise.
143         * generated/minloc1_16_i4.c: Likewise.
144         * generated/minloc1_16_i8.c: Likewise.
145         * generated/minloc1_16_r10.c: Likewise.
146         * generated/minloc1_16_r16.c: Likewise.
147         * generated/minloc1_16_r4.c: Likewise.
148         * generated/minloc1_16_r8.c: Likewise.
149         * generated/minloc1_4_i16.c: Likewise.
150         * generated/minloc1_4_i1.c: Likewise.
151         * generated/minloc1_4_i2.c: Likewise.
152         * generated/minloc1_4_i4.c: Likewise.
153         * generated/minloc1_4_i8.c: Likewise.
154         * generated/minloc1_4_r10.c: Likewise.
155         * generated/minloc1_4_r16.c: Likewise.
156         * generated/minloc1_4_r4.c: Likewise.
157         * generated/minloc1_4_r8.c: Likewise.
158         * generated/minloc1_8_i16.c: Likewise.
159         * generated/minloc1_8_i1.c: Likewise.
160         * generated/minloc1_8_i2.c: Likewise.
161         * generated/minloc1_8_i4.c: Likewise.
162         * generated/minloc1_8_i8.c: Likewise.
163         * generated/minloc1_8_r10.c: Likewise.
164         * generated/minloc1_8_r16.c: Likewise.
165         * generated/minloc1_8_r4.c: Likewise.
166         * generated/minloc1_8_r8.c: Likewise.
167         * generated/minval_i16.c: Likewise.
168         * generated/minval_i1.c: Likewise.
169         * generated/minval_i2.c: Likewise.
170         * generated/minval_i4.c: Likewise.
171         * generated/minval_i8.c: Likewise.
172         * generated/minval_r10.c: Likewise.
173         * generated/minval_r16.c: Likewise.
174         * generated/minval_r4.c: Likewise.
175         * generated/minval_r8.c: Likewise.
176         * generated/product_c10.c: Likewise.
177         * generated/product_c16.c: Likewise.
178         * generated/product_c4.c: Likewise.
179         * generated/product_c8.c: Likewise.
180         * generated/product_i16.c: Likewise.
181         * generated/product_i1.c: Likewise.
182         * generated/product_i2.c: Likewise.
183         * generated/product_i4.c: Likewise.
184         * generated/product_i8.c: Likewise.
185         * generated/product_r10.c: Likewise.
186         * generated/product_r16.c: Likewise.
187         * generated/product_r4.c: Likewise.
188         * generated/product_r8.c: Likewise.
189         * generated/sum_c10.c: Likewise.
190         * generated/sum_c16.c: Likewise.
191         * generated/sum_c4.c: Likewise.
192         * generated/sum_c8.c: Likewise.
193         * generated/sum_i16.c: Likewise.
194         * generated/sum_i1.c: Likewise.
195         * generated/sum_i2.c: Likewise.
196         * generated/sum_i4.c: Likewise.
197         * generated/sum_i8.c: Likewise.
198         * generated/sum_r10.c: Likewise.
199         * generated/sum_r16.c: Likewise.
200         * generated/sum_r4.c: Likewise.
201         * generated/sum_r8.c: Likewise.
202
203 2009-07-22  Jerry DeLisle  <jvdelisle@gcc.gnu.org>
204
205         PR libfortran/32784
206         * unix.c (regular_file): Check for CONIN$ CONOUT$, and CONERR$ and open
207         the respective /dev/conin or /dev/conout devices.  This is Cygwin
208         specific.
209
210 2009-07-19  Thomas Koenig  <tkoenig@gcc.gnu.org>
211
212         PR libfortran/34670
213         PR libfortran/36874
214         * Makefile.am:  Add bounds.c
215         * libgfortran.h (bounds_equal_extents):  Add prototype.
216         (bounds_iforeach_return):  Likewise.
217         (bounds_ifunction_return):  Likewise.
218         (bounds_reduced_extents):  Likewise.
219         * runtime/bounds.c:  New file.
220         (bounds_iforeach_return):  New function; correct typo in
221         error message.
222         (bounds_ifunction_return):  New function.
223         (bounds_equal_extents):  New function.
224         (bounds_reduced_extents):  Likewise.
225         * intrinsics/cshift0.c (cshift0):  Use new functions
226         for bounds checking.
227         * intrinsics/eoshift0.c (eoshift0):  Likewise.
228         * intrinsics/eoshift2.c (eoshift2):  Likewise.
229         * m4/iforeach.m4:  Likewise.
230         * m4/eoshift1.m4:  Likewise.
231         * m4/eoshift3.m4:  Likewise.
232         * m4/cshift1.m4:  Likewise.
233         * m4/ifunction.m4:  Likewise.
234         * Makefile.in:  Regenerated.
235         * generated/cshift1_16.c: Regenerated.
236         * generated/cshift1_4.c: Regenerated.
237         * generated/cshift1_8.c: Regenerated.
238         * generated/eoshift1_16.c: Regenerated.
239         * generated/eoshift1_4.c: Regenerated.
240         * generated/eoshift1_8.c: Regenerated.
241         * generated/eoshift3_16.c: Regenerated.
242         * generated/eoshift3_4.c: Regenerated.
243         * generated/eoshift3_8.c: Regenerated.
244         * generated/maxloc0_16_i1.c: Regenerated.
245         * generated/maxloc0_16_i16.c: Regenerated.
246         * generated/maxloc0_16_i2.c: Regenerated.
247         * generated/maxloc0_16_i4.c: Regenerated.
248         * generated/maxloc0_16_i8.c: Regenerated.
249         * generated/maxloc0_16_r10.c: Regenerated.
250         * generated/maxloc0_16_r16.c: Regenerated.
251         * generated/maxloc0_16_r4.c: Regenerated.
252         * generated/maxloc0_16_r8.c: Regenerated.
253         * generated/maxloc0_4_i1.c: Regenerated.
254         * generated/maxloc0_4_i16.c: Regenerated.
255         * generated/maxloc0_4_i2.c: Regenerated.
256         * generated/maxloc0_4_i4.c: Regenerated.
257         * generated/maxloc0_4_i8.c: Regenerated.
258         * generated/maxloc0_4_r10.c: Regenerated.
259         * generated/maxloc0_4_r16.c: Regenerated.
260         * generated/maxloc0_4_r4.c: Regenerated.
261         * generated/maxloc0_4_r8.c: Regenerated.
262         * generated/maxloc0_8_i1.c: Regenerated.
263         * generated/maxloc0_8_i16.c: Regenerated.
264         * generated/maxloc0_8_i2.c: Regenerated.
265         * generated/maxloc0_8_i4.c: Regenerated.
266         * generated/maxloc0_8_i8.c: Regenerated.
267         * generated/maxloc0_8_r10.c: Regenerated.
268         * generated/maxloc0_8_r16.c: Regenerated.
269         * generated/maxloc0_8_r4.c: Regenerated.
270         * generated/maxloc0_8_r8.c: Regenerated.
271         * generated/maxloc1_16_i1.c: Regenerated.
272         * generated/maxloc1_16_i16.c: Regenerated.
273         * generated/maxloc1_16_i2.c: Regenerated.
274         * generated/maxloc1_16_i4.c: Regenerated.
275         * generated/maxloc1_16_i8.c: Regenerated.
276         * generated/maxloc1_16_r10.c: Regenerated.
277         * generated/maxloc1_16_r16.c: Regenerated.
278         * generated/maxloc1_16_r4.c: Regenerated.
279         * generated/maxloc1_16_r8.c: Regenerated.
280         * generated/maxloc1_4_i1.c: Regenerated.
281         * generated/maxloc1_4_i16.c: Regenerated.
282         * generated/maxloc1_4_i2.c: Regenerated.
283         * generated/maxloc1_4_i4.c: Regenerated.
284         * generated/maxloc1_4_i8.c: Regenerated.
285         * generated/maxloc1_4_r10.c: Regenerated.
286         * generated/maxloc1_4_r16.c: Regenerated.
287         * generated/maxloc1_4_r4.c: Regenerated.
288         * generated/maxloc1_4_r8.c: Regenerated.
289         * generated/maxloc1_8_i1.c: Regenerated.
290         * generated/maxloc1_8_i16.c: Regenerated.
291         * generated/maxloc1_8_i2.c: Regenerated.
292         * generated/maxloc1_8_i4.c: Regenerated.
293         * generated/maxloc1_8_i8.c: Regenerated.
294         * generated/maxloc1_8_r10.c: Regenerated.
295         * generated/maxloc1_8_r16.c: Regenerated.
296         * generated/maxloc1_8_r4.c: Regenerated.
297         * generated/maxloc1_8_r8.c: Regenerated.
298         * generated/maxval_i1.c: Regenerated.
299         * generated/maxval_i16.c: Regenerated.
300         * generated/maxval_i2.c: Regenerated.
301         * generated/maxval_i4.c: Regenerated.
302         * generated/maxval_i8.c: Regenerated.
303         * generated/maxval_r10.c: Regenerated.
304         * generated/maxval_r16.c: Regenerated.
305         * generated/maxval_r4.c: Regenerated.
306         * generated/maxval_r8.c: Regenerated.
307         * generated/minloc0_16_i1.c: Regenerated.
308         * generated/minloc0_16_i16.c: Regenerated.
309         * generated/minloc0_16_i2.c: Regenerated.
310         * generated/minloc0_16_i4.c: Regenerated.
311         * generated/minloc0_16_i8.c: Regenerated.
312         * generated/minloc0_16_r10.c: Regenerated.
313         * generated/minloc0_16_r16.c: Regenerated.
314         * generated/minloc0_16_r4.c: Regenerated.
315         * generated/minloc0_16_r8.c: Regenerated.
316         * generated/minloc0_4_i1.c: Regenerated.
317         * generated/minloc0_4_i16.c: Regenerated.
318         * generated/minloc0_4_i2.c: Regenerated.
319         * generated/minloc0_4_i4.c: Regenerated.
320         * generated/minloc0_4_i8.c: Regenerated.
321         * generated/minloc0_4_r10.c: Regenerated.
322         * generated/minloc0_4_r16.c: Regenerated.
323         * generated/minloc0_4_r4.c: Regenerated.
324         * generated/minloc0_4_r8.c: Regenerated.
325         * generated/minloc0_8_i1.c: Regenerated.
326         * generated/minloc0_8_i16.c: Regenerated.
327         * generated/minloc0_8_i2.c: Regenerated.
328         * generated/minloc0_8_i4.c: Regenerated.
329         * generated/minloc0_8_i8.c: Regenerated.
330         * generated/minloc0_8_r10.c: Regenerated.
331         * generated/minloc0_8_r16.c: Regenerated.
332         * generated/minloc0_8_r4.c: Regenerated.
333         * generated/minloc0_8_r8.c: Regenerated.
334         * generated/minloc1_16_i1.c: Regenerated.
335         * generated/minloc1_16_i16.c: Regenerated.
336         * generated/minloc1_16_i2.c: Regenerated.
337         * generated/minloc1_16_i4.c: Regenerated.
338         * generated/minloc1_16_i8.c: Regenerated.
339         * generated/minloc1_16_r10.c: Regenerated.
340         * generated/minloc1_16_r16.c: Regenerated.
341         * generated/minloc1_16_r4.c: Regenerated.
342         * generated/minloc1_16_r8.c: Regenerated.
343         * generated/minloc1_4_i1.c: Regenerated.
344         * generated/minloc1_4_i16.c: Regenerated.
345         * generated/minloc1_4_i2.c: Regenerated.
346         * generated/minloc1_4_i4.c: Regenerated.
347         * generated/minloc1_4_i8.c: Regenerated.
348         * generated/minloc1_4_r10.c: Regenerated.
349         * generated/minloc1_4_r16.c: Regenerated.
350         * generated/minloc1_4_r4.c: Regenerated.
351         * generated/minloc1_4_r8.c: Regenerated.
352         * generated/minloc1_8_i1.c: Regenerated.
353         * generated/minloc1_8_i16.c: Regenerated.
354         * generated/minloc1_8_i2.c: Regenerated.
355         * generated/minloc1_8_i4.c: Regenerated.
356         * generated/minloc1_8_i8.c: Regenerated.
357         * generated/minloc1_8_r10.c: Regenerated.
358         * generated/minloc1_8_r16.c: Regenerated.
359         * generated/minloc1_8_r4.c: Regenerated.
360         * generated/minloc1_8_r8.c: Regenerated.
361         * generated/minval_i1.c: Regenerated.
362         * generated/minval_i16.c: Regenerated.
363         * generated/minval_i2.c: Regenerated.
364         * generated/minval_i4.c: Regenerated.
365         * generated/minval_i8.c: Regenerated.
366         * generated/minval_r10.c: Regenerated.
367         * generated/minval_r16.c: Regenerated.
368         * generated/minval_r4.c: Regenerated.
369         * generated/minval_r8.c: Regenerated.
370         * generated/product_c10.c: Regenerated.
371         * generated/product_c16.c: Regenerated.
372         * generated/product_c4.c: Regenerated.
373         * generated/product_c8.c: Regenerated.
374         * generated/product_i1.c: Regenerated.
375         * generated/product_i16.c: Regenerated.
376         * generated/product_i2.c: Regenerated.
377         * generated/product_i4.c: Regenerated.
378         * generated/product_i8.c: Regenerated.
379         * generated/product_r10.c: Regenerated.
380         * generated/product_r16.c: Regenerated.
381         * generated/product_r4.c: Regenerated.
382         * generated/product_r8.c: Regenerated.
383         * generated/sum_c10.c: Regenerated.
384         * generated/sum_c16.c: Regenerated.
385         * generated/sum_c4.c: Regenerated.
386         * generated/sum_c8.c: Regenerated.
387         * generated/sum_i1.c: Regenerated.
388         * generated/sum_i16.c: Regenerated.
389         * generated/sum_i2.c: Regenerated.
390         * generated/sum_i4.c: Regenerated.
391         * generated/sum_i8.c: Regenerated.
392         * generated/sum_r10.c: Regenerated.
393         * generated/sum_r16.c: Regenerated.
394         * generated/sum_r4.c: Regenerated.
395         * generated/sum_r8.c: Regenerated.
396
397 2009-07-17  Janne Blomqvist  <jb@gcc.gnu.org>
398             Jerry DeLisle  <jvdelisle@gcc.gnu.org>
399                 
400         PR libfortran/40714
401         * io/transfer.c (finalize_transfer): Set current_record to 0
402         before returning in case of error.
403
404 2009-07-12  Tobias Burnus  <burnus@net-b.de>
405
406         PR libfortran/22423
407         * io/io.h (namelist_type): Use the proper enum for GFC_DTYPE_*.
408         * intrinsics/iso_c_binding.c (c_f_pointer_u0): Make sure
409         variable is initialized to silence warning.
410
411 2009-07-10  Steven G. Kargl  <kargl@gcc.gnu.org>
412
413         * c99_functions.c (ccoshf, ccosh, ccoshl, ctanhf, ctanh, ctanl):
414         Fix errant minus.
415
416 2009-07-08  Jerry DeLisle  <jvdelisle@gcc.gnu.org>
417
418         PR libfortran/40330
419         PR libfortran/40662
420         * io/io.h (st_parameter_dt): Define format_not_saved bit used to signal
421         whether the parsed format data was previously saved. Used to determine
422         if the current format data should be freed or not.
423         * io/transfer.c (st_read_done): Use the format_not_saved bit.
424         (st_write_done): Likewise.
425         * io/format.c (parse_format_list): Add boolean pointer to arg list. This
426         pointer is used to return status to the caller regarding whether it is
427         safe to cache the parsed format data.  Currently, if a FMT_STRING token
428         is encounetered, it is not safe to cache. Also, added a local boolean
429         variable to hold this information as recursive calls to
430         parse_format_list are made.  Remove previous save_format logic.
431         (parse_format): Do not use the format caching facility if the current
432         unit is an internal unit or if it is not safe to save parsed format
433         data.
434         
435 2009-06-29  Jerry DeLisle  <jvdelisle@gcc.gnu.org>
436
437         PR libfortran/40576
438         * io/transfer.c (sset): Adjust exit condition for loop.
439
440 2009-06-22  Jerry DeLisle  <jvdelisle@gcc.gnu.org>
441
442         PR libfortran/40508
443         * io/format.c: Don't save parsed format data for internal units.
444
445 2009-06-21  Thomas Koenig  <tkoenig@gcc.gnu.org>
446
447         PR fortran/37577
448         Port from fortran-dev
449         * runtime/in_pack_generic (internal_pack):  Remove unnecessary
450         test for stride == 0.
451         * runtime/in_unpack_generic.c (internal_unpack):  Likewise.
452         * intrinsics/iso_c_binding.c (c_f_pointer_u0):  Take care
453         of stride in "shape" argument.  Use array access macros for
454         accessing array descriptors.
455         * libgfortran.h (struct descriptor_dimension):  Change stride
456         to _stride, lbound to _lbound and ubound to _ubound.
457         (GFC_DIMENSION_LBOUND):  Use new name(s) in struct
458         descriptor_dimension.
459         (GFC_DIMENSION_UBOUND):  Likewise.
460         (GFC_DIMENSION_STRIDE):  Likewise.
461         (GFC_DIMENSION_EXTENT):  Likewise.
462         (GFC_DIMENSION_SET):  Likewise.
463         (GFC_DESCRIPTOR_LBOUND):  Likewise.
464         (GFC_DESCRIPTOR_UBOUND):  Likewise.
465         (GFC_DESCRIPTOR_EXTENT):  Likewise.
466         (GFC_DESCRIPTOR_STRIDE):  Likewise.
467         * io/transfer.c (transfer_array):  Use array access macros.
468         Use byte-sized strides.
469         * intrinsics/eoshift0.c (eoshift0):  Use array access
470         macros everywhere.
471         * m4/in_pack.m4 (internal_pack_'rtype_ccode`):  Use
472         array access macros for accessing array descriptors.
473         * m4/in_unpack.m4 (internal_unpack_'rtype_ccode`):
474         Likewise.
475         * m4/matmull.m4 (matmul_'rtype_code`):  Likewise.
476         * m4/matmul.m4 (matmul_'rtype_code`):  Likewise.
477         * m4/unpack.m4 (unpack0_'rtype_code`):  Likewise.
478         (unpack1_'rtype_code`):  Likewise.
479         * m4/ifunction_logical.m4 (name`'rtype_qual`_'atype_code): Likewise.
480         * m4/ifunction.m4 (name`'rtype_qual`_'atype_code): Use array access
481         macros everywhere.
482                 * intrinsics/dtime.c (dtime_sub):  Use array access macros
483         for accessing array descriptors.
484         * intrinsics/cshift0 (cshift0):  Likewise.
485         * intrinsics/etime.c:  Likewise.  Remove redundant calculation
486         of rdim.
487         * m4/cshift0.m4 (cshift0_'rtype_code`):  Use array access macros
488         for accessing array descriptors.
489         * m4/pack.m4 (pack_'rtype_code`):  Likewise.
490         * m4/spread.m4 (spread_'rtype_code`):  Likewise.
491         (spread_scalar_'rtype_code`):  Likewise.
492         * m4/transpose.m4 (transpose_'rtype_code`):  Likewise.
493         * m4/iforeach.m4 (name`'rtype_qual`_'atype_code):  Likewise.
494         * m4/eoshift1.m4 (eoshift1):  Likewise.  Remove size argument,
495         calculate within function.
496         (eoshift1_'atype_kind`):  Remove size argument from call
497         to eoshift1.
498         (eoshift1_'atype_kind`_char):  Likewise.
499         (eoshift1_'atype_kind`_char4):  Likewise.
500         * m4/eoshift3.m4 (eoshift3):  Remove size argument, calculate
501         within function. Use array access macros for accessing array
502         descriptors.
503         (eoshift3_'atype_kind`):  Remove size argument from call
504         to eoshift1.
505         (eoshift3_'atype_kind`_char):  Likewise.
506         (eoshift3_'atype_kind`_char4):  Likewise.
507         * m4/shape.m4 (shape_'rtype_kind`):  Use array access macros
508         for accessing array descriptors.
509         * m4/cshift1.m4 (cshift1): Remove size argument, calculate
510         within function. Use array access macros for accessing array
511         descriptors.
512         (cshift1_'atype_kind`):  Remove size argument from call to
513         cshift1.
514         (cshift1_'atype_kind`_char):  Remove size argument from call to
515         cshift1.
516         (cshift1_'atype_kind`_char4):  Remove size argument from call to
517         cshift1.
518         * m4/reshape.m4 (reshape_'rtype_ccode`):  Use array access macros
519         for accessing array descriptors.
520         * m4/ifunction.m4 (name`'rtype_qual`_'atype_code):  Likewise.
521         * intrinsics/pack_generic.c (pack_internal):  Use array access
522         macros for accessing array descriptors.
523         (pack_s_internal):  Likewise.
524         * intrinsics/transpose_generic.c (transpose_internal):  Remove
525         size argument, calculate from array descriptor. Use array
526         access macros for accessing array descriptors.
527         (transpose):  Remove size argument from call.
528         (transpoe_char):  Likewise.
529         (transpose_char4):  Likewise.
530         * intrinsics/move_alloc.c (move_alloc):  Use array access macros
531         for accessing array descriptors.
532         * intrinsics/spread_generic.c (spread_internal):  Remove size
533         argument, calculate from array descriptor.  Use array access
534         macros for accessing array descriptors.
535         (spread_internal_scalar):  Likewise.
536         (spread):  Remove size argument from call to spread_internal.
537         (spread_char):  Mark argument source_length as unused.
538         Remove size argument from call to spread_internal.
539         (spread_char4):  Likewise.
540         (spread_char_scalar):  Likewise.
541         (spread_char4_scalar):  Likewise.
542         * intrinsics/unpack_generic.c (unpack_internal):  Use array access
543         macros for accessing array descriptors.
544         * intrinsics/eoshift2.c (eoshift2):  Remove size argument, calculate
545         from array descriptor instead.  Use array access macros for
546         accessing array descriptors.
547         (eoshift2_##N):  Remove size argument from call to eoshift2.
548         (eoshift2_##N_##char):  Likewise.
549         (eoshift2_##N_##char4):  Likewise.
550         * intrinsics/reshape_generic.c (reshape_internal):  Use array
551         access macross for accessing array descriptors.
552         * libgfortran.h:  Introduce new macros GFC_DIMENSION_LBOUND,
553         GFC_DIMENSION_UBOUND,GFC_DIMENSION_STRIDE, GFC_DIMENSION_EXTENT,
554         GFC_DIMENSION_SET, GFC_DESCRIPTOR_LBOUND, GFC_DESCRIPTOR_UBOUND,
555         GFC_DESCRIPTOR_EXTENT, GFC_DESCRIPTOR_EXTENT_BYTES,
556         GFC_DESCRIPTOR_STRIDE, GFC_DESCRIPTOR_STRIDE_BYTES
557         * runtime/in_pack_generic.c (internal_pack):  Use new macros
558         for array descriptor access.
559         * runtime/in_unpack_generic.c (internal_unpack):  Likewise.
560         * intrinsics/dtime.c (dtime_sub):  Likewise.
561         * intrinsics/cshift0 (cshift0):  Remove argument size,
562         calculate directly from the array descriptor.  Use new macros
563         for array descriptor access.
564         * cshift0_##N:  Remove shift argument in call to cshift0.
565         * cshift0_##N_char:  Mark array_length as unused.  Remove
566         array_length in call to cshift0.
567         * cshift0_##N_char4:  Likewise.
568         * intrisics/etime.c:  Use new macros for array descriptor access.
569         * intrinsics/stat.c (stat_i4_sub_0):  Likewise.
570         (stat_i8_sub_0):  Likewise.
571         (fstat_i4_sub):  Likewise.
572         (fstat_i8_sub):  Likewise.
573         * intrinsics/date_and_time.c (date_and_time):  Likewise.
574         (secnds):  Likewise.
575         (itime_i4):  Likewise.
576         (itime_i8):  Likewise.
577         (idate_i4):  Likewise.
578         (idate_i8):  Likewise.
579         (gmtime_i4):  Likewise.
580         (gmtime_i8):  Likewise.
581         (ltime_i4):  Likewise.
582         (litme_i8):  Likewise.
583         * intrinsics/associated.c (associated):  Likewise.
584         * intrinsics/eoshift0.c (eoshift0):  Likewise.
585         * intriniscs/size.c (size0):  Likewise.
586         * intrinsics/random.c (arandom_r4):  Likewise.
587         (arandom_r8):  Likewise.
588         (arandom_r10):  Likewise.
589         (arandom_r16):  Likewise.
590         (random_seed_i4):  Likewise.
591         (random_seed_i8):  Likewise.
592         * io/list_read.c (nml_parse_qualifier):  Likewise.
593         (nml_touch_nodes):  Likewise.
594         (nml_read_obj):  Likewise.
595         (get_name):  Likewise.
596         * io/transfer.c (transfer_array):  Likewise.
597         (init_loop_spec):  Likewise.
598         (st_set_nml_var_dim):  Likewise.
599         * io/write.c (nml_write_obj):  Likewise.
600         (obj_loop):  Likewise.
601         * generated/all_l1.c: Regenerated.
602         * generated/all_l16.c: Regenerated.
603         * generated/all_l2.c: Regenerated.
604         * generated/all_l4.c: Regenerated.
605         * generated/all_l8.c: Regenerated.
606         * generated/any_l1.c: Regenerated.
607         * generated/any_l16.c: Regenerated.
608         * generated/any_l2.c: Regenerated.
609         * generated/any_l4.c: Regenerated.
610         * generated/any_l8.c: Regenerated.
611         * generated/count_16_l.c: Regenerated.
612         * generated/count_1_l.c: Regenerated.
613         * generated/count_2_l.c: Regenerated.
614         * generated/count_4_l.c: Regenerated.
615         * generated/count_8_l.c: Regenerated.
616         * generated/cshift0_c10.c: Regenerated.
617         * generated/cshift0_c16.c: Regenerated.
618         * generated/cshift0_c4.c: Regenerated.
619         * generated/cshift0_c8.c: Regenerated.
620         * generated/cshift0_i1.c: Regenerated.
621         * generated/cshift0_i16.c: Regenerated.
622         * generated/cshift0_i2.c: Regenerated.
623         * generated/cshift0_i4.c: Regenerated.
624         * generated/cshift0_i8.c: Regenerated.
625         * generated/cshift0_r10.c: Regenerated.
626         * generated/cshift0_r16.c: Regenerated.
627         * generated/cshift0_r4.c: Regenerated.
628         * generated/cshift0_r8.c: Regenerated.
629         * generated/cshift1_16.c: Regenerated.
630         * generated/cshift1_4.c: Regenerated.
631         * generated/cshift1_8.c: Regenerated.
632         * generated/eoshift1_16.c: Regenerated.
633         * generated/eoshift1_4.c: Regenerated.
634         * generated/eoshift1_8.c: Regenerated.
635         * generated/eoshift3_16.c: Regenerated.
636         * generated/eoshift3_4.c: Regenerated.
637         * generated/eoshift3_8.c: Regenerated.
638         * generated/in_pack_c10.c: Regenerated.
639         * generated/in_pack_c16.c: Regenerated.
640         * generated/in_pack_c4.c: Regenerated.
641         * generated/in_pack_c8.c: Regenerated.
642         * generated/in_pack_i1.c: Regenerated.
643         * generated/in_pack_i16.c: Regenerated.
644         * generated/in_pack_i2.c: Regenerated.
645         * generated/in_pack_i4.c: Regenerated.
646         * generated/in_pack_i8.c: Regenerated.
647         * generated/in_pack_r10.c: Regenerated.
648         * generated/in_pack_r16.c: Regenerated.
649         * generated/in_pack_r4.c: Regenerated.
650         * generated/in_pack_r8.c: Regenerated.
651         * generated/in_unpack_c10.c: Regenerated.
652         * generated/in_unpack_c16.c: Regenerated.
653         * generated/in_unpack_c4.c: Regenerated.
654         * generated/in_unpack_c8.c: Regenerated.
655         * generated/in_unpack_i1.c: Regenerated.
656         * generated/in_unpack_i16.c: Regenerated.
657         * generated/in_unpack_i2.c: Regenerated.
658         * generated/in_unpack_i4.c: Regenerated.
659         * generated/in_unpack_i8.c: Regenerated.
660         * generated/in_unpack_r10.c: Regenerated.
661         * generated/in_unpack_r16.c: Regenerated.
662         * generated/in_unpack_r4.c: Regenerated.
663         * generated/in_unpack_r8.c: Regenerated.
664         * generated/matmul_c10.c: Regenerated.
665         * generated/matmul_c16.c: Regenerated.
666         * generated/matmul_c4.c: Regenerated.
667         * generated/matmul_c8.c: Regenerated.
668         * generated/matmul_i1.c: Regenerated.
669         * generated/matmul_i16.c: Regenerated.
670         * generated/matmul_i2.c: Regenerated.
671         * generated/matmul_i4.c: Regenerated.
672         * generated/matmul_i8.c: Regenerated.
673         * generated/matmul_l16.c: Regenerated.
674         * generated/matmul_l4.c: Regenerated.
675         * generated/matmul_l8.c: Regenerated.
676         * generated/matmul_r10.c: Regenerated.
677         * generated/matmul_r16.c: Regenerated.
678         * generated/matmul_r4.c: Regenerated.
679         * generated/matmul_r8.c: Regenerated.
680         * generated/maxloc0_16_i1.c: Regenerated.
681         * generated/maxloc0_16_i16.c: Regenerated.
682         * generated/maxloc0_16_i2.c: Regenerated.
683         * generated/maxloc0_16_i4.c: Regenerated.
684         * generated/maxloc0_16_i8.c: Regenerated.
685         * generated/maxloc0_16_r10.c: Regenerated.
686         * generated/maxloc0_16_r16.c: Regenerated.
687         * generated/maxloc0_16_r4.c: Regenerated.
688         * generated/maxloc0_16_r8.c: Regenerated.
689         * generated/maxloc0_4_i1.c: Regenerated.
690         * generated/maxloc0_4_i16.c: Regenerated.
691         * generated/maxloc0_4_i2.c: Regenerated.
692         * generated/maxloc0_4_i4.c: Regenerated.
693         * generated/maxloc0_4_i8.c: Regenerated.
694         * generated/maxloc0_4_r10.c: Regenerated.
695         * generated/maxloc0_4_r16.c: Regenerated.
696         * generated/maxloc0_4_r4.c: Regenerated.
697         * generated/maxloc0_4_r8.c: Regenerated.
698         * generated/maxloc0_8_i1.c: Regenerated.
699         * generated/maxloc0_8_i16.c: Regenerated.
700         * generated/maxloc0_8_i2.c: Regenerated.
701         * generated/maxloc0_8_i4.c: Regenerated.
702         * generated/maxloc0_8_i8.c: Regenerated.
703         * generated/maxloc0_8_r10.c: Regenerated.
704         * generated/maxloc0_8_r16.c: Regenerated.
705         * generated/maxloc0_8_r4.c: Regenerated.
706         * generated/maxloc0_8_r8.c: Regenerated.
707         * generated/maxloc1_16_i1.c: Regenerated.
708         * generated/maxloc1_16_i16.c: Regenerated.
709         * generated/maxloc1_16_i2.c: Regenerated.
710         * generated/maxloc1_16_i4.c: Regenerated.
711         * generated/maxloc1_16_i8.c: Regenerated.
712         * generated/maxloc1_16_r10.c: Regenerated.
713         * generated/maxloc1_16_r16.c: Regenerated.
714         * generated/maxloc1_16_r4.c: Regenerated.
715         * generated/maxloc1_16_r8.c: Regenerated.
716         * generated/maxloc1_4_i1.c: Regenerated.
717         * generated/maxloc1_4_i16.c: Regenerated.
718         * generated/maxloc1_4_i2.c: Regenerated.
719         * generated/maxloc1_4_i4.c: Regenerated.
720         * generated/maxloc1_4_i8.c: Regenerated.
721         * generated/maxloc1_4_r10.c: Regenerated.
722         * generated/maxloc1_4_r16.c: Regenerated.
723         * generated/maxloc1_4_r4.c: Regenerated.
724         * generated/maxloc1_4_r8.c: Regenerated.
725         * generated/maxloc1_8_i1.c: Regenerated.
726         * generated/maxloc1_8_i16.c: Regenerated.
727         * generated/maxloc1_8_i2.c: Regenerated.
728         * generated/maxloc1_8_i4.c: Regenerated.
729         * generated/maxloc1_8_i8.c: Regenerated.
730         * generated/maxloc1_8_r10.c: Regenerated.
731         * generated/maxloc1_8_r16.c: Regenerated.
732         * generated/maxloc1_8_r4.c: Regenerated.
733         * generated/maxloc1_8_r8.c: Regenerated.
734         * generated/maxval_i1.c: Regenerated.
735         * generated/maxval_i16.c: Regenerated.
736         * generated/maxval_i2.c: Regenerated.
737         * generated/maxval_i4.c: Regenerated.
738         * generated/maxval_i8.c: Regenerated.
739         * generated/maxval_r10.c: Regenerated.
740         * generated/maxval_r16.c: Regenerated.
741         * generated/maxval_r4.c: Regenerated.
742         * generated/maxval_r8.c: Regenerated.
743         * generated/minloc0_16_i1.c: Regenerated.
744         * generated/minloc0_16_i16.c: Regenerated.
745         * generated/minloc0_16_i2.c: Regenerated.
746         * generated/minloc0_16_i4.c: Regenerated.
747         * generated/minloc0_16_i8.c: Regenerated.
748         * generated/minloc0_16_r10.c: Regenerated.
749         * generated/minloc0_16_r16.c: Regenerated.
750         * generated/minloc0_16_r4.c: Regenerated.
751         * generated/minloc0_16_r8.c: Regenerated.
752         * generated/minloc0_4_i1.c: Regenerated.
753         * generated/minloc0_4_i16.c: Regenerated.
754         * generated/minloc0_4_i2.c: Regenerated.
755         * generated/minloc0_4_i4.c: Regenerated.
756         * generated/minloc0_4_i8.c: Regenerated.
757         * generated/minloc0_4_r10.c: Regenerated.
758         * generated/minloc0_4_r16.c: Regenerated.
759         * generated/minloc0_4_r4.c: Regenerated.
760         * generated/minloc0_4_r8.c: Regenerated.
761         * generated/minloc0_8_i1.c: Regenerated.
762         * generated/minloc0_8_i16.c: Regenerated.
763         * generated/minloc0_8_i2.c: Regenerated.
764         * generated/minloc0_8_i4.c: Regenerated.
765         * generated/minloc0_8_i8.c: Regenerated.
766         * generated/minloc0_8_r10.c: Regenerated.
767         * generated/minloc0_8_r16.c: Regenerated.
768         * generated/minloc0_8_r4.c: Regenerated.
769         * generated/minloc0_8_r8.c: Regenerated.
770         * generated/minloc1_16_i1.c: Regenerated.
771         * generated/minloc1_16_i16.c: Regenerated.
772         * generated/minloc1_16_i2.c: Regenerated.
773         * generated/minloc1_16_i4.c: Regenerated.
774         * generated/minloc1_16_i8.c: Regenerated.
775         * generated/minloc1_16_r10.c: Regenerated.
776         * generated/minloc1_16_r16.c: Regenerated.
777         * generated/minloc1_16_r4.c: Regenerated.
778         * generated/minloc1_16_r8.c: Regenerated.
779         * generated/minloc1_4_i1.c: Regenerated.
780         * generated/minloc1_4_i16.c: Regenerated.
781         * generated/minloc1_4_i2.c: Regenerated.
782         * generated/minloc1_4_i4.c: Regenerated.
783         * generated/minloc1_4_i8.c: Regenerated.
784         * generated/minloc1_4_r10.c: Regenerated.
785         * generated/minloc1_4_r16.c: Regenerated.
786         * generated/minloc1_4_r4.c: Regenerated.
787         * generated/minloc1_4_r8.c: Regenerated.
788         * generated/minloc1_8_i1.c: Regenerated.
789         * generated/minloc1_8_i16.c: Regenerated.
790         * generated/minloc1_8_i2.c: Regenerated.
791         * generated/minloc1_8_i4.c: Regenerated.
792         * generated/minloc1_8_i8.c: Regenerated.
793         * generated/minloc1_8_r10.c: Regenerated.
794         * generated/minloc1_8_r16.c: Regenerated.
795         * generated/minloc1_8_r4.c: Regenerated.
796         * generated/minloc1_8_r8.c: Regenerated.
797         * generated/minval_i1.c: Regenerated.
798         * generated/minval_i16.c: Regenerated.
799         * generated/minval_i2.c: Regenerated.
800         * generated/minval_i4.c: Regenerated.
801         * generated/minval_i8.c: Regenerated.
802         * generated/minval_r10.c: Regenerated.
803         * generated/minval_r16.c: Regenerated.
804         * generated/minval_r4.c: Regenerated.
805         * generated/minval_r8.c: Regenerated.
806         * generated/pack_c10.c: Regenerated.
807         * generated/pack_c16.c: Regenerated.
808         * generated/pack_c4.c: Regenerated.
809         * generated/pack_c8.c: Regenerated.
810         * generated/pack_i1.c: Regenerated.
811         * generated/pack_i16.c: Regenerated.
812         * generated/pack_i2.c: Regenerated.
813         * generated/pack_i4.c: Regenerated.
814         * generated/pack_i8.c: Regenerated.
815         * generated/pack_r10.c: Regenerated.
816         * generated/pack_r16.c: Regenerated.
817         * generated/pack_r4.c: Regenerated.
818         * generated/pack_r8.c: Regenerated.
819         * generated/product_c10.c: Regenerated.
820         * generated/product_c16.c: Regenerated.
821         * generated/product_c4.c: Regenerated.
822         * generated/product_c8.c: Regenerated.
823         * generated/product_i1.c: Regenerated.
824         * generated/product_i16.c: Regenerated.
825         * generated/product_i2.c: Regenerated.
826         * generated/product_i4.c: Regenerated.
827         * generated/product_i8.c: Regenerated.
828         * generated/product_r10.c: Regenerated.
829         * generated/product_r16.c: Regenerated.
830         * generated/product_r4.c: Regenerated.
831         * generated/product_r8.c: Regenerated.
832         * generated/reshape_c10.c: Regenerated.
833         * generated/reshape_c16.c: Regenerated.
834         * generated/reshape_c4.c: Regenerated.
835         * generated/reshape_c8.c: Regenerated.
836         * generated/reshape_i16.c: Regenerated.
837         * generated/reshape_i4.c: Regenerated.
838         * generated/reshape_i8.c: Regenerated.
839         * generated/reshape_r10.c: Regenerated.
840         * generated/reshape_r16.c: Regenerated.
841         * generated/reshape_r4.c: Regenerated.
842         * generated/reshape_r8.c: Regenerated.
843         * generated/shape_i16.c: Regenerated.
844         * generated/shape_i4.c: Regenerated.
845         * generated/shape_i8.c: Regenerated.
846         * generated/spread_c10.c: Regenerated.
847         * generated/spread_c16.c: Regenerated.
848         * generated/spread_c4.c: Regenerated.
849         * generated/spread_c8.c: Regenerated.
850         * generated/spread_i1.c: Regenerated.
851         * generated/spread_i16.c: Regenerated.
852         * generated/spread_i2.c: Regenerated.
853         * generated/spread_i4.c: Regenerated.
854         * generated/spread_i8.c: Regenerated.
855         * generated/spread_r10.c: Regenerated.
856         * generated/spread_r16.c: Regenerated.
857         * generated/spread_r4.c: Regenerated.
858         * generated/spread_r8.c: Regenerated.
859         * generated/sum_c10.c: Regenerated.
860         * generated/sum_c16.c: Regenerated.
861         * generated/sum_c4.c: Regenerated.
862         * generated/sum_c8.c: Regenerated.
863         * generated/sum_i1.c: Regenerated.
864         * generated/sum_i16.c: Regenerated.
865         * generated/sum_i2.c: Regenerated.
866         * generated/sum_i4.c: Regenerated.
867         * generated/sum_i8.c: Regenerated.
868         * generated/sum_r10.c: Regenerated.
869         * generated/sum_r16.c: Regenerated.
870         * generated/sum_r4.c: Regenerated.
871         * generated/sum_r8.c: Regenerated.
872         * generated/transpose_c10.c: Regenerated.
873         * generated/transpose_c16.c: Regenerated.
874         * generated/transpose_c4.c: Regenerated.
875         * generated/transpose_c8.c: Regenerated.
876         * generated/transpose_i16.c: Regenerated.
877         * generated/transpose_i4.c: Regenerated.
878         * generated/transpose_i8.c: Regenerated.
879         * generated/transpose_r10.c: Regenerated.
880         * generated/transpose_r16.c: Regenerated.
881         * generated/transpose_r4.c: Regenerated.
882         * generated/transpose_r8.c: Regenerated.
883         * generated/unpack_c10.c: Regenerated.
884         * generated/unpack_c16.c: Regenerated.
885         * generated/unpack_c4.c: Regenerated.
886         * generated/unpack_c8.c: Regenerated.
887         * generated/unpack_i1.c: Regenerated.
888         * generated/unpack_i16.c: Regenerated.
889         * generated/unpack_i2.c: Regenerated.
890         * generated/unpack_i4.c: Regenerated.
891         * generated/unpack_i8.c: Regenerated.
892         * generated/unpack_r10.c: Regenerated.
893         * generated/unpack_r16.c: Regenerated.
894         * generated/unpack_r4.c: Regenerated.
895         * generated/unpack_r8.c: Regenerated.
896
897 2009-06-14 Francois-Xavier Coudert <fxcoudert@gcc.gnu.org>
898
899         * fmain.c (main): Don't PREFIX set_args.
900         * libgfortran.h (set_args): Use iexport_proto.
901         * runtime/main.c (set_args): Use iexport.
902
903 2009-06-07  Jerry DeLisle  <jvdelisle@gcc.gnu.org>
904
905         PR libfortran/40008
906         * libgfortran.h: Define IOPARM_OPEN_HAS_NEWUNIT.
907         * io/open.c (st_open): Don't error on negative unit number if NEWUNIT
908         was specified. If NEWUNIT is specified, call new function to get the
909         unique unit number and assign it.
910         * io/io.h (st_parameter_open): Add pointer to newunit.  Add prototype for
911         next_available_newunit. Add prototype for new function,
912         get_unique_unit_number.
913         * io/unit.c: Declare next_available_newunit. Define the first newunit
914         number. (init_units): Initialize next_available_unit.
915         (get_unique_unit_number): New function. Fix whitespace and comments.
916         * io/transfer.c (data_transfer_init): Update error message to not be
917         specific to OPEN statements.
918
919 2009-06-07  Jerry DeLisle  <jvdelisle@gcc.gnu.org>
920
921         PR libfortran/40334
922         * io/list_read.c (list_formatted_read_scalar): Set the end file
923         conditions after a return from EOF error.
924
925 2009-06-04  Janne Blomqvist  <jb@gcc.gnu.org>
926
927         PR libfortran/40330
928         * io/format.c (free_format_hash_table): Also free and nullify hash key.
929         (save_parsed_format): Copy string rather than pointer copy.
930         
931 2009-05-29  Francois-Xavier Coudert  <fxcoudert@gcc.gnu.org>
932
933         PR fortran/40019
934         * intrinsics/bit_intrinsics.c: New file.
935         * gfortran.map (GFORTRAN_1.2): New list.
936         * Makefile.am: Add intrinsics/bit_intrinsics.c.
937         * Makefile.in: Regenerate.
938
939 2009-05-29  Janne Blomqvist  <jb@gcc.gnu.org>
940
941         PR libfortran/40190
942         * configure.ac: Check for localtime_r and gmtime_r.
943         * intrinsics/date_and_time.c: Add fallback implementations for
944         localtime_r and gmtime_r.
945         (date_and_time): Change to use localtime_r and gmtime_r instead of
946         localtime and gmtime, respectively.
947         (itime0): Use localtime_r instead of localtime.
948         (ltime_0): Likewise.
949         (gmtime_0): Use gmtime_r instead of gmtime.
950         * config.h.in: Regenerated
951         * configure: Regenerated.
952
953 2009-05-27  Janne Blomqvist  <jb@gcc.gnu.org>
954
955         PR fortran/39178
956         * runtime/main.c (store_exe_path): Remove static attribute.
957         * libgfortran.h: Add back store_exe_path prototype.
958
959 2009-05-27  Thomas Koenig  <tkoenig@gcc.gnu.org>
960
961         PR libfortran/40187
962         * intrinsics/iso_c_binding.c (c_f_pointer_u0):  Take care
963         of stride in "shape" argument.
964
965 2009-05-26  Tobias Burnus  <burnus@net-b.de>
966
967         PR fortran/39178
968         * runtime/main.c (store_exe_path): Make static
969         and multiple-times callable.
970         (set_args): Call store_exe_path.
971         * libgfortran.h: Remove store_exe_path prototype.
972         * fmain.c (main): Remove store_exe_path call.
973
974 2009-05-19  Jerry DeLisle  <jvdelisle@gcc.gnu.org>
975
976         PR libfortran/37754
977         * io/write_float.def: Simplify format calculation.
978         
979 2009-05-07  Francois-Xavier Coudert  <fxcoudert@gcc.gnu.org>
980
981         PR fortran/22423
982         * io/transfer.c (read_block_direct): Avoid warning.
983         * runtime/string.c (compare0): Avoid warning.
984
985 2009-04-30  Janne Blomqvist  <jb@gcc.gnu.org>
986
987         PR libfortran/39667
988         * io/file_pos.c (st_rewind): Don't truncate or flush.
989         * io/intrinsics.c (fgetc): Flush if switching mode.
990         (fputc): Likewise.
991
992 2009-04-18  Janne Blomqvist  <jb@gcc.gnu.org>
993
994         PR libfortran/39782
995         * io/transfer.c (data_transfer_init): Don't flush before seek.
996         (finalize_transfer): Remove extra flush.
997
998 2009-04-17  Janne Blomqvist  <jb@gcc.gnu.org>
999
1000         * io/io.h (is_preconnected): Remove prototype.
1001         * io/unix.c (is_preconnected): Remove function.
1002
1003 2009-04-17  Ulrich Weigand  <Ulrich.Weigand@de.ibm.com>
1004
1005         * configure.ac: Test for -ffunction-sections -fdata-sections and
1006         set SECTION_FLAGS accordingly.
1007         * configure: Regenerate.
1008
1009         * Makefile.am: Add SECTION_FLAGS to AM_CFLAGS.
1010         * Makefile.in: Regenerate.
1011
1012 2009-04-15  Janne Blomqvist  <jb@gcc.gnu.org>
1013
1014         PR libfortran/38668
1015         * io/transfer.c (finalize_transfer): Don't flush for advance='no'.
1016
1017 2009-04-15 Danny Smith  <dannysmith@clear.net.nz>
1018
1019         * io/write.c (itoa) : Rename back to gfc_itoa.
1020         (write_i): Adjust call to write_decimal.
1021         (write_integer):  Use gfc_itoa.
1022
1023 2009-04-10  Janne Blomqvist  <jb@gcc.gnu.org>
1024
1025         * io/io.h (move_pos_offset): Remove prototype.
1026         * io/transfer.c (formatted_transfer_scalar_read): Use sseek
1027         instead of move_pos_offset.
1028         * io/unix.c (move_pos_offset): Remove.
1029
1030 2009-04-10  Janne Blomqvist  <jb@gcc.gnu.org>
1031
1032         PR libfortran/39665 libfortran/39702 libfortran/39709
1033         * io/io.h (st_parameter_dt): Revert aligned attribute from u.p.value.
1034         * io/list_read.c (read_complex): Read directly into user pointer.
1035         (read_real): Likewise.
1036         (list_formatted_read_scalar): Update read_complex and read_real calls.
1037         (nml_read_obj): Read directly into user pointer.
1038
1039 2009-04-09  Janne Blomqvist  <jb@gcc.gnu.org>
1040
1041         PR libfortran/39665
1042         * io/io.h (st_parameter_dt): Add aligned attribute to u.p.value.
1043         * io/read.c (convert_real): Add note about alignment requirements.
1044
1045 2009-04-09  Nick Clifton  <nickc@redhat.com>
1046
1047         * m4/cshift0.m4: Change copyright header to refer to version 3
1048         of the GNU General Public License with version 3.1 of the GCC
1049         Runtime Library Exception and to point readers at the COPYING3
1050         and COPYING3.RUNTIME files and the FSF's license web page.
1051         * c99_protos.h: Likewise.
1052         * config/fpu-387.h: Likewise.
1053         * config/fpu-aix.h: Likewise.
1054         * config/fpu-generic.h: Likewise.
1055         * config/fpu-glibc.h: Likewise.
1056         * config/fpu-sysv.h: Likewise.
1057         * intrinsics/abort.c: Likewise.
1058         * intrinsics/access.c: Likewise.
1059         * intrinsics/args.c: Likewise.
1060         * intrinsics/associated.c: Likewise.
1061         * intrinsics/c99_functions.c: Likewise.
1062         * intrinsics/chdir.c: Likewise.
1063         * intrinsics/chmod.c: Likewise.
1064         * intrinsics/clock.c: Likewise.
1065         * intrinsics/cpu_time.c: Likewise.
1066         * intrinsics/cshift0.c: Likewise.
1067         * intrinsics/ctime.c: Likewise.
1068         * intrinsics/date_and_time.c: Likewise.
1069         * intrinsics/dprod_r8.f90: Likewise.
1070         * intrinsics/dtime.c: Likewise.
1071         * intrinsics/env.c: Likewise.
1072         * intrinsics/eoshift0.c: Likewise.
1073         * intrinsics/eoshift2.c: Likewise.
1074         * intrinsics/erfc_scaled.c: Likewise.
1075         * intrinsics/erfc_scaled_inc.c: Likewise.
1076         * intrinsics/etime.c: Likewise.
1077         * intrinsics/exit.c: Likewise.
1078         * intrinsics/f2c_specifics.F90: Likewise.
1079         * intrinsics/fnum.c: Likewise.
1080         * intrinsics/gerror.c: Likewise.
1081         * intrinsics/getXid.c: Likewise.
1082         * intrinsics/getcwd.c: Likewise.
1083         * intrinsics/getlog.c: Likewise.
1084         * intrinsics/hostnm.c: Likewise.
1085         * intrinsics/ierrno.c: Likewise.
1086         * intrinsics/ishftc.c: Likewise.
1087         * intrinsics/iso_c_binding.c: Likewise.
1088         * intrinsics/iso_c_binding.h: Likewise.
1089         * intrinsics/iso_c_generated_procs.c: Likewise.
1090         * intrinsics/kill.c: Likewise.
1091         * intrinsics/link.c: Likewise.
1092         * intrinsics/malloc.c: Likewise.
1093         * intrinsics/move_alloc.c: Likewise.
1094         * intrinsics/mvbits.c: Likewise.
1095         * intrinsics/pack_generic.c: Likewise.
1096         * intrinsics/perror.c: Likewise.
1097         * intrinsics/rand.c: Likewise.
1098         * intrinsics/random.c: Likewise.
1099         * intrinsics/rename.c: Likewise.
1100         * intrinsics/reshape_generic.c: Likewise.
1101         * intrinsics/reshape_packed.c: Likewise.
1102         * intrinsics/selected_char_kind.c: Likewise.
1103         * intrinsics/selected_int_kind.f90: Likewise.
1104         * intrinsics/selected_real_kind.f90: Likewise.
1105         * intrinsics/signal.c: Likewise.
1106         * intrinsics/size.c: Likewise.
1107         * intrinsics/sleep.c: Likewise.
1108         * intrinsics/spread_generic.c: Likewise.
1109         * intrinsics/stat.c: Likewise.
1110         * intrinsics/string_intrinsics.c: Likewise.
1111         * intrinsics/string_intrinsics_inc.c: Likewise.
1112         * intrinsics/symlnk.c: Likewise.
1113         * intrinsics/system.c: Likewise.
1114         * intrinsics/system_clock.c: Likewise.
1115         * intrinsics/time.c: Likewise.
1116         * intrinsics/time_1.h: Likewise.
1117         * intrinsics/transpose_generic.c: Likewise.
1118         * intrinsics/umask.c: Likewise.
1119         * intrinsics/unlink.c: Likewise.
1120         * intrinsics/unpack_generic.c: Likewise.
1121         * io/close.c: Likewise.
1122         * io/fbuf.c: Likewise.
1123         * io/file_pos.c: Likewise.
1124         * io/format.c: Likewise.
1125         * io/inquire.c: Likewise.
1126         * io/intrinsics.c: Likewise.
1127         * io/io.h: Likewise.
1128         * io/list_read.c: Likewise.
1129         * io/lock.c: Likewise.
1130         * io/open.c: Likewise.
1131         * io/read.c: Likewise.
1132         * io/size_from_kind.c: Likewise.
1133         * io/transfer.c: Likewise.
1134         * io/unit.c: Likewise.
1135         * io/unix.c: Likewise.
1136         * io/write.c: Likewise.
1137         * io/write_float.def: Likewise.
1138         * libgfortran.h: Likewise.
1139         * m4/all.m4: Likewise.
1140         * m4/any.m4: Likewise.
1141         * m4/count.m4: Likewise.
1142         * m4/cshift1.m4: Likewise.
1143         * m4/eoshift1.m4: Likewise.
1144         * m4/eoshift3.m4: Likewise.
1145         * m4/exponent.m4: Likewise.
1146         * m4/fraction.m4: Likewise.
1147         * m4/head.m4: Likewise.
1148         * m4/in_pack.m4: Likewise.
1149         * m4/in_unpack.m4: Likewise.
1150         * m4/matmul.m4: Likewise.
1151         * m4/matmull.m4: Likewise.
1152         * m4/maxloc0.m4: Likewise.
1153         * m4/maxloc1.m4: Likewise.
1154         * m4/maxval.m4: Likewise.
1155         * m4/minloc0.m4: Likewise.
1156         * m4/minloc1.m4: Likewise.
1157         * m4/minval.m4: Likewise.
1158         * m4/nearest.m4: Likewise.
1159         * m4/pack.m4: Likewise.
1160         * m4/pow.m4: Likewise.
1161         * m4/product.m4: Likewise.
1162         * m4/reshape.m4: Likewise.
1163         * m4/rrspacing.m4: Likewise.
1164         * m4/set_exponent.m4: Likewise.
1165         * m4/shape.m4: Likewise.
1166         * m4/spacing.m4: Likewise.
1167         * m4/spread.m4: Likewise.
1168         * m4/sum.m4: Likewise.
1169         * m4/transpose.m4: Likewise.
1170         * m4/unpack.m4: Likewise.
1171         * runtime/backtrace.c: Likewise.
1172         * runtime/compile_options.c: Likewise.
1173         * runtime/convert_char.c: Likewise.
1174         * runtime/environ.c: Likewise.
1175         * runtime/error.c: Likewise.
1176         * runtime/in_pack_generic.c: Likewise.
1177         * runtime/in_unpack_generic.c: Likewise.
1178         * runtime/main.c: Likewise.
1179         * runtime/memory.c: Likewise.
1180         * runtime/pause.c: Likewise.
1181         * runtime/select.c: Likewise.
1182         * runtime/select_inc.c: Likewise.
1183         * runtime/stop.c: Likewise.
1184         * runtime/string.c: Likewise.
1185         * generated/_abs_c10.F90: Regenerate.
1186         * generated/_abs_c16.F90: Regenerate.
1187         * generated/_abs_c4.F90: Regenerate.
1188         * generated/_abs_c8.F90: Regenerate.
1189         * generated/_abs_i16.F90: Regenerate.
1190         * generated/_abs_i4.F90: Regenerate.
1191         * generated/_abs_i8.F90: Regenerate.
1192         * generated/_abs_r10.F90: Regenerate.
1193         * generated/_abs_r16.F90: Regenerate.
1194         * generated/_abs_r4.F90: Regenerate.
1195         * generated/_abs_r8.F90: Regenerate.
1196         * generated/_acos_r10.F90: Regenerate.
1197         * generated/_acos_r16.F90: Regenerate.
1198         * generated/_acos_r4.F90: Regenerate.
1199         * generated/_acos_r8.F90: Regenerate.
1200         * generated/_acosh_r10.F90: Regenerate.
1201         * generated/_acosh_r16.F90: Regenerate.
1202         * generated/_acosh_r4.F90: Regenerate.
1203         * generated/_acosh_r8.F90: Regenerate.
1204         * generated/_aimag_c10.F90: Regenerate.
1205         * generated/_aimag_c16.F90: Regenerate.
1206         * generated/_aimag_c4.F90: Regenerate.
1207         * generated/_aimag_c8.F90: Regenerate.
1208         * generated/_aint_r10.F90: Regenerate.
1209         * generated/_aint_r16.F90: Regenerate.
1210         * generated/_aint_r4.F90: Regenerate.
1211         * generated/_aint_r8.F90: Regenerate.
1212         * generated/_anint_r10.F90: Regenerate.
1213         * generated/_anint_r16.F90: Regenerate.
1214         * generated/_anint_r4.F90: Regenerate.
1215         * generated/_anint_r8.F90: Regenerate.
1216         * generated/_asin_r10.F90: Regenerate.
1217         * generated/_asin_r16.F90: Regenerate.
1218         * generated/_asin_r4.F90: Regenerate.
1219         * generated/_asin_r8.F90: Regenerate.
1220         * generated/_asinh_r10.F90: Regenerate.
1221         * generated/_asinh_r16.F90: Regenerate.
1222         * generated/_asinh_r4.F90: Regenerate.
1223         * generated/_asinh_r8.F90: Regenerate.
1224         * generated/_atan2_r10.F90: Regenerate.
1225         * generated/_atan2_r16.F90: Regenerate.
1226         * generated/_atan2_r4.F90: Regenerate.
1227         * generated/_atan2_r8.F90: Regenerate.
1228         * generated/_atan_r10.F90: Regenerate.
1229         * generated/_atan_r16.F90: Regenerate.
1230         * generated/_atan_r4.F90: Regenerate.
1231         * generated/_atan_r8.F90: Regenerate.
1232         * generated/_atanh_r10.F90: Regenerate.
1233         * generated/_atanh_r16.F90: Regenerate.
1234         * generated/_atanh_r4.F90: Regenerate.
1235         * generated/_atanh_r8.F90: Regenerate.
1236         * generated/_conjg_c10.F90: Regenerate.
1237         * generated/_conjg_c16.F90: Regenerate.
1238         * generated/_conjg_c4.F90: Regenerate.
1239         * generated/_conjg_c8.F90: Regenerate.
1240         * generated/_cos_c10.F90: Regenerate.
1241         * generated/_cos_c16.F90: Regenerate.
1242         * generated/_cos_c4.F90: Regenerate.
1243         * generated/_cos_c8.F90: Regenerate.
1244         * generated/_cos_r10.F90: Regenerate.
1245         * generated/_cos_r16.F90: Regenerate.
1246         * generated/_cos_r4.F90: Regenerate.
1247         * generated/_cos_r8.F90: Regenerate.
1248         * generated/_cosh_r10.F90: Regenerate.
1249         * generated/_cosh_r16.F90: Regenerate.
1250         * generated/_cosh_r4.F90: Regenerate.
1251         * generated/_cosh_r8.F90: Regenerate.
1252         * generated/_dim_i16.F90: Regenerate.
1253         * generated/_dim_i4.F90: Regenerate.
1254         * generated/_dim_i8.F90: Regenerate.
1255         * generated/_dim_r10.F90: Regenerate.
1256         * generated/_dim_r16.F90: Regenerate.
1257         * generated/_dim_r4.F90: Regenerate.
1258         * generated/_dim_r8.F90: Regenerate.
1259         * generated/_exp_c10.F90: Regenerate.
1260         * generated/_exp_c16.F90: Regenerate.
1261         * generated/_exp_c4.F90: Regenerate.
1262         * generated/_exp_c8.F90: Regenerate.
1263         * generated/_exp_r10.F90: Regenerate.
1264         * generated/_exp_r16.F90: Regenerate.
1265         * generated/_exp_r4.F90: Regenerate.
1266         * generated/_exp_r8.F90: Regenerate.
1267         * generated/_log10_r10.F90: Regenerate.
1268         * generated/_log10_r16.F90: Regenerate.
1269         * generated/_log10_r4.F90: Regenerate.
1270         * generated/_log10_r8.F90: Regenerate.
1271         * generated/_log_c10.F90: Regenerate.
1272         * generated/_log_c16.F90: Regenerate.
1273         * generated/_log_c4.F90: Regenerate.
1274         * generated/_log_c8.F90: Regenerate.
1275         * generated/_log_r10.F90: Regenerate.
1276         * generated/_log_r16.F90: Regenerate.
1277         * generated/_log_r4.F90: Regenerate.
1278         * generated/_log_r8.F90: Regenerate.
1279         * generated/_mod_i16.F90: Regenerate.
1280         * generated/_mod_i4.F90: Regenerate.
1281         * generated/_mod_i8.F90: Regenerate.
1282         * generated/_mod_r10.F90: Regenerate.
1283         * generated/_mod_r16.F90: Regenerate.
1284         * generated/_mod_r4.F90: Regenerate.
1285         * generated/_mod_r8.F90: Regenerate.
1286         * generated/_sign_i16.F90: Regenerate.
1287         * generated/_sign_i4.F90: Regenerate.
1288         * generated/_sign_i8.F90: Regenerate.
1289         * generated/_sign_r10.F90: Regenerate.
1290         * generated/_sign_r16.F90: Regenerate.
1291         * generated/_sign_r4.F90: Regenerate.
1292         * generated/_sign_r8.F90: Regenerate.
1293         * generated/_sin_c10.F90: Regenerate.
1294         * generated/_sin_c16.F90: Regenerate.
1295         * generated/_sin_c4.F90: Regenerate.
1296         * generated/_sin_c8.F90: Regenerate.
1297         * generated/_sin_r10.F90: Regenerate.
1298         * generated/_sin_r16.F90: Regenerate.
1299         * generated/_sin_r4.F90: Regenerate.
1300         * generated/_sin_r8.F90: Regenerate.
1301         * generated/_sinh_r10.F90: Regenerate.
1302         * generated/_sinh_r16.F90: Regenerate.
1303         * generated/_sinh_r4.F90: Regenerate.
1304         * generated/_sinh_r8.F90: Regenerate.
1305         * generated/_sqrt_c10.F90: Regenerate.
1306         * generated/_sqrt_c16.F90: Regenerate.
1307         * generated/_sqrt_c4.F90: Regenerate.
1308         * generated/_sqrt_c8.F90: Regenerate.
1309         * generated/_sqrt_r10.F90: Regenerate.
1310         * generated/_sqrt_r16.F90: Regenerate.
1311         * generated/_sqrt_r4.F90: Regenerate.
1312         * generated/_sqrt_r8.F90: Regenerate.
1313         * generated/_tan_r10.F90: Regenerate.
1314         * generated/_tan_r16.F90: Regenerate.
1315         * generated/_tan_r4.F90: Regenerate.
1316         * generated/_tan_r8.F90: Regenerate.
1317         * generated/_tanh_r10.F90: Regenerate.
1318         * generated/_tanh_r16.F90: Regenerate.
1319         * generated/_tanh_r4.F90: Regenerate.
1320         * generated/_tanh_r8.F90: Regenerate.
1321         * generated/all_l1.c: Regenerate.
1322         * generated/all_l16.c: Regenerate.
1323         * generated/all_l2.c: Regenerate.
1324         * generated/all_l4.c: Regenerate.
1325         * generated/all_l8.c: Regenerate.
1326         * generated/any_l1.c: Regenerate.
1327         * generated/any_l16.c: Regenerate.
1328         * generated/any_l2.c: Regenerate.
1329         * generated/any_l4.c: Regenerate.
1330         * generated/any_l8.c: Regenerate.
1331         * generated/count_16_l.c: Regenerate.
1332         * generated/count_1_l.c: Regenerate.
1333         * generated/count_2_l.c: Regenerate.
1334         * generated/count_4_l.c: Regenerate.
1335         * generated/count_8_l.c: Regenerate.
1336         * generated/cshift0_c10.c: Regenerate.
1337         * generated/cshift0_c16.c: Regenerate.
1338         * generated/cshift0_c4.c: Regenerate.
1339         * generated/cshift0_c8.c: Regenerate.
1340         * generated/cshift0_i1.c: Regenerate.
1341         * generated/cshift0_i16.c: Regenerate.
1342         * generated/cshift0_i2.c: Regenerate.
1343         * generated/cshift0_i4.c: Regenerate.
1344         * generated/cshift0_i8.c: Regenerate.
1345         * generated/cshift0_r10.c: Regenerate.
1346         * generated/cshift0_r16.c: Regenerate.
1347         * generated/cshift0_r4.c: Regenerate.
1348         * generated/cshift0_r8.c: Regenerate.
1349         * generated/cshift1_16.c: Regenerate.
1350         * generated/cshift1_4.c: Regenerate.
1351         * generated/cshift1_8.c: Regenerate.
1352         * generated/eoshift1_16.c: Regenerate.
1353         * generated/eoshift1_4.c: Regenerate.
1354         * generated/eoshift1_8.c: Regenerate.
1355         * generated/eoshift3_16.c: Regenerate.
1356         * generated/eoshift3_4.c: Regenerate.
1357         * generated/eoshift3_8.c: Regenerate.
1358         * generated/exponent_r10.c: Regenerate.
1359         * generated/exponent_r16.c: Regenerate.
1360         * generated/exponent_r4.c: Regenerate.
1361         * generated/exponent_r8.c: Regenerate.
1362         * generated/fraction_r10.c: Regenerate.
1363         * generated/fraction_r16.c: Regenerate.
1364         * generated/fraction_r4.c: Regenerate.
1365         * generated/fraction_r8.c: Regenerate.
1366         * generated/in_pack_c10.c: Regenerate.
1367         * generated/in_pack_c16.c: Regenerate.
1368         * generated/in_pack_c4.c: Regenerate.
1369         * generated/in_pack_c8.c: Regenerate.
1370         * generated/in_pack_i1.c: Regenerate.
1371         * generated/in_pack_i16.c: Regenerate.
1372         * generated/in_pack_i2.c: Regenerate.
1373         * generated/in_pack_i4.c: Regenerate.
1374         * generated/in_pack_i8.c: Regenerate.
1375         * generated/in_pack_r10.c: Regenerate.
1376         * generated/in_pack_r16.c: Regenerate.
1377         * generated/in_pack_r4.c: Regenerate.
1378         * generated/in_pack_r8.c: Regenerate.
1379         * generated/in_unpack_c10.c: Regenerate.
1380         * generated/in_unpack_c16.c: Regenerate.
1381         * generated/in_unpack_c4.c: Regenerate.
1382         * generated/in_unpack_c8.c: Regenerate.
1383         * generated/in_unpack_i1.c: Regenerate.
1384         * generated/in_unpack_i16.c: Regenerate.
1385         * generated/in_unpack_i2.c: Regenerate.
1386         * generated/in_unpack_i4.c: Regenerate.
1387         * generated/in_unpack_i8.c: Regenerate.
1388         * generated/in_unpack_r10.c: Regenerate.
1389         * generated/in_unpack_r16.c: Regenerate.
1390         * generated/in_unpack_r4.c: Regenerate.
1391         * generated/in_unpack_r8.c: Regenerate.
1392         * generated/matmul_c10.c: Regenerate.
1393         * generated/matmul_c16.c: Regenerate.
1394         * generated/matmul_c4.c: Regenerate.
1395         * generated/matmul_c8.c: Regenerate.
1396         * generated/matmul_i1.c: Regenerate.
1397         * generated/matmul_i16.c: Regenerate.
1398         * generated/matmul_i2.c: Regenerate.
1399         * generated/matmul_i4.c: Regenerate.
1400         * generated/matmul_i8.c: Regenerate.
1401         * generated/matmul_l16.c: Regenerate.
1402         * generated/matmul_l4.c: Regenerate.
1403         * generated/matmul_l8.c: Regenerate.
1404         * generated/matmul_r10.c: Regenerate.
1405         * generated/matmul_r16.c: Regenerate.
1406         * generated/matmul_r4.c: Regenerate.
1407         * generated/matmul_r8.c: Regenerate.
1408         * generated/maxloc0_16_i1.c: Regenerate.
1409         * generated/maxloc0_16_i16.c: Regenerate.
1410         * generated/maxloc0_16_i2.c: Regenerate.
1411         * generated/maxloc0_16_i4.c: Regenerate.
1412         * generated/maxloc0_16_i8.c: Regenerate.
1413         * generated/maxloc0_16_r10.c: Regenerate.
1414         * generated/maxloc0_16_r16.c: Regenerate.
1415         * generated/maxloc0_16_r4.c: Regenerate.
1416         * generated/maxloc0_16_r8.c: Regenerate.
1417         * generated/maxloc0_4_i1.c: Regenerate.
1418         * generated/maxloc0_4_i16.c: Regenerate.
1419         * generated/maxloc0_4_i2.c: Regenerate.
1420         * generated/maxloc0_4_i4.c: Regenerate.
1421         * generated/maxloc0_4_i8.c: Regenerate.
1422         * generated/maxloc0_4_r10.c: Regenerate.
1423         * generated/maxloc0_4_r16.c: Regenerate.
1424         * generated/maxloc0_4_r4.c: Regenerate.
1425         * generated/maxloc0_4_r8.c: Regenerate.
1426         * generated/maxloc0_8_i1.c: Regenerate.
1427         * generated/maxloc0_8_i16.c: Regenerate.
1428         * generated/maxloc0_8_i2.c: Regenerate.
1429         * generated/maxloc0_8_i4.c: Regenerate.
1430         * generated/maxloc0_8_i8.c: Regenerate.
1431         * generated/maxloc0_8_r10.c: Regenerate.
1432         * generated/maxloc0_8_r16.c: Regenerate.
1433         * generated/maxloc0_8_r4.c: Regenerate.
1434         * generated/maxloc0_8_r8.c: Regenerate.
1435         * generated/maxloc1_16_i1.c: Regenerate.
1436         * generated/maxloc1_16_i16.c: Regenerate.
1437         * generated/maxloc1_16_i2.c: Regenerate.
1438         * generated/maxloc1_16_i4.c: Regenerate.
1439         * generated/maxloc1_16_i8.c: Regenerate.
1440         * generated/maxloc1_16_r10.c: Regenerate.
1441         * generated/maxloc1_16_r16.c: Regenerate.
1442         * generated/maxloc1_16_r4.c: Regenerate.
1443         * generated/maxloc1_16_r8.c: Regenerate.
1444         * generated/maxloc1_4_i1.c: Regenerate.
1445         * generated/maxloc1_4_i16.c: Regenerate.
1446         * generated/maxloc1_4_i2.c: Regenerate.
1447         * generated/maxloc1_4_i4.c: Regenerate.
1448         * generated/maxloc1_4_i8.c: Regenerate.
1449         * generated/maxloc1_4_r10.c: Regenerate.
1450         * generated/maxloc1_4_r16.c: Regenerate.
1451         * generated/maxloc1_4_r4.c: Regenerate.
1452         * generated/maxloc1_4_r8.c: Regenerate.
1453         * generated/maxloc1_8_i1.c: Regenerate.
1454         * generated/maxloc1_8_i16.c: Regenerate.
1455         * generated/maxloc1_8_i2.c: Regenerate.
1456         * generated/maxloc1_8_i4.c: Regenerate.
1457         * generated/maxloc1_8_i8.c: Regenerate.
1458         * generated/maxloc1_8_r10.c: Regenerate.
1459         * generated/maxloc1_8_r16.c: Regenerate.
1460         * generated/maxloc1_8_r4.c: Regenerate.
1461         * generated/maxloc1_8_r8.c: Regenerate.
1462         * generated/maxval_i1.c: Regenerate.
1463         * generated/maxval_i16.c: Regenerate.
1464         * generated/maxval_i2.c: Regenerate.
1465         * generated/maxval_i4.c: Regenerate.
1466         * generated/maxval_i8.c: Regenerate.
1467         * generated/maxval_r10.c: Regenerate.
1468         * generated/maxval_r16.c: Regenerate.
1469         * generated/maxval_r4.c: Regenerate.
1470         * generated/maxval_r8.c: Regenerate.
1471         * generated/minloc0_16_i1.c: Regenerate.
1472         * generated/minloc0_16_i16.c: Regenerate.
1473         * generated/minloc0_16_i2.c: Regenerate.
1474         * generated/minloc0_16_i4.c: Regenerate.
1475         * generated/minloc0_16_i8.c: Regenerate.
1476         * generated/minloc0_16_r10.c: Regenerate.
1477         * generated/minloc0_16_r16.c: Regenerate.
1478         * generated/minloc0_16_r4.c: Regenerate.
1479         * generated/minloc0_16_r8.c: Regenerate.
1480         * generated/minloc0_4_i1.c: Regenerate.
1481         * generated/minloc0_4_i16.c: Regenerate.
1482         * generated/minloc0_4_i2.c: Regenerate.
1483         * generated/minloc0_4_i4.c: Regenerate.
1484         * generated/minloc0_4_i8.c: Regenerate.
1485         * generated/minloc0_4_r10.c: Regenerate.
1486         * generated/minloc0_4_r16.c: Regenerate.
1487         * generated/minloc0_4_r4.c: Regenerate.
1488         * generated/minloc0_4_r8.c: Regenerate.
1489         * generated/minloc0_8_i1.c: Regenerate.
1490         * generated/minloc0_8_i16.c: Regenerate.
1491         * generated/minloc0_8_i2.c: Regenerate.
1492         * generated/minloc0_8_i4.c: Regenerate.
1493         * generated/minloc0_8_i8.c: Regenerate.
1494         * generated/minloc0_8_r10.c: Regenerate.
1495         * generated/minloc0_8_r16.c: Regenerate.
1496         * generated/minloc0_8_r4.c: Regenerate.
1497         * generated/minloc0_8_r8.c: Regenerate.
1498         * generated/minloc1_16_i1.c: Regenerate.
1499         * generated/minloc1_16_i16.c: Regenerate.
1500         * generated/minloc1_16_i2.c: Regenerate.
1501         * generated/minloc1_16_i4.c: Regenerate.
1502         * generated/minloc1_16_i8.c: Regenerate.
1503         * generated/minloc1_16_r10.c: Regenerate.
1504         * generated/minloc1_16_r16.c: Regenerate.
1505         * generated/minloc1_16_r4.c: Regenerate.
1506         * generated/minloc1_16_r8.c: Regenerate.
1507         * generated/minloc1_4_i1.c: Regenerate.
1508         * generated/minloc1_4_i16.c: Regenerate.
1509         * generated/minloc1_4_i2.c: Regenerate.
1510         * generated/minloc1_4_i4.c: Regenerate.
1511         * generated/minloc1_4_i8.c: Regenerate.
1512         * generated/minloc1_4_r10.c: Regenerate.
1513         * generated/minloc1_4_r16.c: Regenerate.
1514         * generated/minloc1_4_r4.c: Regenerate.
1515         * generated/minloc1_4_r8.c: Regenerate.
1516         * generated/minloc1_8_i1.c: Regenerate.
1517         * generated/minloc1_8_i16.c: Regenerate.
1518         * generated/minloc1_8_i2.c: Regenerate.
1519         * generated/minloc1_8_i4.c: Regenerate.
1520         * generated/minloc1_8_i8.c: Regenerate.
1521         * generated/minloc1_8_r10.c: Regenerate.
1522         * generated/minloc1_8_r16.c: Regenerate.
1523         * generated/minloc1_8_r4.c: Regenerate.
1524         * generated/minloc1_8_r8.c: Regenerate.
1525         * generated/minval_i1.c: Regenerate.
1526         * generated/minval_i16.c: Regenerate.
1527         * generated/minval_i2.c: Regenerate.
1528         * generated/minval_i4.c: Regenerate.
1529         * generated/minval_i8.c: Regenerate.
1530         * generated/minval_r10.c: Regenerate.
1531         * generated/minval_r16.c: Regenerate.
1532         * generated/minval_r4.c: Regenerate.
1533         * generated/minval_r8.c: Regenerate.
1534         * generated/misc_specifics.F90: Regenerate.
1535         * generated/nearest_r10.c: Regenerate.
1536         * generated/nearest_r16.c: Regenerate.
1537         * generated/nearest_r4.c: Regenerate.
1538         * generated/nearest_r8.c: Regenerate.
1539         * generated/pack_c10.c: Regenerate.
1540         * generated/pack_c16.c: Regenerate.
1541         * generated/pack_c4.c: Regenerate.
1542         * generated/pack_c8.c: Regenerate.
1543         * generated/pack_i1.c: Regenerate.
1544         * generated/pack_i16.c: Regenerate.
1545         * generated/pack_i2.c: Regenerate.
1546         * generated/pack_i4.c: Regenerate.
1547         * generated/pack_i8.c: Regenerate.
1548         * generated/pack_r10.c: Regenerate.
1549         * generated/pack_r16.c: Regenerate.
1550         * generated/pack_r4.c: Regenerate.
1551         * generated/pack_r8.c: Regenerate.
1552         * generated/pow_c10_i16.c: Regenerate.
1553         * generated/pow_c10_i4.c: Regenerate.
1554         * generated/pow_c10_i8.c: Regenerate.
1555         * generated/pow_c16_i16.c: Regenerate.
1556         * generated/pow_c16_i4.c: Regenerate.
1557         * generated/pow_c16_i8.c: Regenerate.
1558         * generated/pow_c4_i16.c: Regenerate.
1559         * generated/pow_c4_i4.c: Regenerate.
1560         * generated/pow_c4_i8.c: Regenerate.
1561         * generated/pow_c8_i16.c: Regenerate.
1562         * generated/pow_c8_i4.c: Regenerate.
1563         * generated/pow_c8_i8.c: Regenerate.
1564         * generated/pow_i16_i16.c: Regenerate.
1565         * generated/pow_i16_i4.c: Regenerate.
1566         * generated/pow_i16_i8.c: Regenerate.
1567         * generated/pow_i4_i16.c: Regenerate.
1568         * generated/pow_i4_i4.c: Regenerate.
1569         * generated/pow_i4_i8.c: Regenerate.
1570         * generated/pow_i8_i16.c: Regenerate.
1571         * generated/pow_i8_i4.c: Regenerate.
1572         * generated/pow_i8_i8.c: Regenerate.
1573         * generated/pow_r10_i16.c: Regenerate.
1574         * generated/pow_r10_i8.c: Regenerate.
1575         * generated/pow_r16_i16.c: Regenerate.
1576         * generated/pow_r16_i8.c: Regenerate.
1577         * generated/pow_r4_i16.c: Regenerate.
1578         * generated/pow_r4_i8.c: Regenerate.
1579         * generated/pow_r8_i16.c: Regenerate.
1580         * generated/pow_r8_i8.c: Regenerate.
1581         * generated/product_c10.c: Regenerate.
1582         * generated/product_c16.c: Regenerate.
1583         * generated/product_c4.c: Regenerate.
1584         * generated/product_c8.c: Regenerate.
1585         * generated/product_i1.c: Regenerate.
1586         * generated/product_i16.c: Regenerate.
1587         * generated/product_i2.c: Regenerate.
1588         * generated/product_i4.c: Regenerate.
1589         * generated/product_i8.c: Regenerate.
1590         * generated/product_r10.c: Regenerate.
1591         * generated/product_r16.c: Regenerate.
1592         * generated/product_r4.c: Regenerate.
1593         * generated/product_r8.c: Regenerate.
1594         * generated/reshape_c10.c: Regenerate.
1595         * generated/reshape_c16.c: Regenerate.
1596         * generated/reshape_c4.c: Regenerate.
1597         * generated/reshape_c8.c: Regenerate.
1598         * generated/reshape_i16.c: Regenerate.
1599         * generated/reshape_i4.c: Regenerate.
1600         * generated/reshape_i8.c: Regenerate.
1601         * generated/reshape_r10.c: Regenerate.
1602         * generated/reshape_r16.c: Regenerate.
1603         * generated/reshape_r4.c: Regenerate.
1604         * generated/reshape_r8.c: Regenerate.
1605         * generated/rrspacing_r10.c: Regenerate.
1606         * generated/rrspacing_r16.c: Regenerate.
1607         * generated/rrspacing_r4.c: Regenerate.
1608         * generated/rrspacing_r8.c: Regenerate.
1609         * generated/set_exponent_r10.c: Regenerate.
1610         * generated/set_exponent_r16.c: Regenerate.
1611         * generated/set_exponent_r4.c: Regenerate.
1612         * generated/set_exponent_r8.c: Regenerate.
1613         * generated/shape_i16.c: Regenerate.
1614         * generated/shape_i4.c: Regenerate.
1615         * generated/shape_i8.c: Regenerate.
1616         * generated/spacing_r10.c: Regenerate.
1617         * generated/spacing_r16.c: Regenerate.
1618         * generated/spacing_r4.c: Regenerate.
1619         * generated/spacing_r8.c: Regenerate.
1620         * generated/spread_c10.c: Regenerate.
1621         * generated/spread_c16.c: Regenerate.
1622         * generated/spread_c4.c: Regenerate.
1623         * generated/spread_c8.c: Regenerate.
1624         * generated/spread_i1.c: Regenerate.
1625         * generated/spread_i16.c: Regenerate.
1626         * generated/spread_i2.c: Regenerate.
1627         * generated/spread_i4.c: Regenerate.
1628         * generated/spread_i8.c: Regenerate.
1629         * generated/spread_r10.c: Regenerate.
1630         * generated/spread_r16.c: Regenerate.
1631         * generated/spread_r4.c: Regenerate.
1632         * generated/spread_r8.c: Regenerate.
1633         * generated/sum_c10.c: Regenerate.
1634         * generated/sum_c16.c: Regenerate.
1635         * generated/sum_c4.c: Regenerate.
1636         * generated/sum_c8.c: Regenerate.
1637         * generated/sum_i1.c: Regenerate.
1638         * generated/sum_i16.c: Regenerate.
1639         * generated/sum_i2.c: Regenerate.
1640         * generated/sum_i4.c: Regenerate.
1641         * generated/sum_i8.c: Regenerate.
1642         * generated/sum_r10.c: Regenerate.
1643         * generated/sum_r16.c: Regenerate.
1644         * generated/sum_r4.c: Regenerate.
1645         * generated/sum_r8.c: Regenerate.
1646         * generated/transpose_c10.c: Regenerate.
1647         * generated/transpose_c16.c: Regenerate.
1648         * generated/transpose_c4.c: Regenerate.
1649         * generated/transpose_c8.c: Regenerate.
1650         * generated/transpose_i16.c: Regenerate.
1651         * generated/transpose_i4.c: Regenerate.
1652         * generated/transpose_i8.c: Regenerate.
1653         * generated/transpose_r10.c: Regenerate.
1654         * generated/transpose_r16.c: Regenerate.
1655         * generated/transpose_r4.c: Regenerate.
1656         * generated/transpose_r8.c: Regenerate.
1657         * generated/unpack_c10.c: Regenerate.
1658         * generated/unpack_c16.c: Regenerate.
1659         * generated/unpack_c4.c: Regenerate.
1660         * generated/unpack_c8.c: Regenerate.
1661         * generated/unpack_i1.c: Regenerate.
1662         * generated/unpack_i16.c: Regenerate.
1663         * generated/unpack_i2.c: Regenerate.
1664         * generated/unpack_i4.c: Regenerate.
1665         * generated/unpack_i8.c: Regenerate.
1666         * generated/unpack_r10.c: Regenerate.
1667         * generated/unpack_r16.c: Regenerate.
1668         * generated/unpack_r4.c: Regenerate.
1669         * generated/unpack_r8.c: Regenerate.
1670
1671 2009-04-08  Janne Blomqvist  <jb@gcc.gnu.org>
1672
1673         * io/open.c (already_open): Test for POSIX close return value.
1674         * io/unit.c (close_unit_1): Likewise.
1675         * io/unix.c (raw_close): Return 0 for success for preconnected units.
1676
1677 2009-04-08  Janne Blomqvist  <jb@gcc.gnu.org>
1678
1679         * runtime/string.c (compare0): Use gfc_charlen_type.
1680         * runtime/error.c (gfc_itoa): Move to io/write.c
1681         (xtoa): Rename to gfc_xtoa.
1682         * runtime/backtrace.c (show_backtrace): Call gfc_xtoa.
1683         * intrinsics/cshift0.c (cshift0): Use index_type for shift arg.
1684         * intrinsics/date_and_time.c (date_and_time): Use index_type.
1685         (itime_i4): Likewise.
1686         (itime_i8): Likewise.
1687         (idate_i4): Likewise.
1688         (idate_i8): Likewise.
1689         (gmtime_i4): Likewise.
1690         (gmtime_i8): Likewise.
1691         (ltime_i4): Likewise.
1692         (ltime_i8): Likewise.
1693         * libgfortran.h (gfc_itoa): Remove prototype.
1694         (xtoa): Rename prototype to gfc_xtoa.
1695         * io/list_read.c (nml_read_obj): Use size_t for string length.
1696         * io/transfer.c (read_block_direct): Change nbytes arg from
1697         pointer to value.
1698         (unformatted_read): Minor cleanup, call read_block_directly properly.
1699         (skip_record): Use ssize_t.
1700         (next_record_w_unf): Avoid stell() call by calling sseek with SEEK_CUR.
1701         (iolength_transfer): Make sure to multiply before cast.
1702         * io/intrinsics.c (fgetc): Remove unnecessary variable.
1703         * io/format.c (format_hash): Use gfc_charlen_type.
1704         * io/write.c (itoa): Move from runtime/error.c:gfc_itoa, rename,
1705         make static.
1706         (write_i): Call with pointer to itoa.
1707         (write_z): Call with pointer to gfc_xtoa.
1708         (write_integer): Pointer to itoa.
1709         (nml_write_obj): Type cleanup, don't call strlen in loop.
1710         
1711 2009-04-06  H.J. Lu  <hongjiu.lu@intel.com>
1712
1713         PR libgfortran/39664
1714         * io/unix.c (raw_close): Don't close STDOUT_FILENO,
1715         STDERR_FILENO nor STDIN_FILENO.
1716
1717 2009-04-06  David Edelsohn  <edelsohn@gnu.org>
1718         
1719         * io/io.h (struct stream): Rename truncate to trunc.
1720         (struncate): Same.
1721         * io/unix.c (raw_init): Rename truncate to trunc.
1722         (buf_init): Same.
1723         (open_internal): Same.
1724         
1725 2009-04-05  Daniel Kraft  <d@domob.eu>
1726
1727         PR fortran/38654
1728         * io/read.c (read_f): Reworked to speed up floating point parsing.
1729         (convert_real): Use pointer-casting instead of memcpy and temporaries.
1730
1731 2009-04-05  Jerry DeLisle  <jvdelisle@gcc.gnu.org>
1732
1733         PR libfortran/37754
1734         * io/io.h (format_hash_entry): New structure for hash table.
1735         (format_hash_table): The hash table itself.
1736         (free_format_data): Revise function prototype.
1737         (free_format_hash_table, init_format_hash,
1738         free_format_hash): New function prototypes.
1739         * io/unit.c (close_unit_1): Use free_format_hash_table.
1740         * io/transfer.c (st_read_done, st_write_done): Free format data if
1741         internal unit.
1742         * io/format.c (free_format_hash_table): New function that frees any
1743         memory allocated previously for cached format data.
1744         (reset_node): New static helper function to reset the format counters
1745         for a format node.
1746         (reset_fnode_counters): New static function recursively calls reset_node
1747         to traverse the fnode tree.
1748         (format_hash): New simple hash function based on XOR, probabalistic,
1749         tosses collisions.
1750         (save_parsed_format): New static function to save the parsed format
1751         data to use again.
1752         (find_parsed_format): New static function searches the hash table
1753         looking for a match.
1754         (free_format_data): Revised to accept pointer to format data rather than
1755         the dtp pointer so that the function can be used in more places.
1756         (format_lex): Editorial.
1757         (parse_format_list): Set flag used to determine of format data hashing
1758         is to be used.  Internal units are not persistent enough for this.
1759         (revert): Move to ne location in file.
1760         (parse_format): Use new functions to look for previously parsed
1761         format strings and use them rather than re-parse.  If not found, saves
1762         the parsed format data for later use.
1763         
1764 2009-04-05  Jerry DeLisle  <jvdelisle@gcc.gnu.org>
1765
1766         PR libfortran/37754
1767         * io/transfer.c (formatted_transfer_scalar): Remove this function by
1768         factoring it into two new functions, one for read and one for write,
1769         eliminating all the conditionals for read or write mode.
1770         (formatted transfer_scalar_read): New function.
1771         (formatted transfer_scalar_write): New function.
1772         (formatted_transfer): Use new functions.
1773
1774 2009-04-05  Janne Blomqvist  <jb@gcc.gnu.org>
1775
1776         PR libfortran/25561 libfortran/37754
1777         * io/io.h (struct stream): Define new stream interface function
1778         pointers, and inline functions for accessing it.
1779         (struct fbuf): Use int instead of size_t, remove flushed element.
1780         (mem_alloc_w): New prototype.
1781         (mem_alloc_r): New prototype.
1782         (stream_at_bof): Remove prototype.
1783         (stream_at_eof): Remove prototype.
1784         (file_position): Remove prototype.
1785         (flush): Remove prototype.
1786         (stream_offset): Remove prototype.
1787         (unit_truncate): New prototype.
1788         (read_block_form): Change to return pointer, int* argument.
1789         (hit_eof): New prototype.
1790         (fbuf_init): Change prototype.
1791         (fbuf_reset): Change prototype.
1792         (fbuf_alloc): Change prototype.
1793         (fbuf_flush): Change prototype.
1794         (fbuf_seek): Change prototype.
1795         (fbuf_read): New prototype.
1796         (fbuf_getc_refill): New prototype.
1797         (fbuf_getc): New inline function.
1798         * io/fbuf.c (fbuf_init): Use int, get rid of flushed.
1799         (fbuf_debug): New function.
1800         (fbuf_reset): Flush, and return position offset.
1801         (fbuf_alloc): Simplify, don't flush, just realloc.
1802         (fbuf_flush): Make usable for read mode, salvage remaining bytes.
1803         (fbuf_seek): New whence argument.
1804         (fbuf_read): New function.
1805         (fbuf_getc_refill): New function.
1806         * io/file_pos.c (formatted_backspace): Use new stream interface.
1807         (unformatted_backspace): Likewise.
1808         (st_backspace): Make sure format buffer is reset, use new stream
1809         interface, use unit_truncate.
1810         (st_endfile): Likewise.
1811         (st_rewind): Likewise.
1812         * io/intrinsics.c: Use new stream interface.
1813         * io/list_read.c (push_char): Don't use u.p.scratch, use realloc
1814         to resize.
1815         (free_saved): Don't check u.p.scratch.
1816         (next_char): Use new stream interface, use fbuf_getc() for external files.
1817         (finish_list_read): flush format buffer.
1818         (nml_query): Update to use modified interface:s
1819         * io/open.c (test_endfile): Use new stream interface.
1820         (edit_modes): Likewise.
1821         (new_unit): Likewise, set bytes_left to 1 for stream files.
1822         * io/read.c (read_l): Use new read_block_form interface.
1823         (read_utf8): Likewise.
1824         (read_utf8_char1): Likewise.
1825         (read_default_char1): Likewise.
1826         (read_utf8_char4): Likewise.
1827         (read_default_char4): Likewise.
1828         (read_a): Likewise.
1829         (read_a_char4): Likewise.
1830         (read_decimal): Likewise.
1831         (read_radix): Likewise.
1832         (read_f): Likewise.
1833         * io/transfer.c (read_sf): Use fbuf_read and mem_alloc_r, remove
1834         usage of u.p.line_buffer.
1835         (read_block_form): Update interface to return pointer, use
1836         fbuf_read for direct access.
1837         (read_block_direct): Update to new stream interface.
1838         (write_block): Use mem_alloc_w for internal I/O.
1839         (write_buf): Update to new stream interface.
1840         (formatted_transfer_scalar): Don't use u.p.line_buffer, use
1841         fbuf_seek for external files.
1842         (us_read): Update to new stream interface.
1843         (us_write): Likewise.
1844         (data_transfer_init): Always check if we switch modes and flush.
1845         (skip_record): Use new stream interface, fix comparison.
1846         (next_record_r): Check for and reset u.p.at_eof, use new stream
1847         interface, use fbuf_getc for spacing.
1848         (write_us_marker): Update to new stream interface, don't inline.
1849         (next_record_w_unf): Likewise.
1850         (sset): New function.
1851         (next_record_w): Use new stream interface, use fbuf for printing
1852         newline.
1853         (next_record): Use new stream interface.
1854         (finalize_transfer): Remove sfree call, use new stream interface.
1855         (st_iolength_done): Don't use u.p.scratch.
1856         (st_read): Don't check for end of file.
1857         (st_read_done): Don't use u.p.scratch, use unit_truncate.
1858         (hit_eof): New function.
1859         * io/unit.c (init_units): Always init fbuf for formatted units.
1860         (update_position): Use new stream interface.
1861         (unit_truncate): New function.
1862         (finish_last_advance_record): Use fbuf to print newline.
1863         * io/unix.c: Remove unused SSIZE_MAX macro.
1864         (BUFFER_SIZE): Make static const variable rather than macro.
1865         (struct unix_stream): Remove dirty_offset, len, method,
1866         small_buffer. Order elements by decreasing size.
1867         (struct int_stream): Remove.
1868         (move_pos_offset): Remove usage of dirty_offset.
1869         (reset_stream): Remove.
1870         (do_read): Rename to raw_read, update to match new stream
1871         interface.
1872         (do_write): Rename to raw_write, update to new stream interface.
1873         (raw_seek): New function.
1874         (raw_tell): New function.
1875         (raw_truncate): New function.
1876         (raw_close): New function.
1877         (raw_flush): New function.
1878         (raw_init): New function.
1879         (fd_alloc): Remove.
1880         (fd_alloc_r_at): Remove.
1881         (fd_alloc_w_at): Remove.
1882         (fd_sfree): Remove.
1883         (fd_seek): Remove.
1884         (fd_truncate): Remove.
1885         (fd_sset): Remove.
1886         (fd_read): Remove.
1887         (fd_write): Remove.
1888         (fd_close): Remove.
1889         (fd_open): Remove.
1890         (fd_flush): Rename to buf_flush, update to new stream interface
1891         and unix_stream.
1892         (buf_read): New function.
1893         (buf_write): New function.
1894         (buf_seek): New function.
1895         (buf_tell): New function.
1896         (buf_truncate): New function.
1897         (buf_close): New function.
1898         (buf_init): New function.
1899         (mem_alloc_r_at): Rename to mem_alloc_r, change prototype.
1900         (mem_alloc_w_at): Rename to mem_alloc_w, change prototype.
1901         (mem_read): Change to match new stream interface.
1902         (mem_write): Likewise.
1903         (mem_seek): Likewise.
1904         (mem_tell): Likewise.
1905         (mem_truncate): Likewise.
1906         (mem_close): Likewise.
1907         (mem_flush): New function.
1908         (mem_sfree): Remove.
1909         (empty_internal_buffer): Cast to correct type.
1910         (open_internal): Use correct type, init function pointers.
1911         (fd_to_stream): Test whether to open file as buffered or raw.
1912         (output_stream): Remove mode set.
1913         (error_stream): Likewise.
1914         (flush_all_units_1): Use new stream interface.
1915         (flush_all_units): Likewise.
1916         (stream_at_bof): Remove.
1917         (stream_at_eof): Remove.
1918         (file_position): Remove.
1919         (file_length): Update logic to use stream interface.
1920         (flush): Remove.
1921         (stream_offset): Remove.
1922         * io/write.c (write_utf8_char4): Use int instead of size_t.
1923         (write_x): Extra safety check.
1924         (namelist_write_newline): Use new stream interface.
1925
1926 2009-03-29  John David Anglin  <dave.anglin@nrc-cnrc.gc.ca>
1927
1928         PR fortran/33595
1929         * intrinsics/c99_functions.c (round): Use floor instead of ceil.
1930         Revise checks to round up.
1931         (roundf): Likewise.
1932
1933 2009-03-28  Daniel Kraft  <d@domob.eu>
1934
1935         * intrinsics/string_intrinsics.c: #include <assert.h>
1936         * intrinsics/string_intrinsics_inc.c (string_trim): Use string_len_trim
1937         instead of calculating the length directly.
1938         (string_len_trim): For KIND=1, speed search up.
1939
1940 2009-03-24  Jerry DeLisle  <jvdelisle@gcc.gnu.org>
1941
1942         PR libfortran/39528
1943         * io/list_read.c (list_formatted_read_scalar): Move check for read
1944         completion to just after the check for a repeated value.
1945
1946 2009-03-08  Jerry DeLisle  <jvdelisle@gcc.gnu.org>
1947
1948         PR libfortran/39402
1949         * io/write_float.def (output_float): Handle F0.d formatting correctly
1950         for any d when value is 0.0.
1951
1952 2009-03-01  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
1953
1954         * configure: Regenerate.
1955
1956 2009-01-21  Daniel Kraft  <d@domob.eu>
1957
1958         PR fortran/38887
1959         * runtime/in_unpack_generic.c (internal_unpack):  Return instead of
1960         abort when called with empty array.
1961         * m4/in_unpack.m4:  Ditto.
1962         * generated/in_unpack_i1.c:  Regenerated.
1963         * generated/in_unpack_i2.c:  Regenerated.
1964         * generated/in_unpack_i4.c:  Regenerated.
1965         * generated/in_unpack_i8.c:  Regenerated.
1966         * generated/in_unpack_i16.c: Regenerated.
1967         * generated/in_unpack_r4.c:  Regenerated.
1968         * generated/in_unpack_r8.c:  Regenerated.
1969         * generated/in_unpack_r10.c: Regenerated.
1970         * generated/in_unpack_r16.c: Regenerated.
1971         * generated/in_unpack_c4.c:  Regenerated.
1972         * generated/in_unpack_c8.c:  Regenerated.
1973         * generated/in_unpack_c10.c: Regenerated.
1974         * generated/in_unpack_c16.c: Regenerated.
1975
1976 2009-01-12  Jerry DeLisle  <jvdelisle@gcc.gnu.org>
1977
1978         PR libfortran/38772
1979         * io/read.c (read_f): Clean up loop conditions for BZ/BN,
1980         allowing proper digit testing. White space fix.
1981
1982 2009-01-05  Jerry DeLisle  <jvdelisle@gcc.gnu.org>
1983
1984         PR libfortran/38735
1985         * io/unit.c (get_internal_unit): Set default BLANK= status to NULL for
1986         internal units.
1987
1988 2008-12-29  John David Anglin  <dave.anglin@nrc-cnrc.gc.ca>
1989
1990         PR fortran/31832
1991         * acinclude.m4 (LIBGFOR_CHECK_FOR_BROKEN_POWF): New autoconf check for
1992         broken powf.
1993         * configure.ac (LIBGFOR_CHECK_FOR_BROKEN_POWF): Use it.
1994         * intrinsics/c99_functions.c: Use internal powf implementation if
1995         HAVE_BROKEN_POWF is defined.
1996         * configure: Rebuilt.
1997         * config.h.in: Rebuilt.
1998
1999 2008-12-22  Jerry DeLisle  <jvdelisle@gcc.gnu.org>
2000
2001         PR libfortran/37472
2002         * io/write_float.def (output_float_FMT_G_): Modify calculation of temp
2003         to avoid sensitivity to round-off.
2004
2005 2008-12-21  Jerry DeLisle  <jvdelisle@gcc.gnu.org>
2006
2007         PR libfortran/38398
2008         * io/io.h (st_parameter_dt): Add new bit to keep track of when to
2009         suppress blanks for g0 formatting.
2010         * io/transfer.c (formatted_transfer_scalar): Always call write_real_g0
2011         for g0 formatting.
2012         * io.c (write.c): Do not use ES formatting and use new bit to suppress
2013         blanks.
2014         * io/write_float.def (output_float): Adjust the location of setting the
2015         width so that it can be adjusted when suppressing blanks.  Set number of
2016         blanks to zero when dtp->u.p.g0_no_blanks is set. Do some minor code
2017         clean-up and add some white space for readability.
2018         
2019 2008-12-18  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
2020
2021         * configure: Regenerate.
2022
2023 2008-12-13  Jerry DeLisle  <jvdelisle@gcc.gnu.org>
2024
2025         PR libfortran/38504
2026         io/write.c (write_decimal): Skip extra sign '-' at beginning of string
2027         returned by gfc_itoa.
2028
2029 2008-12-08  Jerry DeLisle  <jvdelisle@gcc.gnu.org>
2030
2031         PR libfortran/38430
2032         * io/transfer.c (data_transfer_init): Move constraint check for REC=
2033         and STREAM access into condition for other REC= constraints to simplify.
2034         Comment out this constraint to avoid breaking compatibility with 4.3
2035         until later.  Added a TODO for above comment and this one.
2036         Fix test for max pos.
2037
2038 2008-12-06  Jerry DeLisle  <jvdelisle@gcc.gnu.org>
2039
2040         PR libfortran/38291
2041         * io/transfer.c (data_transfer_init): Add fbuf_flush inadvertently
2042         ommitted.  Add check for invalid use of REC= with ACCESS="stream".  Fix
2043         comment.
2044
2045 2008-12-06  Adam Nemet  <anemet@caviumnetworks.com>
2046
2047         * runtime/main.c (store_exe_path): Don't crash if argv0 is NULL.
2048
2049 2008-12-05  Jerry DeLisle  <jvdelisle@gcc.gnu.org>
2050
2051         PR libfortran/38291
2052         * io/transfer.c (data_transfer_init): Add checks for POS= valid range.
2053         Add check for unit opened with ACCESS="stream". Flush and seek if
2054         current stream position does not match. Check ENDFILE on read.
2055
2056 2008-12-04  Jerry DeLisle  <jvdelisle@gcc.gnu.org>
2057
2058         PR fortran/38285
2059         * write_float.def (WRITE_FLOAT): Zero the float value for special case
2060         only if scale_factor = 0.
2061         
2062 2008-11-23  Thomas Koenig  <tkoenig@gcc.gnu.org>
2063
2064         PR libfortran/38234
2065         * intrinsics/reshape_generic.c (reshape_internal):
2066         Source can be larger than shape.
2067         * m4/reshape.m4:  Likewise.
2068         * generated/reshape_c10.c Regenerated.
2069         * generated/reshape_c16.c Regenerated.
2070         * generated/reshape_c4.c Regenerated.
2071         * generated/reshape_c8.c Regenerated.
2072         * generated/reshape_i16.c Regenerated.
2073         * generated/reshape_i4.c Regenerated.
2074         * generated/reshape_i8.c Regenerated.
2075         * generated/reshape_r10.c Regenerated.
2076         * generated/reshape_r16.c Regenerated.
2077         * generated/reshape_r4.c Regenerated.
2078         * generated/reshape_r8.c Regenerated.
2079
2080 2008-11-22  Danny Smith  <dannysmith@users.sourceforge.net>
2081
2082         * libgfortran.h (__mingw_snprintf): Declare with gnu_printf
2083         format attribute.
2084
2085
2086 2008-11-22  Thomas Koenig  <tkoenig@gcc.gnu.org>
2087
2088         PR libfortran/38225
2089         * intrinsics/reshape_generic.c (reshape_internal):
2090         Use all dimensions of source for bounds checking.
2091         * m4/reshape.m4:  Likewise.
2092         * generated/reshape_c10.c Regenerated.
2093         * generated/reshape_c16.c Regenerated.
2094         * generated/reshape_c4.c Regenerated.
2095         * generated/reshape_c8.c Regenerated.
2096         * generated/reshape_i16.c Regenerated.
2097         * generated/reshape_i4.c Regenerated.
2098         * generated/reshape_i8.c Regenerated.
2099         * generated/reshape_r10.c Regenerated.
2100         * generated/reshape_r16.c Regenerated.
2101         * generated/reshape_r4.c Regenerated.
2102         * generated/reshape_r8.c Regenerated.
2103
2104 2008-11-22  Jakub Jelinek  <jakub@redhat.com>
2105
2106         PR libfortran/37839
2107         * io/io.h (IOPARM_INQUIRE_HAS_ROUND, IOPARM_INQUIRE_HAS_SIGN,
2108         IOPARM_INQUIRE_HAS_PENDING): Adjust values.
2109         (st_parameter_inquire): Reorder and fix types of round, sign and
2110         pending fields.
2111         (st_parameter_43, st_parameter_44): Removed.
2112         (st_parameter_dt): Put back struct definition directly to u.p
2113         declaration.  Change type of u.p.size_used from gfc_offset to
2114         GFC_IO_INT.  Decrease back size of u.pad to 16 pointers and
2115         32 ints.  Put id, pos, asynchronous, blank, decimal, delim,
2116         pad, round and sign fields after the union.
2117         * io/inquire.c (inquire_via_unit, inquire_via_filename): Only read
2118         flags2 if it is defined.
2119         * io/transfer.c (read_sf, read_block_form, write_block): Cast
2120         additions to size_used to GFC_IO_INT instead of gfc_offset.
2121         (data_transfer_init): Clear whole u.p struct.  Adjust
2122         for moving id, pos, asynchronous, blank, decimal, delim, pad,
2123         round and sign fields from u.p directly into st_parameter_dt.
2124         (finalize_transfer): Don't cast size_used to GFC_IO_INT.
2125         * io/file_pos.c (st_endfile): Clear whole u.p struct.
2126
2127 2008-11-20  Jerry DeLisle  <jvdelisle@gcc.gnu.org>
2128
2129         PR libfortran/37472
2130         * io/write_float.def (output_float_FMT_G_): Adjust conversion of
2131         G format specification to F format.
2132
2133 2008-11-18  Thomas Koenig  <tkoenig@gcc.gnu.org>
2134
2135         PR libfortran/38135
2136         * m4/reshape.m4:  Correct bounds checking when PAD is present.
2137         Treat PAD as if it were SOURCE when SOURCE is empty.
2138         * intrinsics/reshape_generic.c:  Likewise.
2139         * generated/reshape_c10.c Regenerated.
2140         * generated/reshape_c16.c Regenerated.
2141         * generated/reshape_c4.c Regenerated.
2142         * generated/reshape_c8.c Regenerated.
2143         * generated/reshape_i16.c Regenerated.
2144         * generated/reshape_i4.c Regenerated.
2145         * generated/reshape_i8.c Regenerated.
2146         * generated/reshape_r10.c Regenerated.
2147         * generated/reshape_r16.c Regenerated.
2148         * generated/reshape_r4.c Regenerated.
2149         * generated/reshape_r8.c Regenerated.
2150
2151 2008-11-16  Jerry DeLisle  <jvdelisle@gcc.gnu.org>
2152
2153         PR libfortran/38097
2154         * io/read.c (read_f): Initialize exponent. Fix comment. Set loop
2155         conditions for BZ/BN.
2156         * io/unit.c (get_internal_unit): Initialize flags.blank.
2157         * io/transfer.c (data_transfer_init): Fix whitespace.
2158
2159 2008-11-15  Jerry DeLisle  <jvdelisle@gcc.gnu.org>
2160
2161         PR libfortran/37294
2162         * io/write.c (namelist_write_newline): Use array loop specification to
2163         advance to next internal array unit record. (namelist_write): Adjust to
2164         accomodate the internal array unit behavior.
2165
2166 2008-11-01  Dennis Wassel  <dennis.wassel@gmail.com>
2167
2168         PR fortran/37159
2169         * intrinsics/random.c: Added comment to adapt check.c, should
2170         kiss_size change.
2171         Few cosmetic changes to existing comments.
2172
2173 2008-10-22  Jerry DeLisle  <jvdelisle@gcc.gnu.org>
2174
2175         PR libfortran/37707
2176         * io/list_read.c (read_character): Remove code to look ahead in namelist
2177         reads to descriminate non-delimited strings from namelist objects.
2178         * io/write.c (namelist_write): Delimit character strings with quote or
2179         apostrophe, defaulting to quote.
2180
2181 2008-10-21  Thomas Koenig  <tkoenig@gcc.gnu.org>
2182
2183         PR libfortran/34670
2184         * intrinsics/transpose_generic.c:  Implement bounds checking.
2185         * m4/transpose.m4:  Likewise.
2186         * generated/transpose_c8.c: Regenerated.
2187         * generated/transpose_c16.c: Regenerated.
2188         * generated/transpose_r10.c: Regenerated.
2189         * generated/transpose_i8.c: Regenerated.
2190         * generated/transpose_c10.c: Regenerated.
2191         * generated/transpose_r4.c: Regenerated.
2192         * generated/transpose_c4.c: Regenerated.
2193         * generated/transpose_i16.c: Regenerated.
2194         * generated/transpose_i4.c: Regenerated.
2195         * generated/transpose_r8.c: Regenerated.
2196         * generated/transpose_r16.c: Regenerated.
2197
2198 2008-10-19  Jerry DeLisle  <jvdelisle@gcc.gnu.org
2199
2200         PR libfortran/37834
2201         * io/write_float.def (output_float): Emit '0.' for special case of
2202         format specifier 'f0.0' and value of zero. Likewise emit '0' for 'f1.0'.
2203
2204 2008-10-17  Jerry DeLisle  <jvdelisle@gcc.gnu.org
2205
2206         PR libfortran/37863
2207         * io/write_float.def (WRITE_FLOAT): Round to 1.0 correctly.
2208         * io/io.h (st_parameter_44): Fix id type declaration.
2209
2210 2008-10-16  Thomas Koenig  <tkoenig@gcc.gnu.org>
2211
2212         * io/file_pos.c (unformatted_backspace): Normal case is
2213         GFC_CONVERT_NATIVE.
2214         * io/transfer.c (read_sf):  Mark paths leading to generate_error()
2215         as unlikely.
2216         (readl_block_form):  Likewise.
2217         (read_block_direct):  Likewise.
2218         (write_block):  Likewise.
2219         (write_buf):  Likewise.
2220         (us_read):  Likewise.  Normal case is GFC_CONVERT_NATIVE.
2221         (next_record_w_unf):  Mark paths leading to generate_error()
2222         as unlikely.
2223
2224 2008-10-16  Thomas Koenig  <tkoenig@gcc.gnu.org>
2225
2226         PR libfortran/34670
2227         * generated/spread_r4.c: Regenerated.
2228
2229 2008-10-15  Thomas Koenig  <tkoenig@gcc.gnu.org>
2230
2231         PR libfortran/34670
2232         * intrinsics/reshape_generic.c:  Add bounds checking.
2233         * m4/reshape.m4:  Likewise.
2234         * generated/reshape_c10.c: Regenerated.
2235         * generated/reshape_c16.c: Regenerated.
2236         * generated/reshape_c4.c: Regenerated.
2237         * generated/reshape_c8.c: Regenerated.
2238         * generated/reshape_i16.c: Regenerated.
2239         * generated/reshape_i4.c: Regenerated.
2240         * generated/reshape_i8.c: Regenerated.
2241         * generated/reshape_r10.c: Regenerated.
2242         * generated/reshape_r16.c: Regenerated.
2243         * generated/reshape_r4.c: Regenerated.
2244         * generated/reshape_r8.c: Regenerated.
2245         * generated/spread_r4.c: Regenerated.
2246
2247 2008-10-13  Jerry DeLisle  <jvdelisle@gcc.gnu.org
2248
2249         PR libfortran/37083
2250         * io/list_read.c (next_char): Simplify EOF tests and set endfile flag.
2251         (finish_list_read): Add EOF check.
2252
2253 2008-10-09  Thomas Koenig  <tkoenig@gcc.gnu.org>
2254
2255         PR libfortran/37753
2256         * io/transfer.c (unformatted_read):  CONVERT_NATIVE
2257         is the usual case.  Check for kind==1 for non-byte-reversing
2258         operation.
2259         (unformatted_write):  Likewise.
2260
2261 2008-10-08  Jerry DeLisle  <jvdelisle@gcc.gnu.org
2262
2263         PR libfortran/37707
2264         * io/list_read.c (nml_get_obj_data): If the first namelist object rank
2265         is greater than zero, call nml_object_read with the first object rather
2266         than the sub-object.
2267
2268 2008-09-26  Peter O'Gorman  <pogma@thewrittenword.com>
2269             Steve Ellcey  <sje@cup.hp.com>
2270
2271         * configure: Regenerate for new libtool.
2272         * Makefile.in: Ditto.
2273
2274 2008-09-25  Jerry DeLisle  <jvdelisle@gcc.gnu.org
2275
2276         PR libfortran/37498
2277         * list_read.c (eat_separator): Revert previous patch and move
2278         delim_status, decimal_status, and pad_status to gfc_unit.
2279         (parse_real): Ditto. (read_real): Ditto.
2280         * read.c (read_a): Likewise. (read_a_char4): Likewise.
2281         (read_f): Likewise.
2282         * inquire.c (inquire_via_unit): Add missing check for
2283         IOPARM_INQUIRE_HAS_FLAGS2. (inquire_via_filename): Likewise.
2284         * io.h (unit_sign_s): Move delim_status, decimal_status, and pad_status
2285         to gfc_unit.
2286         * transfer.c (read_sf): Ditto. (read_block_form): Ditto.
2287         (formatted_transfer_scalar): Ditto. (data_transfer_init): Ditto.
2288         * write.c (write_default_char4): Ditto. (write_utf8_char4): Ditto.
2289         (write_character): Ditto. (write_real_g0): Ditto.
2290         (list_formatted_write_scalar): Ditto. (nml_write_obj): Ditto.
2291         (namelist_write): Ditto.
2292         * write_float.def (calculate_sign): Ditto. (output_float): Ditto.
2293
2294 2008-09-24  Tobias Burnus  <burnus@net-b.de>
2295
2296         * runtime/compile_options.c (init_compile_options):
2297         Sync flags with front end.
2298
2299 2008-09-22  Jerry DeLisle  <jvdelisle@gcc.gnu.org
2300
2301         PR libfortran/37498
2302         * file_pos (st_endfile): Clear memory only for libfortran 4.3 private
2303         area.
2304         * list_read.c (eat_separator): Only access F2003 I/O parameters if
2305         IOPARM_DT_HAS_F2003 bit is set. (parse_real): Ditto.
2306         (read_real): Ditto.
2307         * read.c (read_a): Likewise. (read_a_char4): Likewise though not
2308         strictly necessary. (read_f): Likewise.
2309         * io.h (unit_sign_s): New enumerator to allow duplication of
2310         st_parameter structures. (IOPARM_DT_HAS_F2003): New mask bit.
2311         (st_parameter_43): New structure copied from 4.3 version of 
2312         st_paramater_dt private section. (st_parameter_44): New structure with
2313         F2003 items added. (st_parameter_dt): Modified to create union of new
2314         and old structures to allow correct memory setting for 4.3 ABI
2315         compatibility. Bumped the pad size.
2316         * transfer.c (read_sf): Do not use F2003 I/O memory areas unless
2317         IOPARM_DT_HAS_F2003 bit has been set. (read_block_form): Ditto.
2318         (formatted_transfer_scalar): Ditto. (data_transfer_init): Ditto and
2319         add comment, fix formatting.
2320         * write.c (write_default_char4): Likewise though not strictly necessary.
2321         (write_utf8_char4): Ditto. (write_character): Ditto.
2322         (write_real_g0): Ditto. (list_formatted_write_scalar): Ditto.
2323         (nml_write_obj): Ditto. (namelist_write): Ditto.
2324         * write_float.def (calculate_sign): Eliminate warning by including all
2325         cases in switch. (output_float): Output only decimal point of F2003 flag
2326         is not set.
2327
2328 2008-09-10  Tobias Burnus  <burnus@net-b.de>
2329             H. J. Lu  <hongjiu.lu@intel.com>
2330
2331         * mk-sik-inc.sh: Make -Wunused-variable proof.
2332         * mk-srk-inc.sh: Make -Wunused-variable proof.
2333
2334 2008-09-10  Tobias Burnus  <burnus@net-b.de>
2335
2336         * mk-kinds-h.sh: Make -Wunused-variable proof.
2337
2338 2008-09-07  Thomas Koenig  <tkoenig@gcc.gnu.org>
2339
2340         PR fortran/37203
2341         * intrinsics/reshape_generic.c:  Add checking on
2342         out-of-bounds and duplicate values of order argument.
2343         * m4/reshape.m4:  Likewise.
2344         * generated/reshape_c10.c: Regenerated.
2345         * generated/reshape_c16.c: Regenerated.
2346         * generated/reshape_c4.c: Regenerated.
2347         * generated/reshape_c8.c: Regenerated.
2348         * generated/reshape_i16.c: Regenerated.
2349         * generated/reshape_i4.c: Regenerated.
2350         * generated/reshape_i8.c: Regenerated.
2351         * generated/reshape_r10.c: Regenerated.
2352         * generated/reshape_r16.c: Regenerated.
2353         * generated/reshape_r4.c: Regenerated.
2354         * generated/reshape_r8.c: Regenerated.
2355
2356 2008-09-06  Tobias Burnus  <burnus@net-b.de>
2357
2358         * libgfortran.h (likely,unlikely): New makros.
2359         (runtime_warning_at,__mingw_snprintf): Add __attribute__(format()).
2360         * m4/spread.m4 (spread_'rtype_code`): Use unlikely for bounds_check.
2361         * m4/iforeach.m4 (name`'rtype_qual`_'atype_code): Ditto.
2362         * m4/matmull.m4 (matmul_'rtype_code`): Ditto.
2363         * m4/ifunction_logical.m4 (name`'rtype_qual`_'atype_code): Ditto.
2364         * m4/ifunction.m4 (name`'rtype_qual`_'atype_code): Ditto.
2365         * m4/matmul.m4 (matmul_'rtype_code`): Ditto.
2366
2367         * generated/minval_r8.c: Regenerated.
2368         * generated/spread_r10.c: Regenerated.
2369         * generated/minloc1_16_r16.c: Regenerated.
2370         * generated/maxloc1_4_r8.c: Regenerated.
2371         * generated/sum_i8.c: Regenerated.
2372         * generated/any_l16.c: Regenerated.
2373         * generated/spread_i8.c: Regenerated.
2374         * generated/maxval_i2.c: Regenerated.
2375         * generated/any_l2.c: Regenerated.
2376         * generated/product_r4.c: Regenerated.
2377         * generated/maxloc1_8_i4.c: Regenerated.
2378         * generated/maxloc0_4_r4.c: Regenerated.
2379         * generated/all_l1.c: Regenerated.
2380         * generated/matmul_r8.c: Regenerated.
2381         * generated/product_i2.c: Regenerated.
2382         * generated/minloc0_4_r16.c: Regenerated.
2383         * generated/minloc0_4_i1.c: Regenerated.
2384         * generated/maxloc0_4_r16.c: Regenerated.
2385         * generated/maxloc0_4_i2.c: Regenerated.
2386         * generated/minloc1_8_r16.c: Regenerated.
2387         * generated/maxloc1_8_r16.c: Regenerated.
2388         * generated/maxloc0_8_i8.c: Regenerated.
2389         * generated/sum_r16.c: Regenerated.
2390         * generated/sum_i1.c: Regenerated.
2391         * generated/minloc1_4_r8.c: Regenerated.
2392         * generated/maxloc1_16_r16.c: Regenerated.
2393         * generated/minloc1_16_i4.c: Regenerated.
2394         * generated/maxloc1_16_i4.c: Regenerated.
2395         * generated/minloc0_16_i8.c: Regenerated.
2396         * generated/spread_i1.c: Regenerated.
2397         * generated/maxloc0_16_i8.c: Regenerated.
2398         * generated/maxval_r16.c: Regenerated.
2399         * generated/product_c10.c: Regenerated.
2400         * generated/minloc1_8_i4.c: Regenerated.
2401         * generated/minloc0_16_i16.c: Regenerated.
2402         * generated/matmul_r16.c: Regenerated.
2403         * generated/minloc0_4_r4.c: Regenerated.
2404         * generated/all_l2.c: Regenerated.
2405         * generated/product_c4.c: Regenerated.
2406         * generated/sum_r4.c: Regenerated.
2407         * generated/minloc0_4_i2.c: Regenerated.
2408         * generated/spread_c10.c: Regenerated.
2409         * generated/maxloc0_8_i1.c: Regenerated.
2410         * generated/spread_r4.c: Regenerated.
2411         * generated/minloc0_8_i8.c: Regenerated.
2412         * generated/matmul_c8.c: Regenerated.
2413         * generated/all_l16.c: Regenerated.
2414         * generated/minloc1_16_r10.c: Regenerated.
2415         * generated/sum_i2.c: Regenerated.
2416         * generated/minloc0_16_i1.c: Regenerated.
2417         * generated/maxloc0_16_i1.c: Regenerated.
2418         * generated/maxloc1_8_r8.c: Regenerated.
2419         * generated/minval_i16.c: Regenerated.
2420         * generated/spread_i2.c: Regenerated.
2421         * generated/maxval_i4.c: Regenerated.
2422         * generated/minval_i8.c: Regenerated.
2423         * generated/any_l4.c: Regenerated.
2424         * generated/maxloc1_4_i8.c: Regenerated.
2425         * generated/maxloc0_16_i16.c: Regenerated.
2426         * generated/maxloc0_8_r4.c: Regenerated.
2427         * generated/minloc1_4_i16.c: Regenerated.
2428         * generated/maxloc1_4_i16.c: Regenerated.
2429         * generated/minloc0_4_r10.c: Regenerated.
2430         * generated/minloc0_8_i16.c: Regenerated.
2431         * generated/maxloc0_4_r10.c: Regenerated.
2432         * generated/maxloc0_8_i16.c: Regenerated.
2433         * generated/minloc1_8_r10.c: Regenerated.
2434         * generated/product_i4.c: Regenerated.
2435         * generated/minloc0_16_r4.c: Regenerated.
2436         * generated/sum_c16.c: Regenerated.
2437         * generated/maxloc1_8_r10.c: Regenerated.
2438         * generated/maxloc0_16_r4.c: Regenerated.
2439         * generated/minloc1_16_r8.c: Regenerated.
2440         * generated/minloc0_8_i1.c: Regenerated.
2441         * generated/maxloc0_4_i4.c: Regenerated.
2442         * generated/maxloc1_16_r8.c: Regenerated.
2443         * generated/maxloc0_8_i2.c: Regenerated.
2444         * generated/sum_r10.c: Regenerated.
2445         * generated/count_4_l.c: Regenerated.
2446         * generated/sum_c4.c: Regenerated.
2447         * generated/count_8_l.c: Regenerated.
2448         * generated/maxloc1_16_r10.c: Regenerated.
2449         * generated/matmul_i8.c: Regenerated.
2450         * generated/minloc0_16_i2.c: Regenerated.
2451         * generated/minloc1_8_r8.c: Regenerated.
2452         * generated/maxloc0_16_i2.c: Regenerated.
2453         * generated/spread_c4.c: Regenerated.
2454         * generated/matmul_c16.c: Regenerated.
2455         * generated/maxval_r10.c: Regenerated.
2456         * generated/minval_i1.c: Regenerated.
2457         * generated/maxloc1_4_i1.c: Regenerated.
2458         * generated/matmul_r10.c: Regenerated.
2459         * generated/minloc1_4_i8.c: Regenerated.
2460         * generated/minloc0_8_r4.c: Regenerated.
2461         * generated/matmul_l4.c: Regenerated.
2462         * generated/product_i16.c: Regenerated.
2463         * generated/minloc0_16_r16.c: Regenerated.
2464         * generated/all_l4.c: Regenerated.
2465         * generated/minloc0_4_i4.c: Regenerated.
2466         * generated/minloc0_8_i2.c: Regenerated.
2467         * generated/matmul_i1.c: Regenerated.
2468         * generated/minval_r4.c: Regenerated.
2469         * generated/maxloc1_4_r4.c: Regenerated.
2470         * generated/spread_i16.c: Regenerated.
2471         * generated/sum_i4.c: Regenerated.
2472         * generated/maxval_r8.c: Regenerated.
2473         * generated/spread_i4.c: Regenerated.
2474         * generated/minloc1_4_i1.c: Regenerated.
2475         * generated/minval_r16.c: Regenerated.
2476         * generated/minval_i2.c: Regenerated.
2477         * generated/maxloc1_4_i2.c: Regenerated.
2478         * generated/product_r8.c: Regenerated.
2479         * generated/maxloc1_8_i8.c: Regenerated.
2480         * generated/maxloc0_4_r8.c: Regenerated.
2481         * generated/maxloc0_16_r16.c: Regenerated.
2482         * generated/matmul_r4.c: Regenerated.
2483         * generated/sum_c10.c: Regenerated.
2484         * generated/minloc1_4_r16.c: Regenerated.
2485         * generated/maxloc1_4_r16.c: Regenerated.
2486         * generated/minloc0_8_r16.c: Regenerated.
2487         * generated/maxloc0_8_r16.c: Regenerated.
2488         * generated/count_1_l.c: Regenerated.
2489         * generated/maxloc0_8_i4.c: Regenerated.
2490         * generated/matmul_i2.c: Regenerated.
2491         * generated/minloc1_4_r4.c: Regenerated.
2492         * generated/matmul_c10.c: Regenerated.
2493         * generated/minloc0_16_i4.c: Regenerated.
2494         * generated/maxloc0_16_i4.c: Regenerated.
2495         * generated/minloc1_16_i8.c: Regenerated.
2496         * generated/maxloc1_16_i8.c: Regenerated.
2497         * generated/minloc1_4_i2.c: Regenerated.
2498         * generated/matmul_l16.c: Regenerated.
2499         * generated/maxloc1_8_i1.c: Regenerated.
2500         * generated/minloc0_16_r10.c: Regenerated.
2501         * generated/minloc1_8_i8.c: Regenerated.
2502         * generated/minloc0_4_r8.c: Regenerated.
2503         * generated/product_r16.c: Regenerated.
2504         * generated/product_c8.c: Regenerated.
2505         * generated/sum_r8.c: Regenerated.
2506         * generated/minloc0_8_i4.c: Regenerated.
2507         * generated/matmul_c4.c: Regenerated.
2508         * generated/minloc1_16_i16.c: Regenerated.
2509         * generated/spread_r8.c: Regenerated.
2510         * generated/maxloc1_8_r4.c: Regenerated.
2511         * generated/minloc1_16_i1.c: Regenerated.
2512         * generated/maxloc1_16_i1.c: Regenerated.
2513         * generated/spread_r16.c: Regenerated.
2514         * generated/minval_r10.c: Regenerated.
2515         * generated/count_16_l.c: Regenerated.
2516         * generated/minval_i4.c: Regenerated.
2517         * generated/minloc1_8_i1.c: Regenerated.
2518         * generated/maxloc1_4_i4.c: Regenerated.
2519         * generated/maxloc1_8_i2.c: Regenerated.
2520         * generated/maxval_i8.c: Regenerated.
2521         * generated/any_l8.c: Regenerated.
2522         * generated/maxloc0_16_r10.c: Regenerated.
2523         * generated/minloc0_4_i16.c: Regenerated.
2524         * generated/maxloc0_8_r8.c: Regenerated.
2525         * generated/maxloc0_4_i16.c: Regenerated.
2526         * generated/minloc1_4_r10.c: Regenerated.
2527         * generated/minloc1_8_i16.c: Regenerated.
2528         * generated/maxloc1_4_r10.c: Regenerated.
2529         * generated/maxloc1_8_i16.c: Regenerated.
2530         * generated/minloc0_8_r10.c: Regenerated.
2531         * generated/maxloc0_8_r10.c: Regenerated.
2532         * generated/minloc1_16_r4.c: Regenerated.
2533         * generated/maxloc1_16_r4.c: Regenerated.
2534         * generated/minloc0_16_r8.c: Regenerated.
2535         * generated/product_i8.c: Regenerated.
2536         * generated/maxloc0_16_r8.c: Regenerated.
2537         * generated/sum_i16.c: Regenerated.
2538         * generated/count_2_l.c: Regenerated.
2539         * generated/maxloc0_4_i8.c: Regenerated.
2540         * generated/maxloc1_16_i16.c: Regenerated.
2541         * generated/matmul_i4.c: Regenerated.
2542         * generated/minloc1_8_r4.c: Regenerated.
2543         * generated/sum_c8.c: Regenerated.
2544         * generated/minloc1_16_i2.c: Regenerated.
2545         * generated/maxloc1_16_i2.c: Regenerated.
2546         * generated/maxval_i16.c: Regenerated.
2547         * generated/spread_c8.c: Regenerated.
2548         * generated/matmul_i16.c: Regenerated.
2549         * generated/minloc1_4_i4.c: Regenerated.
2550         * generated/maxval_i1.c: Regenerated.
2551         * generated/minloc1_8_i2.c: Regenerated.
2552         * generated/any_l1.c: Regenerated.
2553         * generated/product_c16.c: Regenerated.
2554         * generated/minloc0_8_r8.c: Regenerated.
2555         * generated/matmul_l8.c: Regenerated.
2556         * generated/product_r10.c: Regenerated.
2557         * generated/product_i1.c: Regenerated.
2558         * generated/all_l8.c: Regenerated.
2559         * generated/maxloc0_4_i1.c: Regenerated.
2560         * generated/minloc0_4_i8.c: Regenerated.
2561         * generated/spread_c16.c: Regenerated.
2562         * generated/maxval_r4.c: Regenerated.
2563
2564 2008-09-01  Jerry DeLisle  <jvdelisle@gcc.gnu.org>
2565
2566         PR libfortran/37301
2567         PR libfortran/37228
2568         * io/io.h (write_real_g0): Declare new function to handle g0.d format.
2569         * io/transfer.c (formatted_transfer_scalar): Use new function.
2570         * io/format.c (parse_format_list): Enable g0.d.
2571         * io/write.c (write_a_char4): Delete unused var.
2572         (set_fnode_default): New function to set the default fnode w, d, and e
2573         factored from write_real. (write_real): Use new factored function.
2574         (write_real_g0): New function that sets d to that passed by g0.d format
2575         specifier and set format to ES.  Default values for w and e are used
2576         from the new function, set_fnode_default.
2577
2578 2008-09-01  Jerry DeLisle  <jvdelisle@gcc.gnu.org>
2579
2580         * runtime/error.c: Fix cast for printf.
2581
2582 2008-08-30  Jerry DeLisle  <jvdelisle@gcc.gnu.org>
2583
2584         PR libfortran/36895
2585         * io/write.c (namelist_write_newline): New function to correctly mark
2586         next records in both external and internal units.
2587         (nml_write_obj): Use new function.
2588         (namelist_write: Use new function.
2589
2590 2008-08-19  Tobias Burnus  <burnus@net-b.de>
2591
2592         PR libfortran/35863
2593         * io/write.c (write_a_char4): Add missing variable declaration
2594         in HAVE_CRLF block.
2595
2596 2008-08-15  Jerry DeLisle  <jvdelisle@gcc.gnu.org>
2597
2598         PR libfortran/35863
2599         * intrinsics/selected_char_kind.c: Enable iso_10646.
2600         * io/read.c (typedef uchar): New type.
2601         (read_utf8): New function to read a single UTF-8 encoded character.
2602         (read_utf8_char1): New function to read UTF-8 into a KIND=1 string.
2603         (read_default_char1): New functio to read default into KIND=1 string.
2604         (read_utf8_char4): New function to read UTF-8 into a KIND=4 string.
2605         (read_default_char4): New function to read UTF-8 into a KIND=4 string.
2606         (read_a): Modify to use the new functions.
2607         (read_a_char4): Modify to use the new functions.
2608         * io/write.c (error.h): Add include. (typedef uchar): New type.
2609         (write_default_char4): New function to default write KIND=4 string.
2610         (write_utf8_char4): New function to UTF-8 write KIND=4 string.
2611         (write_a_char4): Modify to use new functions.
2612         (write_character): Modify to use new functions.
2613
2614 2008-08-14  H.J. Lu  <hongjiu.lu@intel.com>
2615
2616         PR libfortran/37123
2617         * intrinsics/cshift0.c (cshift0): Fix 2 typos.
2618
2619 2008-08-14  Thomas Koenig  <tkoenig@gcc.gnu.org>
2620
2621         PR libfortran/36886
2622         * Makefile.am:  Added $(i_cshift0_c).
2623         Added $(i_cshift0_c) to gfor_built_specific_src.
2624         Add rule to build from cshift0.m4.
2625         * Makefile.in:  Regenerated.
2626         * libgfortran.h:  Addedd prototypes for cshift0_i1,
2627         cshift0_i2, cshift0_i4, cshift0_i8, cshift0_i16,
2628         cshift0_r4, cshift0_r8, cshift0_r10, cshift0_r16,
2629         cshift0_c4, cshift0_c8, cshift0_c10, cshift0_c16.
2630         Define Macros GFC_UNALIGNED_C4 and GFC_UNALIGNED_C8.
2631         * intrinsics/cshift0.c:  Remove helper functions for
2632         the innter shift loop.
2633         (cshift0):  Call specific functions depending on type
2634         of array argument.  Only call specific functions for
2635         correct alignment for other types.
2636         * m4/cshift0.m4:  New file.
2637         * generated/cshift0_i1.c:  New file.
2638         * generated/cshift0_i2.c:  New file.
2639         * generated/cshift0_i4.c:  New file.
2640         * generated/cshift0_i8:.c  New file.
2641         * generated/cshift0_i16.c:  New file.
2642         * generated/cshift0_r4.c:  New file.
2643         * generated/cshift0_r8.c:  New file.
2644         * generated/cshift0_r10.c:  New file.
2645         * generated/cshift0_r16.c:  New file.
2646         * generated/cshift0_c4.c:  New file.
2647         * generated/cshift0_c8.c:  New file.
2648         * generated/cshift0_c10.c:  New file.
2649         * generated/cshift0_c16.c:  New file.
2650
2651 2008-07-27  Tobias Burnus  <burnus@net-b.de>
2652
2653         PR fortran/36132
2654         PR fortran/29952
2655         PR fortran/36909
2656         * runtime/error.c: New function runtime_error_at.
2657         * gfortran.map: Ditto.
2658         * libgfortran.h: Ditto.
2659
2660 2008-07-22  Jerry DeLisle  <jvdelisle@gcc.gnu.org>
2661
2662         PR fortran/36582
2663         * io/list_read.c: If variable rank is zero, do not adjust the found
2664         namelist object pointer.
2665
2666 2008-07-22  Daniel Kraft  <d@domob.eu>
2667
2668         PR fortran/29835
2669         * io/format.c (struct format_data):  New member error_element.
2670         (unexpected_element):  Added '%c' to message.
2671         (next_char):  Keep track of last parsed character in fmt->error_element.
2672         (format_error):  If the message is unexpected_element, output the
2673         offending character, too.
2674
2675 2008-07-22  Thomas Koenig  <tkoenig@gcc.gnu.org>
2676
2677         PR libfortran/36890
2678         * io/file_pos.c:  Declare READ_CHUNK as signed to avoid
2679         signed/unsigned comparison warning in formatted_backspace.
2680
2681 2008-07-21  Thomas Koenig  <tkoenig@gcc.gnu.org>
2682
2683         PR libfortran/36773
2684         * intrinsics/cshift0.c (cshift0):  Return early if size of array
2685         is zero.
2686         * intrinsics/eoshift0.c (eoshift0):  Return early if size of
2687         return array is zero.
2688         * intrinsics/eoshift2.c (eoshift2):  Likewise.
2689         * m4/eoshift1.m4 (eoshift1):  Return early if size of array
2690         is zero.
2691         * m4/eoshift3.m4 (eoshift3):  Likewise.
2692         * m4/eoshift2.m4 (eoshift2):  Return early if size of return
2693         array is zero.
2694         * m4/eoshift4.m4 (eoshift2):  Return early if size of return
2695         array is zero.
2696         * generated/cshift1_16.c: Regenerated.
2697         * generated/cshift1_4.c: Regenerated.
2698         * generated/cshift1_8.c: Regenerated.
2699         * generated/eoshift1_16.c: Regenerated.
2700         * generated/eoshift1_4.c: Regenerated.
2701         * generated/eoshift1_8.c: Regenerated.
2702         * generated/eoshift3_16.c: Regenerated.
2703         * generated/eoshift3_4.c: Regenerated.
2704         * generated/eoshift3_8.c: Regenerated.
2705
2706 2008-07-20  Jerry DeLisle  <jvdelisle@gcc.gnu.org>
2707
2708         PR fortran/36857
2709         * io/write_float.def: Comment out locale dependent code and fix general
2710         comments.
2711         
2712 2008-07-07  Thomas Koenig  <tkoenig@gcc.gnu.org>
2713
2714         PR fortran/36341
2715         PR fortran/34670
2716         * m4/matmul.m4:  Add bounds checking.
2717         * m4/matmull.m4:  Likewise.
2718         * generated/matmul_c10.c: Regenerated.
2719         * generated/matmul_c16.c: Regenerated.
2720         * generated/matmul_c4.c: Regenerated.
2721         * generated/matmul_c8.c: Regenerated.
2722         * generated/matmul_i1.c: Regenerated.
2723         * generated/matmul_i16.c: Regenerated.
2724         * generated/matmul_i2.c: Regenerated.
2725         * generated/matmul_i4.c: Regenerated.
2726         * generated/matmul_i8.c: Regenerated.
2727         * generated/matmul_l16.c: Regenerated.
2728         * generated/matmul_l4.c: Regenerated.
2729         * generated/matmul_l8.c: Regenerated.
2730         * generated/matmul_r10.c: Regenerated.
2731         * generated/matmul_r16.c: Regenerated.
2732         * generated/matmul_r4.c: Regenerated.
2733         * generated/matmul_r8.c: Regenerated.
2734
2735 2008-07-07  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
2736
2737         * acinclude.m4 (LIBGFOR_CHECK_GTHR_DEFAULT): Fix configure cache
2738         variable name.
2739         * configure: Regenerate.
2740
2741 2008-07-01  Jerry DeLisle  <jvdelisle@gcc.gnu.org>
2742
2743         PR fortran/36676
2744         * io/list_read.c (find_nml_name): Use eat_separator instead of eat_line.
2745         
2746 2008-06-28  Jerry DeLisle  <jvdelisle@gcc.gnu.org>
2747
2748         PR fortran/36657
2749         * io/list_read.c (read_character): Check for '!' along with separators.
2750         (find_nml_name): Likewise and eat the comment if found.
2751
2752 2008-06-17  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
2753
2754         * configure: Regenerate.
2755
2756 2008-06-16  Jerry DeLisle  <jvdelisle@gcc.gnu.org>
2757
2758         PR fortran/36546
2759         * io/list_read.c (eat_separator): Add tab character to condition
2760         for looping past whitespace.
2761
2762 2008-06-14  Jerry DeLisle  <jvdelisle@gcc.gnu.org>
2763
2764         PR fortran/36515
2765         * libgfortran.h (compile_options_t): Add int range_check to structure.
2766         * runtime/compile_options.c (set_options): Add range_check option.
2767         (init_compile_options): Likewise.
2768         *io/read.c (read_decimal): Change overflow checks to include
2769         range_check.
2770         
2771 2008-06-13  Jerry DeLisle  <jvdelisle@gcc.gnu.org>
2772
2773         PR fortran/36538
2774         * io/list_read.c (namelist_read): Add eat_separator to eliminate leading
2775         tabs.
2776
2777 2008-06-13  Jerry DeLisle  <jvdelisle@gcc.gnu.org>
2778
2779         PR fortran/35863
2780         * libgfortran.h: Change l8_to_l4_offset to big_endian and add endian_off.
2781         * runtime/main.c: Fix error in comment. Change l8_to_l4_offset to
2782         big_endian. (determine_endianness): Add endian_off and set its value
2783         according to big_endian.
2784         * gfortran.map: Add symbol for new _gfortran_transfer_character_wide.
2785         * io/io.h: Add prototype declarations for new functions.
2786         * io/list_read.c (list_formatted_read_scalar): Modify to handle kind=4.
2787         (list_formatted_read): Calculate stride based on kind for character type
2788         and use it when calling list_formatted_read_scalar.
2789         * io/inquire.c (inquire_via_unit): Change l8_to_l4_offset to big_endian.
2790         * io/open.c (st_open): Change l8_to_l4_offset to big_endian.
2791         * io/read.c (read_a_char4): New function to handle formatted read.
2792         * io/write.c: Define GFC_CHAR4(x) to improve readability of code.
2793         (write_a_char4): New function to handle formatted write.
2794         (write_character): Modify to accept the kind parameter and adjust for
2795         endianess of the machine. (list_formatted_write): Calculate the stride
2796         resulting from the kind and adjust the list_formatted_write_scalar call
2797         accordingly. (nml_write_obj): Adjust calls to write_character.
2798         (namelist_write): Likewise.
2799         * io/transfer.c (formatted_transfer_scaler): Rename 'len' argument to
2800         'kind' argument to better describe what it is. Add calls to new
2801         functions for kind == 4. (formatted_transfer): Modify to handle the case
2802         of type character and kind equals 4 to pass in the kind to the transfer
2803         routines. (transfer_character_wide): Add this new function.
2804         (transfer_array): Don't set kind to the character string length. Adjust
2805         strides bases on character kind.
2806         (unformatted_read): Adjust size based on kind for character types.
2807         (unformatted_write): Likewise. (data_transfer_init): Change
2808         l8_to_l4_offset to big_endian.
2809         io/fbuf.c (fbuf_seek): Add cast to eliminate warning.
2810
2811 2008-06-13  Tobias Burnus  <burnus@net-b.de>
2812
2813         * configure.ac (AM_CFLAGS): Remove -Werror again.
2814         * configure: Regenerate.
2815
2816 2008-06-13  Tobias Burnus  <burnus@net-b.de>
2817
2818         PR libgfortran/36518
2819         * configure.ac (AM_CFLAGS): Add -Werror.
2820         * configure: Regenerate.
2821         * m4/ifunction_logical.m4: Cast "n" to "(int)".
2822         * generated/any_l16.c: Regenerate.
2823         * generated/any_l2.c: Regenerate.
2824         * generated/all_l1.c: Regenerate.
2825         * generated/all_l2.c: Regenerate.
2826         * generated/all_l16.c: Regenerate.
2827         * generated/any_l4.c: Regenerate.
2828         * generated/count_4_l.c: Regenerate.
2829         * generated/count_8_l.c: Regenerate.
2830         * generated/all_l4.c: Regenerate.
2831         * generated/count_1_l.c: Regenerate.
2832         * generated/count_16_l.c: Regenerate.
2833         * generated/any_l8.c: Regenerate.
2834         * generated/count_2_l.c: Regenerate.
2835         * generated/any_l1.c: Regenerate.
2836         * generated/all_l8.c: Regenerate.
2837
2838 2008-06-13  Tobias Burnus  <burnus@net-b.de>
2839
2840         PR fortran/36495
2841         * configure.ac (AM_FCFLAGS): Add "-Werror -fimplicit-none".
2842         * configure: (generated) ditto.
2843         * intrinsics/dprod_r8.f90: Add "implicit none".
2844
2845 2008-06-07  Jerry DeLisle  <jvdelisle@gcc.gnu.org>
2846
2847         PR libfortran/36420
2848         PR libfortran/36421
2849         PR libfortran/36422
2850         * io/io.h: Add prototype for write_real.
2851         * io/transfer.c (formatted_transfer_scalar): For FMT_G and width zero,
2852         use write_real.
2853         * io/format.c: Add zero width error message. (parse_format_list): Use
2854         error message for FMT_A if followed by FMT_ZERO. Use zero width error
2855         message for FMT_G if mode is READ or if -std=f95 or f2003. (fmormat0):
2856         Fix typo in comment.
2857         * io/write.c(write_a): Set wlen to len if FMT_G and length is zero.
2858         (write_l): Add wlen variable and use it if FMT_G and width is zero.
2859         (write_decimal): If FMT_G, set m to -1 to flag processor dependent
2860         formatting. (write_real): Remove static declaration.
2861
2862 2008-05-28  Francois-Xavier Coudert  <fxcoudert@gcc.gnu.org>
2863
2864         PR fortran/36319
2865         * intrinsics/string_intrinsics_inc.c (string_index): Return
2866         correct value for zero-length substring.
2867         * intrinsics/cshift0.c: Add _char4 variant.
2868         * intrinsics/eoshift0.c (eoshift0): Allow filler to be a pattern
2869         wider than a single byte. Add _char4 variant and use above
2870         functionality.
2871         * intrinsics/eoshift2.c (eoshift2): Likewise.
2872         * m4/eoshift1.m4: Likewise.
2873         * m4/eoshift3.m4: Likewise.
2874         * m4/cshift1.m4: Add _char4 variants.
2875         * gfortran.map (GFORTRAN_1.1): Add _gfortran_cshift0_1_char4,
2876         _gfortran_cshift0_2_char4, _gfortran_cshift0_4_char4,
2877         _gfortran_cshift0_8_char4, _gfortran_cshift1_16_char4,
2878         _gfortran_cshift1_4_char4, _gfortran_cshift1_8_char4,
2879         _gfortran_eoshift0_1_char4, _gfortran_eoshift0_2_char4,
2880         _gfortran_eoshift0_4_char4, _gfortran_eoshift0_8_char4,
2881         _gfortran_eoshift1_16_char4, _gfortran_eoshift1_4_char4,
2882         _gfortran_eoshift1_8_char4, _gfortran_eoshift2_1_char4,
2883         _gfortran_eoshift2_2_char4, _gfortran_eoshift2_4_char4,
2884         _gfortran_eoshift2_8_char4, _gfortran_eoshift3_16_char4,
2885         _gfortran_eoshift3_4_char4 and _gfortran_eoshift3_8_char4.
2886         * generated/eoshift3_4.c: Regenerate.
2887         * generated/eoshift1_8.c: Regenerate.
2888         * generated/eoshift1_16.c: Regenerate.
2889         * generated/cshift1_4.c: Regenerate.
2890         * generated/eoshift1_4.c: Regenerate.
2891         * generated/eoshift3_8.c: Regenerate.
2892         * generated/eoshift3_16.c: Regenerate.
2893         * generated/cshift1_8.c: Regenerate.
2894         * generated/cshift1_16.c: Regenerate.
2895
2896 2008-05-25  Tobias Burnus  <burnus@net-b.de>
2897
2898         PR fortran/32600
2899         * intrinsics/iso_c_binding.c (c_f_procpointer): Remove.
2900         * intrinsics/iso_c_binding.h (c_f_procpointer): Remove.
2901         * gfortran.map (c_f_procpointer): Remove.
2902
2903 2008-05-22  Thomas Koenig  <tkoenig@gcc.gnu.org>
2904
2905         PR libgfortran/36302
2906         * gfortran.map (GFORTRAN_1.1): Add _gfortran_eoshift0_16,
2907         _gfortran_eoshift0_16_char, _gfortran_eoshift2_16,
2908         _gfortran_eoshift2_16_char,_gfortran_cshift0_16,
2909         _gfortran_cshift0_16_char.  Sort alphabetically.
2910         * intrinsics/eoshift0.c:  Add function for kind=16 integer.
2911         * intrinsics/eoshift2.c:  Likewise.
2912         * intrinsics/cshift0.c:  Likewise.
2913
2914 2008-05-18  Thomas Koenig  <tkoenig@gcc.gnu.org>
2915
2916         * m4/in_pack.m4 (internal_pack_'rtype_code`):  Destination
2917         pointer is restrict.
2918         * m4/transpose.m4 (transpose_'rtype_code`):  Likewise.
2919         * m4/pack.m4 (pack_'rtype_code`):  Likewise.
2920         * m4/spread.m4 (spread_'rtype_code`):  Likewise.
2921         (spread_scalar_'rtype_code`): Likewise.
2922         * m4/iforeach.m4 (name`'rtype_qual`_'atype_code):  Likewise.
2923         * m4/eoshift1.m4 (eoshift1):  Likewise.
2924         * m4/eoshift3.m4 (eoshift3):  Likewise.
2925         * m4/in_unpack.m4 (internal_unpack_'rtype_ccode`):  Likewise.
2926         * m4/unpack.m4 (unpack0_'rtype_code`):  Likewise.
2927         (unpack1_'rtype_code`):  Likewise.
2928         * intrinsics/pack_generic.c (pack_generic.c):  Likewise.
2929         * intrinsics/unpack_generic.c (unpack_internal):  Likewise.
2930         * intrinsics/eoshift0.c (eoshift0):  Likewise.
2931         * intrinsics/eoshift2.c (eoshift2):  Likewise.
2932         * intrinsics/reshape_generic.c (reshape_internal):  Likewise.
2933         * intrinsics/reshape_packed.c (reshape_packed):  Likewise.
2934         * generated/eoshift1_16.c: Regenerated.
2935         * generated/eoshift1_4.c: Regenerated.
2936         * generated/eoshift1_8.c: Regenerated.
2937         * generated/eoshift3_16.c: Regenerated.
2938         * generated/eoshift3_4.c: Regenerated.
2939         * generated/eoshift3_8.c: Regenerated.
2940         * generated/in_pack_c10.c: Regenerated.
2941         * generated/in_pack_c16.c: Regenerated.
2942         * generated/in_pack_c4.c: Regenerated.
2943         * generated/in_pack_c8.c: Regenerated.
2944         * generated/in_pack_i1.c: Regenerated.
2945         * generated/in_pack_i16.c: Regenerated.
2946         * generated/in_pack_i2.c: Regenerated.
2947         * generated/in_pack_i4.c: Regenerated.
2948         * generated/in_pack_i8.c: Regenerated.
2949         * generated/in_pack_r10.c: Regenerated.
2950         * generated/in_pack_r16.c: Regenerated.
2951         * generated/in_pack_r4.c: Regenerated.
2952         * generated/in_pack_r8.c: Regenerated.
2953         * generated/in_unpack_c10.c: Regenerated.
2954         * generated/in_unpack_c16.c: Regenerated.
2955         * generated/in_unpack_c4.c: Regenerated.
2956         * generated/in_unpack_c8.c: Regenerated.
2957         * generated/in_unpack_i1.c: Regenerated.
2958         * generated/in_unpack_i16.c: Regenerated.
2959         * generated/in_unpack_i2.c: Regenerated.
2960         * generated/in_unpack_i4.c: Regenerated.
2961         * generated/in_unpack_i8.c: Regenerated.
2962         * generated/in_unpack_r10.c: Regenerated.
2963         * generated/in_unpack_r16.c: Regenerated.
2964         * generated/in_unpack_r4.c: Regenerated.
2965         * generated/in_unpack_r8.c: Regenerated.
2966         * generated/maxloc0_16_i1.c: Regenerated.
2967         * generated/maxloc0_16_i16.c: Regenerated.
2968         * generated/maxloc0_16_i2.c: Regenerated.
2969         * generated/maxloc0_16_i4.c: Regenerated.
2970         * generated/maxloc0_16_i8.c: Regenerated.
2971         * generated/maxloc0_16_r10.c: Regenerated.
2972         * generated/maxloc0_16_r16.c: Regenerated.
2973         * generated/maxloc0_16_r4.c: Regenerated.
2974         * generated/maxloc0_16_r8.c: Regenerated.
2975         * generated/maxloc0_4_i1.c: Regenerated.
2976         * generated/maxloc0_4_i16.c: Regenerated.
2977         * generated/maxloc0_4_i2.c: Regenerated.
2978         * generated/maxloc0_4_i4.c: Regenerated.
2979         * generated/maxloc0_4_i8.c: Regenerated.
2980         * generated/maxloc0_4_r10.c: Regenerated.
2981         * generated/maxloc0_4_r16.c: Regenerated.
2982         * generated/maxloc0_4_r4.c: Regenerated.
2983         * generated/maxloc0_4_r8.c: Regenerated.
2984         * generated/maxloc0_8_i1.c: Regenerated.
2985         * generated/maxloc0_8_i16.c: Regenerated.
2986         * generated/maxloc0_8_i2.c: Regenerated.
2987         * generated/maxloc0_8_i4.c: Regenerated.
2988         * generated/maxloc0_8_i8.c: Regenerated.
2989         * generated/maxloc0_8_r10.c: Regenerated.
2990         * generated/maxloc0_8_r16.c: Regenerated.
2991         * generated/maxloc0_8_r4.c: Regenerated.
2992         * generated/maxloc0_8_r8.c: Regenerated.
2993         * generated/minloc0_16_i1.c: Regenerated.
2994         * generated/minloc0_16_i16.c: Regenerated.
2995         * generated/minloc0_16_i2.c: Regenerated.
2996         * generated/minloc0_16_i4.c: Regenerated.
2997         * generated/minloc0_16_i8.c: Regenerated.
2998         * generated/minloc0_16_r10.c: Regenerated.
2999         * generated/minloc0_16_r16.c: Regenerated.
3000         * generated/minloc0_16_r4.c: Regenerated.
3001         * generated/minloc0_16_r8.c: Regenerated.
3002         * generated/minloc0_4_i1.c: Regenerated.
3003         * generated/minloc0_4_i16.c: Regenerated.
3004         * generated/minloc0_4_i2.c: Regenerated.
3005         * generated/minloc0_4_i4.c: Regenerated.
3006         * generated/minloc0_4_i8.c: Regenerated.
3007         * generated/minloc0_4_r10.c: Regenerated.
3008         * generated/minloc0_4_r16.c: Regenerated.
3009         * generated/minloc0_4_r4.c: Regenerated.
3010         * generated/minloc0_4_r8.c: Regenerated.
3011         * generated/minloc0_8_i1.c: Regenerated.
3012         * generated/minloc0_8_i16.c: Regenerated.
3013         * generated/minloc0_8_i2.c: Regenerated.
3014         * generated/minloc0_8_i4.c: Regenerated.
3015         * generated/minloc0_8_i8.c: Regenerated.
3016         * generated/minloc0_8_r10.c: Regenerated.
3017         * generated/minloc0_8_r16.c: Regenerated.
3018         * generated/minloc0_8_r4.c: Regenerated.
3019         * generated/minloc0_8_r8.c: Regenerated.
3020         * generated/pack_c10.c: Regenerated.
3021         * generated/pack_c16.c: Regenerated.
3022         * generated/pack_c4.c: Regenerated.
3023         * generated/pack_c8.c: Regenerated.
3024         * generated/pack_i1.c: Regenerated.
3025         * generated/pack_i16.c: Regenerated.
3026         * generated/pack_i2.c: Regenerated.
3027         * generated/pack_i4.c: Regenerated.
3028         * generated/pack_i8.c: Regenerated.
3029         * generated/pack_r10.c: Regenerated.
3030         * generated/pack_r16.c: Regenerated.
3031         * generated/pack_r4.c: Regenerated.
3032         * generated/pack_r8.c: Regenerated.
3033         * generated/spread_c10.c: Regenerated.
3034         * generated/spread_c16.c: Regenerated.
3035         * generated/spread_c4.c: Regenerated.
3036         * generated/spread_c8.c: Regenerated.
3037         * generated/spread_i1.c: Regenerated.
3038         * generated/spread_i16.c: Regenerated.
3039         * generated/spread_i2.c: Regenerated.
3040         * generated/spread_i4.c: Regenerated.
3041         * generated/spread_i8.c: Regenerated.
3042         * generated/spread_r10.c: Regenerated.
3043         * generated/spread_r16.c: Regenerated.
3044         * generated/spread_r4.c: Regenerated.
3045         * generated/spread_r8.c: Regenerated.
3046         * generated/transpose_c10.c: Regenerated.
3047         * generated/transpose_c16.c: Regenerated.
3048         * generated/transpose_c4.c: Regenerated.
3049         * generated/transpose_c8.c: Regenerated.
3050         * generated/transpose_i16.c: Regenerated.
3051         * generated/transpose_i4.c: Regenerated.
3052         * generated/transpose_i8.c: Regenerated.
3053         * generated/transpose_r10.c: Regenerated.
3054         * generated/transpose_r16.c: Regenerated.
3055         * generated/transpose_r4.c: Regenerated.
3056         * generated/transpose_r8.c: Regenerated.
3057         * generated/unpack_c10.c: Regenerated.
3058         * generated/unpack_c16.c: Regenerated.
3059         * generated/unpack_c4.c: Regenerated.
3060         * generated/unpack_c8.c: Regenerated.
3061         * generated/unpack_i1.c: Regenerated.
3062         * generated/unpack_i16.c: Regenerated.
3063         * generated/unpack_i2.c: Regenerated.
3064         * generated/unpack_i4.c: Regenerated.
3065         * generated/unpack_i8.c: Regenerated.
3066         * generated/unpack_r10.c: Regenerated.
3067         * generated/unpack_r16.c: Regenerated.
3068         * generated/unpack_r4.c: Regenerated.
3069         * generated/unpack_r8.c: Regenerated.
3070
3071 2008-05-18  Francois-Xavier Coudert  <fxcoudert@gcc.gnu.org>
3072
3073         * runtime/select.c: Moved content to select_inc.c. Include it. 
3074         Add macros for different character types.
3075         * runtime/select_inc.c: New file.
3076         * runtime/convert_char.c: New file.
3077         * intrinsics/pack_generic.c (pack_char4, pack_s_char4): New
3078         functions.
3079         * intrinsics/transpose_generic.c (transpose_char4): New function.
3080         * intrinsics/spread_generic.c (spread_char4, spread_char4_scalar):
3081         New functions.
3082         * intrinsics/unpack_generic.c (unpack1_char4, unpack0_char4): 
3083         New functions.
3084         * intrinsics/reshape_generic.c (reshape_char): Use
3085         gfc_charlen_type as type for length variables.
3086         (reshape_char4): New function.
3087         * gfortran.map (GFORTRAN_1.1): Add _gfortran_select_string_char4,
3088         _gfortran_convert_char1_to_char4, _gfortran_convert_char4_to_char1,
3089         _gfortran_transpose_char4, _gfortran_spread_char4,
3090         _gfortran_spread_char4_scalar, _gfortran_reshape_char4,
3091         _gfortran_pack_char4, _gfortran_pack_s_char4,
3092         _gfortran_unpack0_char4 and _gfortran_unpack1_char4.
3093         * Makefile.am: Add runtime/convert_char.c.
3094         * Makefile.in: Regenerate.
3095
3096 2008-05-17  Thomas Koenig  <tkoenig@gcc.gnu.org>
3097
3098         * io/list_read.c (list_formatted_read_scalar):  Declare
3099         type as volatile to shut up compiler warning.
3100
3101 2008-05-16  Janne Blomqvist  <jb@gcc.gnu.org>
3102
3103         PR libfortran/25561
3104         * io/io.h (struct fbuf): Change pointer to position offset.
3105         * io/fbuf.c (fbuf_init): Reduce default size of buffer, ptr=>pos
3106         changes.
3107         (fbuf_reset): ptr=>pos changes.
3108         (fbuf_alloc): If the request doesn't fit, don't waste memory by
3109         keeping flushed bytes. ptr=>pos changes.
3110         (fbuf_flush): ptr=>pos changes.
3111         (fbuf_seek): Don't seek past the left tab limit, don't update active
3112         byte count.
3113         * io/open.c (new_unit): If RECL has been specified, used that as
3114         initial buffer size.
3115
3116 2008-05-16  Janne Blomqvist  <jb@gcc.gnu.org>
3117
3118         PR libfortran/35632
3119         * io/open.c (new_unit): Set stream position to correct value.
3120
3121 2008-05-15  Janne Blomqvist  <jb@gcc.gnu.org>
3122
3123         PR libfortran/25561
3124         * Makefile.am: Add fbuf.c to gfor_io_src.
3125         * Makefile.in: Regenerate.
3126         * io/io.h (read_block): Remove.
3127         (struct stream): Remove alloc_r_at function pointer.
3128         (salloc_r): Remove.
3129         (salloc_r_at): Remove.
3130         (salloc_w_at): Remove.
3131         (salloc_w): Remove offset argument.
3132         (struct fbuf): New struct for format buffer.
3133         (struct gfc_unit): Add fbuf.
3134         (read_block_form): New prototype.
3135         (fbuf_init): Likewise.
3136         (fbuf_destroy): Likewise.
3137         (fbuf_reset): Likewise.
3138         (fbuf_alloc): Likewise.
3139         (fbuf_flush): Likewise.
3140         (fbuf_seek): Likewise.
3141         * io/file_pos.c (formatted_backspace): Change to use sread.
3142         (unformatted_backspace): Likewise.
3143         (st_backspace): Flush format buffer.
3144         (st_rewind): Likewise.
3145         * io/list_read.c (next_char): Likewise.
3146         (nml_query): Tidying, flush format buffer.
3147         * io/open.c (new_unit): Init format buffer.
3148         * io/read.c (read_l): Change to use read_block_form.
3149         (read_a): Likewise.
3150         (read_decimal): Likewise.
3151         (read_radix): Likewise.
3152         (read_f): Likewise.
3153         (read_x): Empty reads also for stream I/O.
3154         * io/transfer.c (read_sf): Change to use sread.
3155         (read_block): Rename to read_block_form, change prototype, use sread.
3156         (read_block_direct): Don't seek stream files.
3157         (write_block): Change to use fbuf if external file, don't seek stream
3158         files.
3159         (write_buf): Don't seek stream files.
3160         (formatted_transfer_scalar): Use fbuf for external files.
3161         (us_read): Change to use sread.
3162         (pre_position): Do nothing for stream I/O.
3163         (data_transfer_init): Flush fbuf when switching from write to read, if
3164         POS is specified, seek stream file to correct offset.
3165         (skip_record): Change to use sread.
3166         (min_off): New function.
3167         (next_record_r): Change to use sread.
3168         (next_record_w): Change to use sset/sseek, flush fbuf.
3169         (finalize_transfer): Flush fbuf.
3170         * io/unit.c (init_units): Init fbuf for stdout, stderr.
3171         (close_unit_1): Destroy fbuf.
3172         (finish_last_advance_record): Flush fbuf, no need to seek.
3173         * io/unix.c (fd_alloc_r_at): Remove unused where argument.
3174         (fd_alloc_w_at): Likewise.
3175         (fd_read): Remove third argument to fd_alloc_r_at.
3176         (fd_write): Remove third argument to fd_alloc_w_at.
3177         (fd_sset): Likewise.
3178         (fd_open): Don't set alloc_r_at.
3179         (mem_alloc_r_at): Remove unused where argument.
3180         (mem_alloc_w_at): Likewise.
3181         (mem_read): Don't incorrectly return previous errno, remove unused
3182         third argument to alloc function.
3183         (mem_write): Likewise.
3184         (mem_set): Likewise.
3185         (open_internal): Don't set alloc_r_at pointer.
3186         * io/fbuf.c: New file.
3187
3188 2008-05-14  Francois-Xavier Coudert  <fxcoudert@gcc.gnu.org>
3189
3190         * libgfortran.h (gfc_char4_t): New type.
3191         (GFC_SIZE_OF_CHAR_KIND): New macro.
3192         (compare_string): Adjust prototype.
3193         (compare_string_char4): New prototype.
3194         * gfortran.map (GFORTRAN_1.1): Add _gfortran_adjustl_char4,
3195         _gfortran_adjustr_char4, _gfortran_compare_string_char4,
3196         _gfortran_concat_string_char4, _gfortran_string_index_char4,
3197         _gfortran_string_len_trim_char4, _gfortran_string_minmax_char4,
3198         _gfortran_string_scan_char4, _gfortran_string_trim_char4 and
3199         _gfortran_string_verify_char4.
3200         * intrinsics/string_intrinsics_inc.c: New file from content of
3201         string_intrinsics.c with types replaced by macros.
3202         * intrinsics/string_intrinsics.c: Move content to
3203         string_intrinsics_inc.c.
3204
3205 2008-05-11  Jerry DeLisle  <jvdelisle@gcc.gnu.org>
3206
3207         PR libfortran/36202
3208         * io/list_read (eat_separator): Handle the CR-LF case correctly.
3209
3210 2008-05-09  Julian Brown  <julian@codesourcery.com>
3211
3212         * Makefile.am (LTLDFLAGS): New.
3213         (libgfortran_la_LDFLAGS): Use above.
3214         * Makefile.in: Regenerate.
3215
3216 2008-05-05  Jerry DeLisle  <jvdelisle@gcc.gnu.org>
3217
3218         PR libfortran/36131
3219         * io/transfer.c (formatted_transfer_scalar): Revert patch for PR34974.
3220         (next_record_w): Likewise.
3221
3222 2008-05-04  Thomas Koenig  <tkoenig@gcc.gnu.org>
3223
3224         PR libfortran/35995
3225         * m4/ifunction_logical.m4:  If the extent of "array"
3226         is less than zero, set it to zero.  Use an explicit
3227         flag for breaking out of the main loop to avoid, because
3228         the data pointer for "array" may be NULL for an empty
3229         array.
3230         * m4/ifunction.m4:  Likewise.
3231         * generated/all_l1.c: Regenerated.
3232         * generated/all_l16.c: Regenerated.
3233         * generated/all_l2.c: Regenerated.
3234         * generated/all_l4.c: Regenerated.
3235         * generated/all_l8.c: Regenerated.
3236         * generated/any_l1.c: Regenerated.
3237         * generated/any_l16.c: Regenerated.
3238         * generated/any_l2.c: Regenerated.
3239         * generated/any_l4.c: Regenerated.
3240         * generated/any_l8.c: Regenerated.
3241         * generated/count_16_l.c: Regenerated.
3242         * generated/count_1_l.c: Regenerated.
3243         * generated/count_2_l.c: Regenerated.
3244         * generated/count_4_l.c: Regenerated.
3245         * generated/count_8_l.c: Regenerated.
3246         * generated/maxloc1_16_i1.c: Regenerated.
3247         * generated/maxloc1_16_i16.c: Regenerated.
3248         * generated/maxloc1_16_i2.c: Regenerated.
3249         * generated/maxloc1_16_i4.c: Regenerated.
3250         * generated/maxloc1_16_i8.c: Regenerated.
3251         * generated/maxloc1_16_r10.c: Regenerated.
3252         * generated/maxloc1_16_r16.c: Regenerated.
3253         * generated/maxloc1_16_r4.c: Regenerated.
3254         * generated/maxloc1_16_r8.c: Regenerated.
3255         * generated/maxloc1_4_i1.c: Regenerated.
3256         * generated/maxloc1_4_i16.c: Regenerated.
3257         * generated/maxloc1_4_i2.c: Regenerated.
3258         * generated/maxloc1_4_i4.c: Regenerated.
3259         * generated/maxloc1_4_i8.c: Regenerated.
3260         * generated/maxloc1_4_r10.c: Regenerated.
3261         * generated/maxloc1_4_r16.c: Regenerated.
3262         * generated/maxloc1_4_r4.c: Regenerated.
3263         * generated/maxloc1_4_r8.c: Regenerated.
3264         * generated/maxloc1_8_i1.c: Regenerated.
3265         * generated/maxloc1_8_i16.c: Regenerated.
3266         * generated/maxloc1_8_i2.c: Regenerated.
3267         * generated/maxloc1_8_i4.c: Regenerated.
3268         * generated/maxloc1_8_i8.c: Regenerated.
3269         * generated/maxloc1_8_r10.c: Regenerated.
3270         * generated/maxloc1_8_r16.c: Regenerated.
3271         * generated/maxloc1_8_r4.c: Regenerated.
3272         * generated/maxloc1_8_r8.c: Regenerated.
3273         * generated/maxval_i1.c: Regenerated.
3274         * generated/maxval_i16.c: Regenerated.
3275         * generated/maxval_i2.c: Regenerated.
3276         * generated/maxval_i4.c: Regenerated.
3277         * generated/maxval_i8.c: Regenerated.
3278         * generated/maxval_r10.c: Regenerated.
3279         * generated/maxval_r16.c: Regenerated.
3280         * generated/maxval_r4.c: Regenerated.
3281         * generated/maxval_r8.c: Regenerated.
3282         * generated/minloc1_16_i1.c: Regenerated.
3283         * generated/minloc1_16_i16.c: Regenerated.
3284         * generated/minloc1_16_i2.c: Regenerated.
3285         * generated/minloc1_16_i4.c: Regenerated.
3286         * generated/minloc1_16_i8.c: Regenerated.
3287         * generated/minloc1_16_r10.c: Regenerated.
3288         * generated/minloc1_16_r16.c: Regenerated.
3289         * generated/minloc1_16_r4.c: Regenerated.
3290         * generated/minloc1_16_r8.c: Regenerated.
3291         * generated/minloc1_4_i1.c: Regenerated.
3292         * generated/minloc1_4_i16.c: Regenerated.
3293         * generated/minloc1_4_i2.c: Regenerated.
3294         * generated/minloc1_4_i4.c: Regenerated.
3295         * generated/minloc1_4_i8.c: Regenerated.
3296         * generated/minloc1_4_r10.c: Regenerated.
3297         * generated/minloc1_4_r16.c: Regenerated.
3298         * generated/minloc1_4_r4.c: Regenerated.
3299         * generated/minloc1_4_r8.c: Regenerated.
3300         * generated/minloc1_8_i1.c: Regenerated.
3301         * generated/minloc1_8_i16.c: Regenerated.
3302         * generated/minloc1_8_i2.c: Regenerated.
3303         * generated/minloc1_8_i4.c: Regenerated.
3304         * generated/minloc1_8_i8.c: Regenerated.
3305         * generated/minloc1_8_r10.c: Regenerated.
3306         * generated/minloc1_8_r16.c: Regenerated.
3307         * generated/minloc1_8_r4.c: Regenerated.
3308         * generated/minloc1_8_r8.c: Regenerated.
3309         * generated/minval_i1.c: Regenerated.
3310         * generated/minval_i16.c: Regenerated.
3311         * generated/minval_i2.c: Regenerated.
3312         * generated/minval_i4.c: Regenerated.
3313         * generated/minval_i8.c: Regenerated.
3314         * generated/minval_r10.c: Regenerated.
3315         * generated/minval_r16.c: Regenerated.
3316         * generated/minval_r4.c: Regenerated.
3317         * generated/minval_r8.c: Regenerated.
3318         * generated/product_c10.c: Regenerated.
3319         * generated/product_c16.c: Regenerated.
3320         * generated/product_c4.c: Regenerated.
3321         * generated/product_c8.c: Regenerated.
3322         * generated/product_i1.c: Regenerated.
3323         * generated/product_i16.c: Regenerated.
3324         * generated/product_i2.c: Regenerated.
3325         * generated/product_i4.c: Regenerated.
3326         * generated/product_i8.c: Regenerated.
3327         * generated/product_r10.c: Regenerated.
3328         * generated/product_r16.c: Regenerated.
3329         * generated/product_r4.c: Regenerated.
3330         * generated/product_r8.c: Regenerated.
3331         * generated/sum_c10.c: Regenerated.
3332         * generated/sum_c16.c: Regenerated.
3333         * generated/sum_c4.c: Regenerated.
3334         * generated/sum_c8.c: Regenerated.
3335         * generated/sum_i1.c: Regenerated.
3336         * generated/sum_i16.c: Regenerated.
3337         * generated/sum_i2.c: Regenerated.
3338         * generated/sum_i4.c: Regenerated.
3339         * generated/sum_i8.c: Regenerated.
3340         * generated/sum_r10.c: Regenerated.
3341         * generated/sum_r16.c: Regenerated.
3342         * generated/sum_r4.c: Regenerated.
3343         * generated/sum_r8.c: Regenerated.
3344
3345 2008-05-04  Thomas Koenig  <tkoenig@gcc.gnu.org>
3346
3347         PR libfortran/35990
3348         * intrinsics/pack_generic.c:  Really commit.
3349
3350 2008-05-04  Thomas Koenig  <tkoenig@gcc.gnu.org>
3351
3352         PR libfortran/35990
3353         * intrinsics/pack_generic.c:  If an extent of the source
3354         array is less then zero, set it to zero.  Set the source
3355         pointer to NULL if the source size is zero.  Set the total
3356         number of elements to zero if the vector has an extent
3357         less or equal to zero.
3358         * m4/pack.m4:  Set the source pointer to NULL if the
3359         source array is zero-sized.  Set the total number of
3360         elemements to zero if the vector has an extent less or
3361         equal to zero.
3362         * generated/pack_i1.c:  Regenerated.
3363         * generated/pack_i2.c:  Regenerated.
3364         * generated/pack_i4.c:  Regenerated.
3365         * generated/pack_i8.c:  Regenerated.
3366         * generated/pack_i16.c:  Regenerated.
3367         * generated/pack_r4.c:  Regenerated.
3368         * generated/pack_r8.c:  Regenerated.
3369         * generated/pack_r10.c:  Regenerated.
3370         * generated/pack_r16.c:  Regenerated.
3371         * generated/pack_c4.c:  Regenerated.
3372         * generated/pack_c8.c:  Regenerated.
3373         * generated/pack_c10.c:  Regenerated.
3374         * generated/pack_c16.c:  Regenerated.
3375
3376 2008-05-01  Jerry DeLisle  <jvdelisle@gcc.gnu.org>
3377
3378         PR libfortran/36094
3379         * runtime/error.c (show_locus): Provide modified error message when
3380         filename has not yet been associated with a unit number.
3381         * io/open.c (encoding_opt[]): Comment out "utf-8" option and add TODO.
3382
3383 2008-04-30  Francois-Xavier Coudert  <fxcoudert@gcc.gnu.org>
3384
3385         * intrinsics/selected_char_kind.c: New file.
3386         * gfortran.map (GFORTRAN_1.1): Add _gfortran_selected_char_kind.
3387         * Makefile.am: Add intrinsics/selected_char_kind.c.
3388         * Makefile.in: Regenerate.
3389
3390 2008-04-30  Thomas Koenig  <tkoenig@gcc.gnu.org>
3391
3392         PR libfortran/35993
3393         * ifunction.m4 (SCALAR_ARRAY_FUNCTION):  Use correct
3394         implementation for multi-dimensional return arrays when
3395         the mask is .false.
3396         * generated/maxloc1_16_i1.c: Regenerated.
3397         * generated/maxloc1_16_i16.c: Regenerated.
3398         * generated/maxloc1_16_i2.c: Regenerated.
3399         * generated/maxloc1_16_i4.c: Regenerated.
3400         * generated/maxloc1_16_i8.c: Regenerated.
3401         * generated/maxloc1_16_r10.c: Regenerated.
3402         * generated/maxloc1_16_r16.c: Regenerated.
3403         * generated/maxloc1_16_r4.c: Regenerated.
3404         * generated/maxloc1_16_r8.c: Regenerated.
3405         * generated/maxloc1_4_i1.c: Regenerated.
3406         * generated/maxloc1_4_i16.c: Regenerated.
3407         * generated/maxloc1_4_i2.c: Regenerated.
3408         * generated/maxloc1_4_i4.c: Regenerated.
3409         * generated/maxloc1_4_i8.c: Regenerated.
3410         * generated/maxloc1_4_r10.c: Regenerated.
3411         * generated/maxloc1_4_r16.c: Regenerated.
3412         * generated/maxloc1_4_r4.c: Regenerated.
3413         * generated/maxloc1_4_r8.c: Regenerated.
3414         * generated/maxloc1_8_i1.c: Regenerated.
3415         * generated/maxloc1_8_i16.c: Regenerated.
3416         * generated/maxloc1_8_i2.c: Regenerated.
3417         * generated/maxloc1_8_i4.c: Regenerated.
3418         * generated/maxloc1_8_i8.c: Regenerated.
3419         * generated/maxloc1_8_r10.c: Regenerated.
3420         * generated/maxloc1_8_r16.c: Regenerated.
3421         * generated/maxloc1_8_r4.c: Regenerated.
3422         * generated/maxloc1_8_r8.c: Regenerated.
3423         * generated/maxval_i1.c: Regenerated.
3424         * generated/maxval_i16.c: Regenerated.
3425         * generated/maxval_i2.c: Regenerated.
3426         * generated/maxval_i4.c: Regenerated.
3427         * generated/maxval_i8.c: Regenerated.
3428         * generated/maxval_r10.c: Regenerated.
3429         * generated/maxval_r16.c: Regenerated.
3430         * generated/maxval_r4.c: Regenerated.
3431         * generated/maxval_r8.c: Regenerated.
3432         * generated/minloc1_16_i1.c: Regenerated.
3433         * generated/minloc1_16_i16.c: Regenerated.
3434         * generated/minloc1_16_i2.c: Regenerated.
3435         * generated/minloc1_16_i4.c: Regenerated.
3436         * generated/minloc1_16_i8.c: Regenerated.
3437         * generated/minloc1_16_r10.c: Regenerated.
3438         * generated/minloc1_16_r16.c: Regenerated.
3439         * generated/minloc1_16_r4.c: Regenerated.
3440         * generated/minloc1_16_r8.c: Regenerated.
3441         * generated/minloc1_4_i1.c: Regenerated.
3442         * generated/minloc1_4_i16.c: Regenerated.
3443         * generated/minloc1_4_i2.c: Regenerated.
3444         * generated/minloc1_4_i4.c: Regenerated.
3445         * generated/minloc1_4_i8.c: Regenerated.
3446         * generated/minloc1_4_r10.c: Regenerated.
3447         * generated/minloc1_4_r16.c: Regenerated.
3448         * generated/minloc1_4_r4.c: Regenerated.
3449         * generated/minloc1_4_r8.c: Regenerated.
3450         * generated/minloc1_8_i1.c: Regenerated.
3451         * generated/minloc1_8_i16.c: Regenerated.
3452         * generated/minloc1_8_i2.c: Regenerated.
3453         * generated/minloc1_8_i4.c: Regenerated.
3454         * generated/minloc1_8_i8.c: Regenerated.
3455         * generated/minloc1_8_r10.c: Regenerated.
3456         * generated/minloc1_8_r16.c: Regenerated.
3457         * generated/minloc1_8_r4.c: Regenerated.
3458         * generated/minloc1_8_r8.c: Regenerated.
3459         * generated/minval_i1.c: Regenerated.
3460         * generated/minval_i16.c: Regenerated.
3461         * generated/minval_i2.c: Regenerated.
3462         * generated/minval_i4.c: Regenerated.
3463         * generated/minval_i8.c: Regenerated.
3464         * generated/minval_r10.c: Regenerated.
3465         * generated/minval_r16.c: Regenerated.
3466         * generated/minval_r4.c: Regenerated.
3467         * generated/minval_r8.c: Regenerated.
3468         * generated/product_c10.c: Regenerated.
3469         * generated/product_c16.c: Regenerated.
3470         * generated/product_c4.c: Regenerated.
3471         * generated/product_c8.c: Regenerated.
3472         * generated/product_i1.c: Regenerated.
3473         * generated/product_i16.c: Regenerated.
3474         * generated/product_i2.c: Regenerated.
3475         * generated/product_i4.c: Regenerated.
3476         * generated/product_i8.c: Regenerated.
3477         * generated/product_r10.c: Regenerated.
3478         * generated/product_r16.c: Regenerated.
3479         * generated/product_r4.c: Regenerated.
3480         * generated/product_r8.c: Regenerated.
3481         * generated/sum_c10.c: Regenerated.
3482         * generated/sum_c16.c: Regenerated.
3483         * generated/sum_c4.c: Regenerated.
3484         * generated/sum_c8.c: Regenerated.
3485         * generated/sum_i1.c: Regenerated.
3486         * generated/sum_i16.c: Regenerated.
3487         * generated/sum_i2.c: Regenerated.
3488         * generated/sum_i4.c: Regenerated.
3489         * generated/sum_i8.c: Regenerated.
3490         * generated/sum_r10.c: Regenerated.
3491         * generated/sum_r16.c: Regenerated.
3492         * generated/sum_r4.c: Regenerated.
3493         * generated/sum_r8.c: Regenerated.
3494
3495 2008-04-25  Thomas Koenig  <tkoenig@gcc.gnu.org>
3496
3497         PR libfortran/35960
3498         * m4/reshape.m4:  Fix typo in last commit.
3499         * generated/reshape_i4.c:  Regererated.
3500         * generated/reshape_i8.c:  Regenerated.
3501         * generated/reshape_i16.c:  Regenerated.
3502         * generated/reshape_r4.c:  Regenerated.
3503         * generated/reshape_r8.c:  Regenerated.
3504         * generated/reshape_r10.c:  Regenerated.
3505         * generated/reshape_r16.c:  Regenerated.
3506         * generated/reshape_c4.c:  Regenerated.
3507         * generated/reshape_c8.c:  Regenerated.
3508         * generated/reshape_c10.c:  Regenerated.
3509         * generated/reshape_c16.c:  Regenerated.
3510
3511 2008-04-24  Francois-Xavier Coudert  <fxcoudert@gcc.gnu.org>
3512
3513         * intrinsics/time_1.h (__time_1): Remove unused variable.
3514
3515 2008-04-23  Thomas Koenig  <tkoenig@gcc.gnu.org>
3516
3517         PR libfortran/35988
3518         * m4/matmul.m4:  Only issue a runtime error if extents are
3519         non-zero.
3520         * generated/matmul_i1.c:  Regenerated.
3521         * generated/matmul_i2.c:  Regenerated.
3522         * generated/matmul_i4.c:  Regenerated.
3523         * generated/matmul_i8.c:  Regenerated.
3524         * generated/matmul_i16.c:  Regenerated.
3525         * generated/matmul_r4.c:  Regenerated.
3526         * generated/matmul_r8.c:  Regenerated.
3527         * generated/matmul_r10.c:  Regenerated.
3528         * generated/matmul_r16.c:  Regenerated.
3529         * generated/matmul_c4.c:  Regenerated.
3530         * generated/matmul_c8.c:  Regenerated.
3531         * generated/matmul_c10.c:  Regenerated.
3532         * generated/matmul_c16.c:  Regenerated.
3533
3534 2008-04-21  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
3535
3536         * acinclude.m4 (LIBGFOR_CHECK_ATTRIBUTE_VISIBILITY)
3537         (LIBGFOR_CHECK_ATTRIBUTE_DLLEXPORT)
3538         (LIBGFOR_CHECK_ATTRIBUTE_ALIAS, LIBGFOR_CHECK_SYNC_FETCH_AND_ADD)
3539         (LIBGFOR_GTHREAD_WEAK, LIBGFOR_CHECK_UNLINK_OPEN_FILE)
3540         (LIBGFOR_CHECK_CRLF, LIBGFOR_CHECK_FOR_BROKEN_ISFINITE)
3541         (LIBGFOR_CHECK_FOR_BROKEN_ISNAN)
3542         (LIBGFOR_CHECK_FOR_BROKEN_FPCLASSIFY, LIBGFOR_CHECK_WORKING_STAT)
3543         (LIBGFOR_CHECK_FPSETMASK, LIBGFOR_CHECK_MINGW_SNPRINTF):
3544         Fix cache variable names.
3545         * configure, Makefile.in: Regenerate.
3546
3547 2008-04-20  Jerry DeLisle  <jvdelisle@gcc.gnu.org>
3548
3549         PR fortran/35991
3550         * intrinsics/cshift0.c (cshift0): Avoid divide by zero.
3551
3552 2008-04-20  Thomas Koenig  <tkoenig@gcc.gnu.org>
3553
3554         PR libfortran/35960
3555         * intrinsics/reshape_generic.c (reshape_internal): If the size
3556         of the resized array is zero, as determined by the SHAPE
3557         argument, return early.
3558         * m4/reshape.m4:  Likewise.
3559         * generated/reshape_i4.c:  Regererated.
3560         * generated/reshape_i8.c:  Regenerated.
3561         * generated/reshape_i16.c:  Regenerated.
3562         * generated/reshape_r4.c:  Regenerated.
3563         * generated/reshape_r8.c:  Regenerated.
3564         * generated/reshape_r10.c:  Regenerated.
3565         * generated/reshape_r16.c:  Regenerated.
3566         * generated/reshape_c4.c:  Regenerated.
3567         * generated/reshape_c8.c:  Regenerated.
3568         * generated/reshape_c10.c:  Regenerated.
3569         * generated/reshape_c16.c:  Regenerated.
3570
3571 2008-04-18  Paolo Bonzini  <bonzini@gnu.org>
3572
3573         PR bootstrap/35457
3574         * aclocal.m4: Regenerate.
3575         * configure: Regenerate.
3576
3577 2008-04-14  Thomas Koenig  <tkoenig@gcc.gnu.org>
3578
3579         PR libfortran/32972
3580         * intrinsics/spread_generic.c (spread):  Use spread_i2()
3581         for GFC_DTYPE_DERIVED_2 (fix typo from previous commit).
3582
3583 2008-04-13  Thomas Koenig  <tkoenig@gcc.gnu.org>
3584         Francois-Xavier Coudert  <fxcoudert@gcc.gnu.org>
3585
3586         PR libfortran/32972
3587         PR libfortran/32512
3588         configure.ac:  Add test for uintptr_t.
3589         configure:  Regenerated.
3590         config.h.in:  Regenerated.
3591         * libgfortran.h: GFC_DTYPE_DERIVED_1:  New macro.
3592         GFC_DTYPE_DERIVED_2:  New macro.
3593         GFC_DTYPE_DERIVED_4:  New macro.
3594         GFC_DTYPE_DERIVED_8:  New macro.
3595         GFC_DTYPE_DERIVED_16:  New macro.
3596         GFC_UNALIGNED_2:  New macro.
3597         GFC_UNALIGNED_4:  New macro.
3598         GFC_UNALIGNED_8:  New macro.
3599         GFC_UNALIGNED_16:  New macro.
3600         intptr_t:  Define if we don't have it.
3601         uintptr_t:  Likewise.
3602         * runtime/backtrace.c (show_backtrace):  Use intptr_t.
3603         * intrinsics/signal.c (signal_sub):  Likewise.
3604         (signal_sub_int):  Likewise.
3605         (alarm_sub_int_i4):  Likewise.
3606         * intrinsics/spread_generic.c (spread):  Use the integer
3607         routines for handling derived types of sizes 1, 2, 4, 8 and 16
3608         if the alignment of all pointers is correct.
3609         (spread_scalar):  Likewise.
3610         * intrinsics/pack_generic.c (pack):  Likewise.
3611         Use GFD_DTYPE_TYPE_SIZE to avoid nested switch statements.
3612         * intrinsics/unpack_generic.c (unpack1):  Likewise.
3613         (unpack0):  Likewise.
3614         * runtime/in_pack_generic.c (internal_pack):  Likewise.
3615         * runtime/in_unpack_generic.c (internal_unpack):  Likewise.
3616
3617 2008-04-09  Jakub Jelinek  <jakub@redhat.com>
3618
3619         * io/list_read.c (snprintf): Define if HAVE_SNPRINTF isn't defined.
3620         (nml_read_obj): Add nml_err_msg_size argument.  Pass it down to
3621         recursive call.  Use snprintf instead of sprintf when %s nl->var_name
3622         is used.
3623         (nml_get_obj_data): Add nml_err_msg_size argument.  Pass it down to
3624         nml_read_obj call.  Use snprintf instead of sprintf when %s
3625         nl->var_name is used.  Pass nml_err_msg to nml_parse_qualifier instead
3626         of parse_err_msg array.  Append " for namelist variable " and
3627         nl->var_name to it.
3628         (namelist_read): Increase size of nml_err_msg array to 200.  Pass
3629         sizeof nml_err_msg as extra argument to nml_get_obj_data.
3630
3631 2008-04-07  Jerry DeLisle  <jvdelisle@gcc.gnu.org>
3632
3633         PR fortran/25829 28655
3634         * io/open.c (edit_modes): Set flags.async. (new_unit) Set flags.async
3635         and flags.status. (st_open): Initialize flags.async.
3636         * io/list_read.c (read_charactor): Use delim_status instead of
3637         flags.delim.
3638         * io/read.c (read_x): Use pad_status instead of flags.pad.
3639         * io/inquire.c (inquire_via_unit): Add new checks.
3640         (inquire_via_filename): Likewise.
3641         * io/io.h (st_parameter_inquire): Add new flags.
3642         (st_parameter_dt): Likewise.
3643         * io/unit.c (get_internal_unit): Set flags.async. (init_units): Set
3644         flags.async.
3645         * io/transfer.c: Add delim and pad option arrays. (read_sf): Use
3646         pad_status instead of flags.pad. (read_block): Likewise.
3647         (data_transfer_init): Set flags.async and add checks.
3648         * io/write.c (write_character): Use delim_status.
3649         (list_formatted_write_scalar): Likewise. (nml_write_obj): Likewise.
3650         (namelist_write): Likewise.
3651
3652 2008-04-05  Jerry DeLisle  <jvdelisle@gcc.gnu.org>
3653
3654         PR fortran/25829 28655
3655         * gfortran.map: Add new symbol, _gfortran_st_wait.
3656         * libgfortran.h (st_paramter_common): Add new I/O parameters.
3657         * open.c (st_option decimal_opt[], st_option encoding_opt[],
3658         st_option round_opt[], st_option sign_opt[], st_option async_opt[]): New
3659         parameter option arrays. (edit_modes): Add checks for new parameters.
3660         (new_unit): Likewise. (st_open): Likewise.
3661         * list_read.c (CASE_SEPERATORS): Add ';' as a valid separator.
3662         (eat_separator): Handle deimal comma. (read_logical): Fix whitespace.
3663         (parse_real): Handle decimal comma. (read_real): Handle decimal comma.
3664         * read.c (read_a): Use decimal status flag to allow comma in place of a
3665         decimal point. (read_f): Allow comma as acceptable character in float.
3666         According to decimal flag, substitute a period for a comma.
3667         (read_x): If decimal status flag is comma, disable the read_comma flag,
3668         not allowing comma as a delimiter, an extension otherwise.
3669         * io.h: (unit_decimal, unit_encoding, unit_round, unit_sign,
3670         unit_async): New enumerators. Add all new I/O parameters.
3671         * unix.c (unix_stream, int_stream): Add io_mode asychronous I/O control.
3672         (move_pos_offset, fd_alloc_w_at): Fix some whitespace.
3673         (fd_sfree): Use new enumerator. (fd_read): Likewise.
3674         (fd_write): Likewise. (fd_close): Fix whitespace.
3675         (fd_open): Use new enumertors. (tempfile, regular_file,
3676         open_external): Fix whitespace. (output_stream, error_stream): Set
3677         method. (stream_offset): Fix whitespace.
3678         * transfer.c: (st_option decimal_opt[], sign_opt[], blank_opt[]): New
3679         option arrays.  (formatted_transfer_scalar): Set sf_read_comma flag
3680         based on new decimal_status flag. (data_transfer_init): Initialize new
3681         parameters. Add checks for decimal, sign, and blank. (st_wait): New stub.
3682         * format.c: (format_lex): Add format specifiers DP, DC, and D.
3683         (parse_format_list): Parse the new specifiers.
3684         * write.c (write_decimal): Use new sign enumerators to set the sign.
3685         (write_complex): Handle decimal comma and semi-colon separator.
3686         (nml_write_obj): Likewise.
3687         * write_float.def: Revise sign enumerators. (calculate_sign): Use new
3688         sign enumerators. (output_float): Likewise. Use new decimal_status flag
3689         to set the decimal character to a point or a comma.
3690         
3691 2008-03-28  Thomas Koenig  <tkoenig@gcc.gnu.org>
3692
3693         PR libfortran/32972
3694         PR libfortran/32512
3695         * Makefile.am:  Add new variable, i_spread_c, containing
3696         pack_i1.c, pack_i2.c, pack_i4.c, pack_i8.c, spread_i16.c,
3697         spread_r4.c, spread_r8.c, spread_r10.c, spread_r16.c,
3698         spread_c4.c, spread_c8.c, spread_c10.c, spread_c16.c.
3699         * Makefile.in:  Regenerated.
3700         * libgfortran.h:  Add prototypes for spread_i1, spread_i2,
3701         spread_i4, spread_i8, spread_i16, spread_r4, spread_r8,
3702         spread_c4, spread_c8, spread_c10, spread_c16,
3703         spread_scalar_i1, spread_scalar_i2, spread_scalar_i4,
3704         spread_scalar_i8, spread_scalar_i16, spread_scalar_r4
3705         spread_scalar_r8, spread_scalar_c4, spread_scalar_c8,
3706         spread_scalar_c10 and spread_scalar_c16.
3707         Add macros to isolate both type and size information
3708         from array descriptors with a single mask operation.
3709         * intrinsics/spread_generic.c:  Add calls to specific
3710         spread functions.
3711         * m4/spread.m4:  New file.
3712         * generated/spread_i1.c:  New file.
3713         * generated/spread_i2.c:  New file.
3714         * generated/spread_i4.c:  New file.
3715         * generated/spread_i8.c:  New file.
3716         * generated/spread_i16.c:  New file.
3717         * generated/spread_r4.c:  New file.
3718         * generated/spread_r8.c:  New file.
3719         * generated/spread_r10.c:  New file.
3720         * generated/spread_r16.c:  New file.
3721         * generated/spread_c4.c:  New file.
3722         * generated/spread_c8.c:  New file.
3723         * generated/spread_c10.c:  New file.
3724         * generated/spread_c16.c:  New file.
3725
3726 2008-03-28  Jerry DeLisle  <jvdelisle@gcc.gnu.org>
3727
3728         PR libfortran/35699
3729         * io/transfer.c (write_buf):  Don't pad the record, just return if the
3730         data is NULL.  (next_record_w): If there are bytes left in the record
3731         for unformatted direct I/O, pad out the record with zero bytes.
3732
3733 2008-03-28  Tobias Burnus  <burnus@net-b.de>
3734
3735         PR fortran/35721
3736         * intrinsics/associated.c (associated): Ignore different
3737         stride of pointer vs. target if only one element is referred.
3738
3739 2008-03-26  Jerry DeLisle  <jvdelisle@gcc.gnu.org>
3740
3741         * io/unix.c (fd_close):  Do not close STDIN.
3742
3743 2007-03-23  Thomas Koenig  <tkoenig@gcc.gnu.org
3744
3745         PR libfortran/32972
3746         * Makefile.am:  Add new variable, i_unpack_c, containing
3747         unpack_i1.c, unpack_i2.c, unpack_i4.c, unpack_i8.c,
3748         unpack_i16.c, unpack_r4.c, unpack_r8.c, unpack_r10.c,
3749         unpack_r16.c, unpack_c4.c, unpack_c8.c, unpack_c10.c
3750         and unpack_c16.c
3751         Add i_unpack_c to gfor_built_src.
3752         Add rule to generate i_unpack_c from m4/unpack.m4.
3753         * Makefile.in:  Regenerated.
3754         * libgfortran.h: Add prototypes for unpack0_i1, unpack0_i2,
3755         unpack0_i4, unpack0_i8, unpack0_i16, unpack0_r4, unpack0_r8,
3756         unpack0_r10, unpack0_r16, unpack0_c4, unpack0_c8, unpack0_c10,
3757         unpack0_c16, unpack1_i1, unpack1_i2, unpack1_i4, unpack1_i8,
3758         unpack1_i16, unpack1_r4, unpack1_r8, unpack1_r10, unpack1_r16,
3759         unpack1_c4, unpack1_c8, unpack1_c10 and unpack1_c16.
3760         * intrinsics/pack_generic.c (unpack1):  Add calls to specific
3761         unpack1 functions.
3762         (unpack0):  Add calls to specific unpack0 functions.
3763         * m4/unpack.m4:  New file.
3764         * generated/unpack_i1.c:  New file.
3765         * generated/unpack_i2.c:  New file.
3766         * generated/unpack_i4.c:  New file.
3767         * generated/unpack_i8.c:  New file.
3768         * generated/unpack_i16.c:  New file.
3769         * generated/unpack_r4.c:  New file.
3770         * generated/unpack_r8.c:  New file.
3771         * generated/unpack_r10.c:  New file.
3772         * generated/unpack_r16.c:  New file.
3773         * generated/unpack_c4.c:  New file.
3774         * generated/unpack_c8.c:  New file.
3775         * generated/unpack_c10.c:  New file.
3776         * generated/unpack_c16.c:  New file.
3777
3778 2008-03-22  Jerry DeLisle  <jvdelisle@gcc.gnu.org>
3779
3780         PR libfortran/35632
3781         * io/transfer.c (data_transfer_init):  Fix whitespace.
3782         (next_record_w): Truncate the file only if the stream
3783         position is short of the file end.
3784
3785 2008-03-21  Jerry DeLisle  <jvdelisle@gcc.gnu.org>
3786