Refresh from GCC
[libffi.git] / .pc / ffi_last_abi / ChangeLog
1 2011-01-26  Dave Korn  <dave.korn.cygwin@gmail.com>
2
3         PR target/40125
4         * configure.ac (AM_LTLDFLAGS): Add -bindir option for windows DLLs.
5         * configure: Regenerate.
6
7 2010-12-18  Iain Sandoe  <iains@gcc.gnu.org>
8
9         PR libffi/29152
10         PR libffi/42378
11         * src/powerpc/darwin_closure.S: Provide Darwin64 implementation,
12         update comments.
13         * src/powerpc/ffitarget.h (POWERPC_DARWIN64): New,
14         (FFI_TRAMPOLINE_SIZE): Update for Darwin64.
15         * src/powerpc/darwin.S: Provide Darwin64 implementation,
16         update comments.
17         * src/powerpc/ffi_darwin.c: Likewise.
18
19 2010-12-06  Rainer Orth  <ro@CeBiTec.Uni-Bielefeld.DE>
20
21         * configure.ac (libffi_cv_as_ascii_pseudo_op): Use double
22         backslashes.
23         (libffi_cv_as_string_pseudo_op): Likewise.
24         * configure: Regenerate.
25
26 2010-12-03  Chung-Lin Tang  <cltang@codesourcery.com>
27
28         * src/arm/sysv.S (ffi_closure_SYSV): Add UNWIND to .pad directive.
29         (ffi_closure_VFP): Same.
30         (ffi_call_VFP): Move down to before ffi_closure_VFP. Add '.fpu vfp'
31         directive.
32
33 2010-12-01  Rainer Orth  <ro@CeBiTec.Uni-Bielefeld.DE>
34
35         * testsuite/libffi.call/ffitest.h [__sgi] (PRId64, PRIu64): Define.
36         (PRIuPTR): Define.
37
38 2010-11-29  Richard Henderson  <rth@redhat.com>
39             Rainer Orth  <ro@CeBiTec.Uni-Bielefeld.DE>
40
41         * src/x86/sysv.S (FDE_ENCODING, FDE_ENCODE): Define.
42         (.eh_frame): Use FDE_ENCODING.
43         (.LASFDE1, .LASFDE2, LASFDE3): Simplify with FDE_ENCODE.
44
45 2010-11-15  Rainer Orth  <ro@CeBiTec.Uni-Bielefeld.DE>
46
47         * testsuite/lib/libffi-dg.exp: Rename ...
48         * testsuite/lib/libffi.exp: ... to this.
49         * libffi/testsuite/libffi.call/call.exp: Don't load libffi-dg.exp.
50         * libffi/testsuite/libffi.special/special.exp: Likewise.
51
52 2010-10-28  Chung-Lin Tang  <cltang@codesourcery.com>
53
54         * src/arm/ffi.c (ffi_prep_args): Add VFP register argument handling
55         code, new parameter, and return value. Update comments.
56         (ffi_prep_cif_machdep): Add case for VFP struct return values. Add
57         call to layout_vfp_args().
58         (ffi_call_SYSV): Update declaration.
59         (ffi_call_VFP): New declaration.
60         (ffi_call): Add VFP struct return conditions. Call ffi_call_VFP()
61         when ABI is FFI_VFP.
62         (ffi_closure_VFP): New declaration.
63         (ffi_closure_SYSV_inner): Add new vfp_args parameter, update call to
64         ffi_prep_incoming_args_SYSV().
65         (ffi_prep_incoming_args_SYSV): Update parameters. Add VFP argument
66         case handling.
67         (ffi_prep_closure_loc): Pass ffi_closure_VFP to trampoline
68         construction under VFP hard-float.
69         (rec_vfp_type_p): New function.
70         (vfp_type_p): Same.
71         (place_vfp_arg): Same.
72         (layout_vfp_args): Same.
73         * src/arm/ffitarget.h (ffi_abi): Add FFI_VFP. Define FFI_DEFAULT_ABI
74         based on __ARM_PCS_VFP.
75         (FFI_EXTRA_CIF_FIELDS): Define for adding VFP hard-float specific
76         fields.
77         (FFI_TYPE_STRUCT_VFP_FLOAT): Define internally used type code.
78         (FFI_TYPE_STRUCT_VFP_DOUBLE): Same.
79         * src/arm/sysv.S (ffi_call_SYSV): Change call of ffi_prep_args() to
80         direct call. Move function pointer load upwards.
81         (ffi_call_VFP): New function.
82         (ffi_closure_VFP): Same.
83
84         * testsuite/lib/libffi-dg.exp (check-flags): New function.
85         (dg-skip-if): New function.
86         * testsuite/libffi.call/cls_double_va.c: Skip if target is arm*-*-*
87         and compiler options include -mfloat-abi=hard.
88         * testsuite/libffi.call/cls_longdouble_va.c: Same.
89
90 2010-10-01  Jakub Jelinek  <jakub@redhat.com>
91
92         PR libffi/45677
93         * src/x86/ffi64.c (ffi_prep_cif_machdep): Ensure cif->bytes is
94         a multiple of 8.
95         * testsuite/libffi.call/many2.c: New test.
96
97 2010-08-20  Mark Wielaard  <mjw@redhat.com>
98
99         * src/closures.c (open_temp_exec_file_mnt): Check if getmntent_r
100         returns NULL.
101
102 2010-08-09  Andreas Tobler  <andreast@fgznet.ch>
103
104         * configure.ac: Add target powerpc64-*-freebsd*.
105         * configure: Regenerate.
106         * testsuite/libffi.call/cls_align_longdouble_split.c: Pass
107         -mlong-double-128 only to linux targets.
108         * testsuite/libffi.call/cls_align_longdouble_split2.c: Likewise.
109         * testsuite/libffi.call/cls_longdouble.c: Likewise.
110         * testsuite/libffi.call/huge_struct.c: Likewise.
111
112 2010-07-10  Evan Phoenix  <evan@fallingsnow.net>
113
114         * src/closures.c (selinux_enabled_check): Fix strncmp usage bug.
115
116 2010-07-07  Dan HorĂ¡k <dan@danny.cz>
117
118         * include/ffi.h.in: Protect #define with #ifndef.
119         * src/powerpc/ffitarget.h: Ditto.
120         * src/s390/ffitarget.h: Ditto.
121         * src/sparc/ffitarget.h: Ditto.
122
123 2010-07-07   Neil Roberts <neil@linux.intel.com>
124
125         * src/x86/sysv.S (ffi_call_SYSV): Align the stack pointer to
126         16-bytes.
127
128 2010-07-02  Jakub Jelinek  <jakub@redhat.com>
129
130         * Makefile.am (AM_MAKEFLAGS): Pass also mandir to submakes.
131         * Makefile.in: Regenerated.
132
133 2010-05-19  Rainer Orth  <ro@CeBiTec.Uni-Bielefeld.DE>
134
135         * configure.ac (libffi_cv_as_x86_pcrel): Check for illegal in as
136         output, too.
137         (libffi_cv_as_ascii_pseudo_op): Check for .ascii.
138         (libffi_cv_as_string_pseudo_op): Check for .string.
139         * configure: Regenerate.
140         * fficonfig.h.in: Regenerate.
141         * src/x86/sysv.S (.eh_frame): Use .ascii, .string or error.
142
143 2010-05-05  Michael Kohler <michaelkohler@live.com>
144
145         * src/dlmalloc.c (dlfree): Fix spelling.
146         * src/ia64/ffi.c (ffi_prep_cif_machdep): Ditto.
147         * configure.ac: Ditto.
148         * configure: Rebuilt.
149
150 2010-04-13  Dan Witte  <dwitte@mozilla.com>
151
152         * msvcc.sh: Build with -W3 instead of -Wall.
153         * src/powerpc/ffi_darwin.c: Remove build warnings.
154         * src/x86/ffi.c: Ditto.
155         * src/x86/ffitarget.h: Ditto.
156
157 2010-04-12  Dan Witte  <dwitte@mozilla.com>
158             Walter Meinl <wuno@lsvw.de>
159
160         * configure.ac: Add OS/2 support.
161         * configure: Rebuilt.
162         * src/closures.c: Ditto.
163         * src/dlmalloc.c: Ditto.
164         * src/x86/win32.S: Ditto.
165
166 2010-04-07  Jakub Jelinek  <jakub@redhat.com>
167
168         * testsuite/libffi.call/err_bad_abi.c: Remove unused args variable.
169
170 2010-04-02  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
171
172         * Makefile.in: Regenerate.
173         * aclocal.m4: Regenerate.
174         * include/Makefile.in: Regenerate.
175         * man/Makefile.in: Regenerate.
176         * testsuite/Makefile.in: Regenerate.
177
178 2010-03-30  Dan Witte  <dwitte@mozilla.com>
179
180         * msvcc.sh: Disable build warnings.
181         * README (tested): Clarify windows build procedure.
182
183 2010-03-15  Rainer Orth  <ro@CeBiTec.Uni-Bielefeld.DE>
184
185         * configure.ac (libffi_cv_as_x86_64_unwind_section_type): New test.
186         * configure: Regenerate.
187         * fficonfig.h.in: Regenerate.
188         * libffi/src/x86/unix64.S (.eh_frame)
189         [HAVE_AS_X86_64_UNWIND_SECTION_TYPE]: Use @unwind section type.
190
191 2010-03-14  Matthias Klose  <doko@ubuntu.com>
192
193         * src/x86/ffi64.c: Fix typo in comment.
194         * src/x86/ffi.c: Use /* ... */ comment style.
195
196 2010-02-24  Rainer Orth  <ro@CeBiTec.Uni-Bielefeld.DE>
197
198         * doc/libffi.texi (The Closure API): Fix typo.
199         * doc/libffi.info: Remove.
200
201 2010-02-15  Matthias Klose  <doko@ubuntu.com>
202
203         * src/arm/sysv.S (__ARM_ARCH__): Define for processor
204         __ARM_ARCH_7EM__.
205
206 2010-01-15  Anthony Green  <green@redhat.com>
207
208         * README: Add notes on building with Microsoft Visual C++.
209
210 2010-01-15  Daniel Witte  <dwitte@mozilla.com>
211
212         * msvcc.sh: New file.
213
214         * src/x86/win32.S: Port assembly routines to MSVC and #ifdef.
215         * src/x86/ffi.c: Tweak function declaration and remove excess
216         parens.
217         * include/ffi.h.in: Add __declspec(align(8)) to typedef struct
218         ffi_closure.
219
220         * src/x86/ffi.c: Merge ffi_call_SYSV and ffi_call_STDCALL into new
221         function ffi_call_win32 on X86_WIN32.
222         * src/x86/win32.S (ffi_call_SYSV): Rename to ffi_call_win32.
223         (ffi_call_STDCALL): Remove.
224
225         * src/prep_cif.c (ffi_prep_cif): Move stack space allocation code
226         to ffi_prep_cif_machdep for x86.
227         * src/x86/ffi.c (ffi_prep_cif_machdep): To here.
228
229 2010-01-15  Oliver Kiddle  <okiddle@yahoo.co.uk>
230
231         * src/x86/ffitarget.h (ffi_abi): Check for __i386 and __amd64 for
232         Sun Studio compiler compatibility.
233
234 2010-01-12  Conrad Irwin <conrad.irwin@gmail.com>
235
236         * doc/libffi.texi: Add closure example.
237
238 2010-01-07  Rainer Orth  <ro@CeBiTec.Uni-Bielefeld.DE>
239
240         PR libffi/40701
241         * testsuite/libffi.call/ffitest.h [__alpha__ && __osf__] (PRIdLL,
242         PRIuLL, PRId64, PRIu64, PRIuPTR): Define.
243         * testsuite/libffi.call/cls_align_sint64.c: Add -Wno-format on
244         alpha*-dec-osf*.
245         * testsuite/libffi.call/cls_align_uint64.c: Likewise.
246         * testsuite/libffi.call/cls_ulonglong.c: Likewise.
247         * testsuite/libffi.call/return_ll1.c: Likewise.
248         * testsuite/libffi.call/stret_medium2.c: Likewise.
249         * testsuite/libffi.special/ffitestcxx.h (allocate_mmap): Cast
250         MAP_FAILED to char *.
251
252 2010-01-06  Rainer Orth  <ro@CeBiTec.Uni-Bielefeld.DE>
253
254         * src/mips/n32.S: Use .abicalls and .eh_frame with __GNUC__.
255
256 2009-12-31  Anthony Green  <green@redhat.com>
257
258         * README: Update for libffi 3.0.9.
259
260 2009-12-27  Matthias Klose  <doko@ubuntu.com>
261
262         * configure.ac (HAVE_LONG_DOUBLE): Define for mips when
263         appropriate.
264         * configure: Rebuilt.
265
266 2009-12-26  Anthony Green  <green@redhat.com>
267
268         * testsuite/libffi.call/cls_longdouble_va.c: Mark as xfail for
269         avr32*-*-*.
270         * testsuite/libffi.call/cls_double_va.c: Ditto.
271
272 2009-12-26  Andreas Tobler  <a.tobler@schweiz.org>
273
274         * testsuite/libffi.call/ffitest.h: Conditionally include stdint.h
275         and inttypes.h.
276         * testsuite/libffi.special/unwindtest.cc: Ditto.
277
278 2009-12-26  Andreas Tobler  <a.tobler@schweiz.org>
279
280         * configure.ac: Add amd64-*-openbsd*.
281         * configure: Rebuilt.
282         * testsuite/lib/libffi-dg.exp (libffi_target_compile): Link
283         openbsd programs with -lpthread.
284
285 2009-12-26  Anthony Green  <green@redhat.com>
286
287         * testsuite/libffi.call/cls_double_va.c,
288         testsuite/libffi.call/cls_longdouble.c,
289         testsuite/libffi.call/cls_longdouble_va.c,
290         testsuite/libffi.call/cls_pointer.c,
291         testsuite/libffi.call/cls_pointer_stack.c: Remove xfail for
292         mips*-*-* and arm*-*-*.
293         * testsuite/libffi.call/cls_align_longdouble_split.c,
294         testsuite/libffi.call/cls_align_longdouble_split2.c,
295         testsuite/libffi.call/stret_medium2.c,
296         testsuite/libffi.call/stret_medium.c,
297         testsuite/libffi.call/stret_large.c,
298         testsuite/libffi.call/stret_large2.c: Remove xfail for arm*-*-*.
299
300 2009-12-31  Kay Tietz  <ktietz70@googlemail.com>
301
302         * testsuite/libffi.call/ffitest.h,
303         testsuite/libffi.special/ffitestcxx.h (PRIdLL, PRuLL): Fix
304         definitions.
305
306 2009-12-31  Carlo Bramini  <carlo.bramix@libero.it>
307
308         * configure.ac (AM_LTLDFLAGS): Define for windows hosts.
309         * Makefile.am (libffi_la_LDFLAGS): Add AM_LTLDFLAGS.
310         * configure: Rebuilt.
311         * Makefile.in: Rebuilt.
312
313 2009-12-31  Anthony Green  <green@redhat.com>
314             Blake Chaffin.
315
316         * testsuite/libffi.call/huge_struct.c: New test case from Blake
317         Chaffin @ Apple.
318
319 2009-12-28  David Edelsohn  <edelsohn@gnu.org>
320
321         * src/powerpc/ffi_darwin.c (ffi_prep_args): Copy abi and nargs to
322         local variables.
323         (aix_adjust_aggregate_sizes): New function.
324         (ffi_prep_cif_machdep): Call it.
325
326 2009-12-26  Andreas Tobler  <a.tobler@schweiz.org>
327
328         * configure.ac: Define FFI_MMAP_EXEC_WRIT for the given targets.
329         * configure: Regenerate.
330         * fficonfig.h.in: Likewise.
331         * src/closures.c: Remove the FFI_MMAP_EXEC_WRIT definition for
332         Solaris/x86.
333
334 2009-12-26  Andreas Schwab  <schwab@linux-m68k.org>
335
336         * src/powerpc/ffi.c (ffi_prep_args_SYSV): Advance intarg_count
337         when a float arguments is passed in memory.
338         (ffi_closure_helper_SYSV): Mark general registers as used up when
339         a 64bit or soft-float long double argument is passed in memory.
340
341 2009-12-25  Matthias Klose  <doko@ubuntu.com>
342
343         * man/ffi_call.3: Fix #include in examples.
344         * doc/libffi.texi: Add dircategory.
345
346 2009-12-25  Frank Everdij <f.p.x.everdij@tudelft.nl>
347
348         * include/ffi.h.in: Placed '__GNUC__' ifdef around
349         '__attribute__((aligned(8)))' in ffi_closure, fixes compile for
350         IRIX MIPSPro c99.
351         * include/ffi_common.h: Added '__sgi' define to non
352         '__attribute__((__mode__()))' integer typedefs.
353         * src/mips/ffi.c (ffi_call, ffi_closure_mips_inner_O32,
354         ffi_closure_mips_inner_N32): Added 'defined(_MIPSEB)' to BE check.
355         (ffi_closure_mips_inner_O32, ffi_closure_mips_inner_N32): Added
356         FFI_LONGDOUBLE support and alignment(N32 only).
357         * src/mips/ffitarget.h: Corrected '#include <sgidefs.h>' for IRIX and
358         fixed non '__attribute__((__mode__()))' integer typedefs.
359         * src/mips/n32.S: Put '#ifdef linux' around '.abicalls' and '.eh_frame'
360         since they are Linux/GNU Assembler specific.
361
362 2009-12-25  Bradley Smith  <brad@brad-smith.co.uk>
363
364         * configure.ac, Makefile.am, src/avr32/ffi.c,
365         src/avr32/ffitarget.h,
366         src/avr32/sysv.S: Add AVR32 port.
367         * configure, Makefile.in: Rebuilt.
368
369 2009-12-21  Andreas Tobler  <a.tobler@schweiz.org>
370
371         * configure.ac: Make i?86 build on FreeBSD and OpenBSD.
372         * configure: Regenerate.
373
374 2009-12-15  John David Anglin  <dave.anglin@nrc-cnrc.gc.ca>
375
376         * testsuite/libffi.call/ffitest.h: Define PRIuPTR on PA HP-UX.
377
378 2009-12-13  John David Anglin  <dave.anglin@nrc-cnrc.gc.ca>
379
380         * src/pa/ffi.c (ffi_closure_inner_pa32): Handle FFI_TYPE_LONGDOUBLE
381         type on HP-UX.
382
383 2009-12-11  Eric Botcazou  <ebotcazou@adacore.com>
384
385         * src/sparc/ffi.c (ffi_closure_sparc_inner_v9): Properly align 'long
386         double' arguments.
387
388 2009-12-11  Eric Botcazou  <ebotcazou@adacore.com>
389
390         * testsuite/libffi.call/ffitest.h: Define PRIuPTR on Solaris < 10.
391
392 2009-12-10  Rainer Orth  <ro@CeBiTec.Uni-Bielefeld.DE>
393
394         PR libffi/40700
395         * src/closures.c [X86_64 && __sun__ && __svr4__]
396         (FFI_MMAP_EXEC_WRIT): Define.
397
398 2009-12-08  David Daney  <ddaney@caviumnetworks.com>
399
400         * testsuite/libffi.call/stret_medium.c: Remove xfail for mips*-*-*
401         * testsuite/libffi.call/cls_align_longdouble_split2.c: Same.
402         * testsuite/libffi.call/stret_large.c: Same.
403         * testsuite/libffi.call/cls_align_longdouble_split.c: Same.
404         * testsuite/libffi.call/stret_large2.c: Same.
405         * testsuite/libffi.call/stret_medium2.c: Same.
406
407 2009-12-07  David Edelsohn  <edelsohn@gnu.org>
408
409         * src/powerpc/aix_closure.S (libffi_closure_ASM): Fix tablejump
410         typo.
411
412 2009-12-05  David Edelsohn  <edelsohn@gnu.org>
413
414         * src/powerpc/aix.S: Update AIX32 code to be consistent with AIX64
415         code.
416         * src/powerpc/aix_closure.S: Same.
417
418 2009-12-05  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
419
420         * Makefile.in: Regenerate.
421         * configure: Regenerate.
422         * include/Makefile.in: Regenerate.
423         * man/Makefile.in: Regenerate.
424         * testsuite/Makefile.in: Regenerate.
425
426 2009-12-04  David Edelsohn  <edelsohn@gnu.org>
427
428         * src/powerpc/aix_closure.S: Reorganize 64-bit code to match
429         linux64_closure.S.
430
431 2009-12-04  Uros Bizjak  <ubizjak@gmail.com>
432
433         PR libffi/41908
434         * src/x86/ffi64.c (classify_argument): Update from
435         gcc/config/i386/i386.c.
436         (ffi_closure_unix64_inner): Do not use the address of two consecutive
437         SSE registers directly.
438         * testsuite/libffi.call/cls_dbls_struct.c (main): Remove xfail
439         for x86_64 linux targets.
440
441 2009-12-04  David Edelsohn  <edelsohn@gnu.org>
442
443         * src/powerpc/ffi_darwin.c (ffi_closure_helper_DARWIN): Increment
444         pfr for long double split between fpr13 and stack.
445
446 2009-12-03  David Edelsohn  <edelsohn@gnu.org>
447
448         * src/powerpc/ffi_darwin.c (ffi_prep_args): Increment next_arg and
449         fparg_count twice for long double.
450
451 2009-12-03  David Edelsohn  <edelsohn@gnu.org>
452
453         PR libffi/42243
454         * src/powerpc/ffi_darwin.c (ffi_prep_args): Remove extra parentheses.
455
456 2009-12-03  Uros Bizjak  <ubizjak@gmail.com>
457
458         * testsuite/libffi.call/cls_longdouble_va.c (main): Fix format string.
459         Remove xfails for x86 linux targets.
460
461 2009-12-02  David Edelsohn  <edelsohn@gnu.org>
462
463         * src/powerpc/ffi_darwin.c (ffi_prep_args): Fix typo in INT64
464         case.
465
466 2009-12-01  David Edelsohn  <edelsohn@gnu.org>
467
468         * src/powerpc/aix.S (ffi_call_AIX): Convert to more standard
469         register usage.  Call ffi_prep_args directly.  Add long double
470         return value support.
471         * src/powerpc/ffi_darwin.c (ffi_prep_args): Double arg increment
472         applies to FFI_TYPE_DOUBLE.  Correct fpr_base increment typo.
473         Separate FFI_TYPE_SINT32 and FFI_TYPE_UINT32 cases.
474         (ffi_prep_cif_machdep): Only 16 byte stack alignment in 64 bit
475         mode.
476         (ffi_closure_helper_DARWIN): Remove nf and ng counters.  Move temp
477         into case.
478         * src/powerpc/aix_closure.S: Maintain 16 byte stack alignment.
479         Allocate result area between params and FPRs.
480
481 2009-11-30  David Edelsohn  <edelsohn@gnu.org>
482
483         PR target/35484
484         * src/powerpc/ffitarget.h (POWERPC64): Define for PPC64 Linux and
485         AIX64.
486         * src/powerpc/aix.S: Implement AIX64 version.
487         * src/powerpc/aix_closure.S: Implement AIX64 version.
488         (ffi_closure_ASM): Use extsb, lha and displament addresses.
489         * src/powerpc/ffi_darwin.c (ffi_prep_args): Implement AIX64
490         support.
491         (ffi_prep_cif_machdep): Same.
492         (ffi_call): Same.
493         (ffi_closure_helper_DARWIN): Same.
494
495 2009-11-02  Andreas Tobler  <a.tobler@schweiz.org>
496
497         PR libffi/41908
498         * testsuite/libffi.call/testclosure.c: New test.
499
500 2009-09-28  Kai Tietz  <kai.tietz@onevision.com>
501
502         * src/x86/win64.S (_ffi_call_win64 stack): Remove for gnu
503         assembly version use of ___chkstk.
504
505 2009-09-23  Matthias Klose  <doko@ubuntu.com>
506
507         PR libffi/40242, PR libffi/41443
508         * src/arm/sysv.S (__ARM_ARCH__): Define for processors
509         __ARM_ARCH_6T2__, __ARM_ARCH_6M__, __ARM_ARCH_7__,
510         __ARM_ARCH_7A__, __ARM_ARCH_7R__, __ARM_ARCH_7M__.
511         Change the conditionals to __SOFTFP__ || __ARM_EABI__
512         for -mfloat-abi=softfp to work.
513
514 2009-09-17  Loren J. Rittle  <ljrittle@acm.org>
515
516         PR testsuite/32843 (strikes again)
517         * src/x86/ffi.c (ffi_prep_cif_machdep): Add X86_FREEBSD to
518         enable proper extension on char and short.
519
520 2009-09-15  David Daney  <ddaney@caviumnetworks.com>
521
522         * src/java_raw_api.c (ffi_java_raw_to_rvalue): Remove special
523         handling for FFI_TYPE_POINTER.
524         * src/mips/ffitarget.h (FFI_TYPE_STRUCT_D_SOFT,
525         FFI_TYPE_STRUCT_F_SOFT, FFI_TYPE_STRUCT_DD_SOFT,
526         FFI_TYPE_STRUCT_FF_SOFT, FFI_TYPE_STRUCT_FD_SOFT,
527         FFI_TYPE_STRUCT_DF_SOFT, FFI_TYPE_STRUCT_SOFT): New defines.
528         (FFI_N32_SOFT_FLOAT, FFI_N64_SOFT_FLOAT): New ffi_abi enumerations.
529         (enum ffi_abi): Set FFI_DEFAULT_ABI for soft-float.
530         * src/mips/n32.S (ffi_call_N32): Add handling for soft-float
531         structure and pointer returns.
532         (ffi_closure_N32): Add handling for pointer returns.
533         * src/mips/ffi.c (ffi_prep_args, calc_n32_struct_flags,
534         calc_n32_return_struct_flags): Handle soft-float.
535         (ffi_prep_cif_machdep):  Handle soft-float, fix pointer handling.
536         (ffi_call_N32): Declare proper argument types.
537         (ffi_call, copy_struct_N32, ffi_closure_mips_inner_N32): Handle
538         soft-float.
539
540 2009-08-24  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
541
542         * configure.ac (AC_PREREQ): Bump to 2.64.
543
544 2009-08-22  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
545
546         * Makefile.am (install-html, install-pdf): Remove.
547         * Makefile.in: Regenerate.
548
549         * Makefile.in: Regenerate.
550         * aclocal.m4: Regenerate.
551         * configure: Regenerate.
552         * fficonfig.h.in: Regenerate.
553         * include/Makefile.in: Regenerate.
554         * man/Makefile.in: Regenerate.
555         * testsuite/Makefile.in: Regenerate.
556
557 2009-07-30  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
558
559         * configure.ac (_AC_ARG_VAR_PRECIOUS): Use m4_rename_force.
560
561 2009-07-24  Dave Korn  <dave.korn.cygwin@gmail.com>
562
563         PR libffi/40807
564         * src/x86/ffi.c (ffi_prep_cif_machdep): Also use sign/zero-extending
565         return types for X86_WIN32.
566         * src/x86/win32.S (_ffi_call_SYSV): Handle omitted return types.
567         (_ffi_call_STDCALL, _ffi_closure_SYSV, _ffi_closure_raw_SYSV,
568         _ffi_closure_STDCALL): Likewise.
569
570         * src/closures.c (is_selinux_enabled): Define to const 0 for Cygwin.
571         (dlmmap, dlmunmap): Also use these functions on Cygwin.
572
573 2009-07-11  Richard Sandiford  <rdsandiford@googlemail.com>
574
575         PR testsuite/40699
576         PR testsuite/40707
577         PR testsuite/40709
578         * testsuite/lib/libffi-dg.exp: Revert 2009-07-02, 2009-07-01 and
579         2009-06-30 commits.
580
581 2009-07-01  Richard Sandiford  <r.sandiford@uk.ibm.com>
582
583         * testsuite/lib/libffi-dg.exp (libffi-init): Set ld_library_path
584         to "" before adding paths.  (This reinstates an assignment that
585         was removed by my 2009-06-30 commit, but changes the initial
586         value from "." to "".)
587
588 2009-07-01  H.J. Lu  <hongjiu.lu@intel.com>
589
590         PR testsuite/40601
591         * testsuite/lib/libffi-dg.exp (libffi-init): Properly set
592         gccdir.  Adjust ld_library_path for gcc only if gccdir isn't
593         empty.
594
595 2009-06-30  Richard Sandiford  <r.sandiford@uk.ibm.com>
596
597         * testsuite/lib/libffi-dg.exp (libffi-init): Don't add "."
598         to ld_library_path.  Use add_path.  Add just find_libgcc_s
599         to ld_library_path, not every libgcc multilib directory.
600
601 2009-06-16  Wim Lewis  <wiml@hhhh.org>
602
603         * src/powerpc/ffi.c: Avoid clobbering cr3 and cr4, which are
604         supposed to be callee-saved.
605         * src/powerpc/sysv.S (small_struct_return_value): Fix overrun of
606         return buffer for odd-size structs.
607
608 2009-06-16  Andreas Tobler  <a.tobler@schweiz.org>
609
610         PR libffi/40444
611         * testsuite/lib/libffi-dg.exp (libffi_target_compile): Add
612         allow_stack_execute for Darwin.
613
614 2009-06-16  Andrew Haley  <aph@redhat.com>
615
616         * configure.ac (TARGETDIR): Add missing blank lines.
617         * configure: Regenerate.
618
619 2009-06-16  Andrew Haley  <aph@redhat.com>
620
621         * testsuite/libffi.call/cls_align_sint64.c,
622         testsuite/libffi.call/cls_align_uint64.c,
623         testsuite/libffi.call/cls_longdouble_va.c,
624         testsuite/libffi.call/cls_ulonglong.c,
625         testsuite/libffi.call/return_ll1.c,
626         testsuite/libffi.call/stret_medium2.c: Fix printf format
627         specifiers.
628         * testsuite/libffi.call/ffitest.h,
629         testsuite/libffi.special/ffitestcxx.h (PRIdLL, PRIuLL): Define.
630
631 2009-06-15  Andrew Haley  <aph@redhat.com>
632
633         * testsuite/libffi.call/err_bad_typedef.c: xfail everywhere.
634         * testsuite/libffi.call/err_bad_abi.c: Likewise.
635
636 2009-06-12  Andrew Haley  <aph@redhat.com>
637
638         * Makefile.am: Remove info_TEXINFOS.
639
640 2009-06-12  Andrew Haley  <aph@redhat.com>
641
642         * ChangeLog.libffi: testsuite/libffi.call/cls_align_sint64.c,
643         testsuite/libffi.call/cls_align_uint64.c,
644         testsuite/libffi.call/cls_ulonglong.c,
645         testsuite/libffi.call/return_ll1.c,
646         testsuite/libffi.call/stret_medium2.c: Fix printf format
647         specifiers.
648         testsuite/libffi.special/unwindtest.cc: include stdint.h.
649
650 2009-06-11  Timothy Wall  <twall@users.sf.net>
651
652         * Makefile.am,
653         configure.ac,
654         include/ffi.h.in,
655         include/ffi_common.h,
656         src/closures.c,
657         src/dlmalloc.c,
658         src/x86/ffi.c,
659         src/x86/ffitarget.h,
660         src/x86/win64.S (new),
661         README: Added win64 support (mingw or MSVC)
662         * Makefile.in,
663         include/Makefile.in,
664         man/Makefile.in,
665         testsuite/Makefile.in,
666         configure,
667         aclocal.m4: Regenerated
668         * ltcf-c.sh: properly escape cygwin/w32 path
669         * man/ffi_call.3: Clarify size requirements for return value.
670         * src/x86/ffi64.c: Fix filename in comment.
671         * src/x86/win32.S: Remove unused extern.
672
673         * testsuite/libffi.call/closure_fn0.c,
674         testsuite/libffi.call/closure_fn1.c,
675         testsuite/libffi.call/closure_fn2.c,
676         testsuite/libffi.call/closure_fn3.c,
677         testsuite/libffi.call/closure_fn4.c,
678         testsuite/libffi.call/closure_fn5.c,
679         testsuite/libffi.call/closure_fn6.c,
680         testsuite/libffi.call/closure_stdcall.c,
681         testsuite/libffi.call/cls_12byte.c,
682         testsuite/libffi.call/cls_16byte.c,
683         testsuite/libffi.call/cls_18byte.c,
684         testsuite/libffi.call/cls_19byte.c,
685         testsuite/libffi.call/cls_1_1byte.c,
686         testsuite/libffi.call/cls_20byte.c,
687         testsuite/libffi.call/cls_20byte1.c,
688         testsuite/libffi.call/cls_24byte.c,
689         testsuite/libffi.call/cls_2byte.c,
690         testsuite/libffi.call/cls_3_1byte.c,
691         testsuite/libffi.call/cls_3byte1.c,
692         testsuite/libffi.call/cls_3byte2.c,
693         testsuite/libffi.call/cls_4_1byte.c,
694         testsuite/libffi.call/cls_4byte.c,
695         testsuite/libffi.call/cls_5_1_byte.c,
696         testsuite/libffi.call/cls_5byte.c,
697         testsuite/libffi.call/cls_64byte.c,
698         testsuite/libffi.call/cls_6_1_byte.c,
699         testsuite/libffi.call/cls_6byte.c,
700         testsuite/libffi.call/cls_7_1_byte.c,
701         testsuite/libffi.call/cls_7byte.c,
702         testsuite/libffi.call/cls_8byte.c,
703         testsuite/libffi.call/cls_9byte1.c,
704         testsuite/libffi.call/cls_9byte2.c,
705         testsuite/libffi.call/cls_align_double.c,
706         testsuite/libffi.call/cls_align_float.c,
707         testsuite/libffi.call/cls_align_longdouble.c,
708         testsuite/libffi.call/cls_align_longdouble_split.c,
709         testsuite/libffi.call/cls_align_longdouble_split2.c,
710         testsuite/libffi.call/cls_align_pointer.c,
711         testsuite/libffi.call/cls_align_sint16.c,
712         testsuite/libffi.call/cls_align_sint32.c,
713         testsuite/libffi.call/cls_align_sint64.c,
714         testsuite/libffi.call/cls_align_uint16.c,
715         testsuite/libffi.call/cls_align_uint32.c,
716         testsuite/libffi.call/cls_align_uint64.c,
717         testsuite/libffi.call/cls_dbls_struct.c,
718         testsuite/libffi.call/cls_double.c,
719         testsuite/libffi.call/cls_double_va.c,
720         testsuite/libffi.call/cls_float.c,
721         testsuite/libffi.call/cls_longdouble.c,
722         testsuite/libffi.call/cls_longdouble_va.c,
723         testsuite/libffi.call/cls_multi_schar.c,
724         testsuite/libffi.call/cls_multi_sshort.c,
725         testsuite/libffi.call/cls_multi_sshortchar.c,
726         testsuite/libffi.call/cls_multi_uchar.c,
727         testsuite/libffi.call/cls_multi_ushort.c,
728         testsuite/libffi.call/cls_multi_ushortchar.c,
729         testsuite/libffi.call/cls_pointer.c,
730         testsuite/libffi.call/cls_pointer_stack.c,
731         testsuite/libffi.call/cls_schar.c,
732         testsuite/libffi.call/cls_sint.c,
733         testsuite/libffi.call/cls_sshort.c,
734         testsuite/libffi.call/cls_uchar.c,
735         testsuite/libffi.call/cls_uint.c,
736         testsuite/libffi.call/cls_ulonglong.c,
737         testsuite/libffi.call/cls_ushort.c,
738         testsuite/libffi.call/err_bad_abi.c,
739         testsuite/libffi.call/err_bad_typedef.c,
740         testsuite/libffi.call/float2.c,
741         testsuite/libffi.call/huge_struct.c,
742         testsuite/libffi.call/nested_struct.c,
743         testsuite/libffi.call/nested_struct1.c,
744         testsuite/libffi.call/nested_struct10.c,
745         testsuite/libffi.call/nested_struct2.c,
746         testsuite/libffi.call/nested_struct3.c,
747         testsuite/libffi.call/nested_struct4.c,
748         testsuite/libffi.call/nested_struct5.c,
749         testsuite/libffi.call/nested_struct6.c,
750         testsuite/libffi.call/nested_struct7.c,
751         testsuite/libffi.call/nested_struct8.c,
752         testsuite/libffi.call/nested_struct9.c,
753         testsuite/libffi.call/problem1.c,
754         testsuite/libffi.call/return_ldl.c,
755         testsuite/libffi.call/return_ll1.c,
756         testsuite/libffi.call/stret_large.c,
757         testsuite/libffi.call/stret_large2.c,
758         testsuite/libffi.call/stret_medium.c,
759         testsuite/libffi.call/stret_medium2.c,
760         testsuite/libffi.special/unwindtest.cc: use ffi_closure_alloc instead
761         of checking for MMAP.  Use intptr_t instead of long casts.
762
763 2009-06-11  Kaz Kojima  <kkojima@gcc.gnu.org>
764
765         * testsuite/libffi.call/cls_longdouble_va.c: Add xfail sh*-*-linux-*.
766         * testsuite/libffi.call/err_bad_abi.c: Add xfail sh*-*-*.
767         * testsuite/libffi.call/err_bad_typedef.c: Likewise.
768
769 2009-06-09  Andrew Haley  <aph@redhat.com>
770
771         * src/x86/freebsd.S: Add missing file.
772
773 2009-06-08  Andrew Haley  <aph@redhat.com>
774
775         Import from libffi 3.0.8:
776
777         * doc/libffi.texi: New file.
778         * doc/libffi.info: Likewise.
779         * doc/stamp-vti: Likewise.
780         * man/Makefile.am: New file.
781         * man/ffi_call.3: New file.
782
783         * Makefile.am (EXTRA_DIST): Add src/x86/darwin64.S,
784         src/dlmalloc.c.
785         (nodist_libffi_la_SOURCES): Add X86_FREEBSD.
786
787         * configure.ac: Bump version to 3.0.8.
788         parisc*-*-linux*: Add.
789         i386-*-freebsd* | i386-*-openbsd*: Add.
790         powerpc-*-beos*: Add.
791         AM_CONDITIONAL X86_FREEBSD: Add.
792         AC_CONFIG_FILES: Add man/Makefile.
793
794         * include/ffi.h.in (FFI_FN): Change void (*)() to void (*)(void).
795
796 2009-06-08  Andrew Haley  <aph@redhat.com>
797
798         * README: Import from libffi 3.0.8.
799
800 2009-06-08  Andrew Haley  <aph@redhat.com>
801
802         * testsuite/libffi.call/err_bad_abi.c: Add xfails.
803         * testsuite/libffi.call/cls_longdouble_va.c: Add xfails.
804         * testsuite/libffi.call/cls_dbls_struct.c: Add xfail x86_64-*-linux-*.
805         * testsuite/libffi.call/err_bad_typedef.c: Add xfails.
806
807         * testsuite/libffi.call/stret_medium2.c: Add __UNUSED__ to args.
808         * testsuite/libffi.call/stret_medium.c: Likewise.
809         * testsuite/libffi.call/stret_large2.c: Likewise.
810         * testsuite/libffi.call/stret_large.c:  Likewise.
811
812 2008-12-26  Timothy Wall  <twall@users.sf.net>
813
814         * testsuite/libffi.call/cls_longdouble.c,
815         testsuite/libffi.call/cls_longdouble_va.c,
816         testsuite/libffi.call/cls_align_longdouble.c,
817         testsuite/libffi.call/cls_align_longdouble_split.c,
818         testsuite/libffi.call/cls_align_longdouble_split2.c: mark expected
819         failures on x86_64 cygwin/mingw.
820
821 2008-12-22  Timothy Wall  <twall@users.sf.net>
822
823         * testsuite/libffi.call/closure_fn0.c,
824         testsuite/libffi.call/closure_fn1.c,
825         testsuite/libffi.call/closure_fn2.c,
826         testsuite/libffi.call/closure_fn3.c,
827         testsuite/libffi.call/closure_fn4.c,
828         testsuite/libffi.call/closure_fn5.c,
829         testsuite/libffi.call/closure_fn6.c,
830         testsuite/libffi.call/closure_loc_fn0.c,
831         testsuite/libffi.call/closure_stdcall.c,
832         testsuite/libffi.call/cls_align_pointer.c,
833         testsuite/libffi.call/cls_pointer.c,
834         testsuite/libffi.call/cls_pointer_stack.c: use portable cast from
835         pointer to integer (intptr_t).
836         * testsuite/libffi.call/cls_longdouble.c: disable for win64.
837
838 2008-07-24  Anthony Green  <green@redhat.com>
839
840         * testsuite/libffi.call/cls_dbls_struct.c,
841         testsuite/libffi.call/cls_double_va.c,
842         testsuite/libffi.call/cls_longdouble.c,
843         testsuite/libffi.call/cls_longdouble_va.c,
844         testsuite/libffi.call/cls_pointer.c,
845         testsuite/libffi.call/cls_pointer_stack.c,
846         testsuite/libffi.call/err_bad_abi.c: Clean up failures from
847         compiler warnings.
848
849 2008-03-04  Anthony Green  <green@redhat.com>
850             Blake Chaffin
851             hos@tamanegi.org
852
853         * testsuite/libffi.call/cls_align_longdouble_split2.c
854           testsuite/libffi.call/cls_align_longdouble_split.c
855           testsuite/libffi.call/cls_dbls_struct.c
856           testsuite/libffi.call/cls_double_va.c
857           testsuite/libffi.call/cls_longdouble.c
858           testsuite/libffi.call/cls_longdouble_va.c
859           testsuite/libffi.call/cls_pointer.c
860           testsuite/libffi.call/cls_pointer_stack.c
861           testsuite/libffi.call/err_bad_abi.c
862           testsuite/libffi.call/err_bad_typedef.c
863           testsuite/libffi.call/stret_large2.c
864           testsuite/libffi.call/stret_large.c
865           testsuite/libffi.call/stret_medium2.c
866           testsuite/libffi.call/stret_medium.c: New tests from Apple.
867
868 2009-06-05  Andrew Haley  <aph@redhat.com>
869
870         * src/x86/ffitarget.h, src/x86/ffi.c: Merge stdcall changes from
871         libffi.
872
873 2009-06-04  Andrew Haley  <aph@redhat.com>
874
875         * src/x86/ffitarget.h, src/x86/win32.S, src/x86/ffi.c: Back out
876         stdcall changes.
877
878 2008-02-26  Anthony Green  <green@redhat.com>
879             Thomas Heller  <theller@ctypes.org>
880
881         * src/x86/ffi.c (ffi_closure_SYSV_inner): Change C++ comment to C
882         comment.
883
884 2008-02-03  Timothy Wall  <twall@users.sf.net>
885
886         * src/x86/ffi.c (FFI_INIT_TRAMPOLINE_STDCALL): Calculate jump return
887           offset based on code pointer, not data pointer.
888
889 2008-01-31  Timothy Wall <twall@users.sf.net>
890
891         * testsuite/libffi.call/closure_stdcall.c: Add test for stdcall
892         closures.
893         * src/x86/ffitarget.h: Increase size of trampoline for stdcall
894         closures.
895         * src/x86/win32.S: Add assembly for stdcall closure.
896         * src/x86/ffi.c: Initialize stdcall closure trampoline.
897
898 2009-06-04  Andrew Haley  <aph@redhat.com>
899
900         * include/ffi.h.in: Change void (*)() to void (*)(void).
901         * src/x86/ffi.c: Likewise.
902
903 2009-06-04  Andrew Haley  <aph@redhat.com>
904
905         * src/powerpc/ppc_closure.S: Insert licence header.
906         * src/powerpc/linux64_closure.S: Likewise.
907         * src/m68k/sysv.S: Likewise.
908
909         * src/sh64/ffi.c: Change void (*)() to void (*)(void).
910         * src/powerpc/ffi.c: Likewise.
911         * src/powerpc/ffi_darwin.c: Likewise.
912         * src/m32r/ffi.c: Likewise.
913         * src/sh64/ffi.c: Likewise.
914         * src/x86/ffi64.c: Likewise.
915         * src/alpha/ffi.c: Likewise.
916         * src/alpha/osf.S: Likewise.
917         * src/frv/ffi.c: Likewise.
918         * src/s390/ffi.c: Likewise.
919         * src/pa/ffi.c: Likewise.
920         * src/pa/hpux32.S: Likewise.
921         * src/ia64/unix.S: Likewise.
922         * src/ia64/ffi.c: Likewise.
923         * src/sparc/ffi.c: Likewise.
924         * src/mips/ffi.c: Likewise.
925         * src/sh/ffi.c: Likewise.
926
927 2008-02-15  David Daney  <ddaney@avtrex.com>
928
929         * src/mips/ffi.c (USE__BUILTIN___CLEAR_CACHE):
930         Define (conditionally), and use it to include cachectl.h.
931         (ffi_prep_closure_loc): Fix cache flushing.
932         * src/mips/ffitarget.h (_ABIN32, _ABI64, _ABIO32): Define.
933
934 2009-06-04  Andrew Haley  <aph@redhat.com>
935
936         include/ffi.h.in,
937         src/arm/ffitarget.h,
938         src/arm/ffi.c,
939         src/arm/sysv.S,
940         src/powerpc/ffitarget.h,
941         src/closures.c,
942         src/sh64/ffitarget.h,
943         src/sh64/ffi.c,
944         src/sh64/sysv.S,
945         src/types.c,
946         src/x86/ffi64.c,
947         src/x86/ffitarget.h,
948         src/x86/win32.S,
949         src/x86/darwin.S,
950         src/x86/ffi.c,
951         src/x86/sysv.S,
952         src/x86/unix64.S,
953         src/alpha/ffitarget.h,
954         src/alpha/ffi.c,
955         src/alpha/osf.S,
956         src/m68k/ffitarget.h,
957         src/frv/ffitarget.h,
958         src/frv/ffi.c,
959         src/s390/ffitarget.h,
960         src/s390/sysv.S,
961         src/cris/ffitarget.h,
962         src/pa/linux.S,
963         src/pa/ffitarget.h,
964         src/pa/ffi.c,
965         src/raw_api.c,
966         src/ia64/ffitarget.h,
967         src/ia64/unix.S,
968         src/ia64/ffi.c,
969         src/ia64/ia64_flags.h,
970         src/java_raw_api.c,
971         src/debug.c,
972         src/sparc/v9.S,
973         src/sparc/ffitarget.h,
974         src/sparc/ffi.c,
975         src/sparc/v8.S,
976         src/mips/ffitarget.h,
977         src/mips/n32.S,
978         src/mips/o32.S,
979         src/mips/ffi.c,
980         src/prep_cif.c,
981         src/sh/ffitarget.h,
982         src/sh/ffi.c,
983         src/sh/sysv.S: Update license text.
984
985 2009-05-22  Dave Korn  <dave.korn.cygwin@gmail.com>
986
987         * src/x86/win32.S (_ffi_closure_STDCALL):  New function.
988         (.eh_frame):  Add FDE for it.
989
990 2009-05-22  Dave Korn  <dave.korn.cygwin@gmail.com>
991
992         * configure.ac:  Also check if assembler supports pc-relative
993         relocs on X86_WIN32 targets.
994         * configure:  Regenerate.
995         * src/x86/win32.S (ffi_prep_args):  Declare extern, not global.
996         (_ffi_call_SYSV):  Add missing function type symbol .def and
997         add EH markup labels.
998         (_ffi_call_STDCALL):  Likewise.
999         (_ffi_closure_SYSV):  Likewise.
1000         (_ffi_closure_raw_SYSV):  Likewise.
1001         (.eh_frame):  Add hand-crafted EH data.
1002
1003 2009-04-09  Jakub Jelinek  <jakub@redhat.com>
1004
1005         * testsuite/lib/libffi-dg.exp: Change copyright header to refer to
1006         version 3 of the GNU General Public License and to point readers
1007         at the COPYING3 file and the FSF's license web page.
1008         * testsuite/libffi.call/call.exp: Likewise.
1009         * testsuite/libffi.special/special.exp: Likewise.
1010
1011 2009-03-01  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
1012
1013         * configure: Regenerate.
1014
1015 2008-12-18  Rainer Orth  <ro@TechFak.Uni-Bielefeld.DE>
1016
1017         PR libffi/26048
1018         * configure.ac (HAVE_AS_X86_PCREL): New test.
1019         * configure: Regenerate.
1020         * fficonfig.h.in: Regenerate.
1021         * src/x86/sysv.S [!FFI_NO_RAW_API]: Precalculate
1022         RAW_CLOSURE_CIF_OFFSET, RAW_CLOSURE_FUN_OFFSET,
1023         RAW_CLOSURE_USER_DATA_OFFSET for the Solaris 10/x86 assembler.
1024         (.eh_frame): Only use SYMBOL-. iff HAVE_AS_X86_PCREL.
1025         * src/x86/unix64.S (.Lstore_table): Move to .text section.
1026         (.Lload_table): Likewise.
1027         (.eh_frame): Only use SYMBOL-. iff HAVE_AS_X86_PCREL.
1028
1029 2008-12-18  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
1030
1031         * configure: Regenerate.
1032
1033 2008-11-21  Eric Botcazou  <ebotcazou@adacore.com>
1034
1035         * src/sparc/ffi.c (ffi_prep_cif_machdep): Add support for
1036         signed/unsigned int8/16 return values.
1037         * src/sparc/v8.S (ffi_call_v8): Likewise.
1038         (ffi_closure_v8): Likewise.
1039
1040 2008-09-26  Peter O'Gorman  <pogma@thewrittenword.com>
1041             Steve Ellcey  <sje@cup.hp.com>
1042
1043         * configure: Regenerate for new libtool.
1044         * Makefile.in: Ditto.
1045         * include/Makefile.in: Ditto.
1046         * aclocal.m4: Ditto.
1047
1048 2008-08-25  Andreas Tobler  <a.tobler@schweiz.org>
1049
1050         * src/powerpc/ffitarget.h (ffi_abi): Add FFI_LINUX and
1051         FFI_LINUX_SOFT_FLOAT to the POWERPC_FREEBSD enum.
1052         Add note about flag bits used for FFI_SYSV_TYPE_SMALL_STRUCT.
1053         Adjust copyright notice.
1054         * src/powerpc/ffi.c: Add two new flags to indicate if we have one
1055         register or two register to use for FFI_SYSV structs.
1056         (ffi_prep_cif_machdep): Pass the right register flag introduced above.
1057         (ffi_closure_helper_SYSV): Fix the return type for
1058         FFI_SYSV_TYPE_SMALL_STRUCT. Comment.
1059         Adjust copyright notice.
1060
1061 2008-07-16  Kaz Kojima  <kkojima@gcc.gnu.org>
1062
1063         * src/sh/ffi.c (ffi_prep_closure_loc): Turn INSN into an unsigned
1064         int.
1065
1066 2008-06-17  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
1067
1068         * configure: Regenerate.
1069         * include/Makefile.in: Regenerate.
1070         * testsuite/Makefile.in: Regenerate.
1071
1072 2008-06-07  Joseph Myers  <joseph@codesourcery.com>
1073
1074         * configure.ac (parisc*-*-linux*, powerpc-*-sysv*,
1075         powerpc-*-beos*): Remove.
1076         * configure: Regenerate.
1077
1078 2008-05-09  Julian Brown  <julian@codesourcery.com>
1079
1080         * Makefile.am (LTLDFLAGS): New.
1081         (libffi_la_LDFLAGS): Use above.
1082         * Makefile.in: Regenerate.
1083
1084 2008-04-18  Paolo Bonzini  <bonzini@gnu.org>
1085
1086         PR bootstrap/35457
1087         * aclocal.m4: Regenerate.
1088         * configure: Regenerate.
1089
1090 2008-03-26  Kaz Kojima  <kkojima@gcc.gnu.org>
1091
1092         * src/sh/sysv.S: Add .note.GNU-stack on Linux.
1093         * src/sh64/sysv.S: Likewise.
1094
1095 2008-03-26  Daniel Jacobowitz  <dan@debian.org>
1096
1097         * src/arm/sysv.S: Fix ARM comment marker.
1098
1099 2008-03-26  Jakub Jelinek  <jakub@redhat.com>
1100
1101         * src/alpha/osf.S: Add .note.GNU-stack on Linux.
1102         * src/s390/sysv.S: Likewise.
1103         * src/powerpc/ppc_closure.S: Likewise.
1104         * src/powerpc/sysv.S: Likewise.
1105         * src/x86/unix64.S: Likewise.
1106         * src/x86/sysv.S: Likewise.
1107         * src/sparc/v8.S: Likewise.
1108         * src/sparc/v9.S: Likewise.
1109         * src/m68k/sysv.S: Likewise.
1110         * src/arm/sysv.S: Likewise.
1111
1112 2008-03-16  Ralf Wildenhues  <Ralf.Wildenhues@gmx.de>
1113
1114         * aclocal.m4: Regenerate.
1115         * configure: Likewise.
1116         * Makefile.in: Likewise.
1117         * include/Makefile.in: Likewise.
1118         * testsuite/Makefile.in: Likewise.
1119
1120 2008-02-12  Bjoern Koenig  <bkoenig@alpha-tierchen.de>
1121             Andreas Tobler  <a.tobler@schweiz.org>
1122
1123         * configure.ac: Add amd64-*-freebsd* target.
1124         * configure: Regenerate.
1125
1126 2008-01-30  H.J. Lu  <hongjiu.lu@intel.com>
1127
1128         PR libffi/34612
1129         * src/x86/sysv.S (ffi_closure_SYSV): Pop 4 byte from stack when
1130         returning struct.
1131
1132         * testsuite/libffi.call/call.exp: Add "-O2 -fomit-frame-pointer"
1133         tests.
1134
1135 2008-01-24  David Edelsohn  <edelsohn@gnu.org>
1136
1137         * configure: Regenerate.
1138
1139 2008-01-06  Andreas Tobler  <a.tobler@schweiz.org>
1140
1141         * src/x86/ffi.c (ffi_prep_cif_machdep): Fix thinko.
1142
1143 2008-01-05  Andreas Tobler  <a.tobler@schweiz.org>
1144
1145         PR testsuite/32843
1146         * src/x86/ffi.c (ffi_prep_cif_machdep): Add code for
1147         signed/unsigned int8/16 for X86_DARWIN.
1148         Updated copyright info.
1149         Handle one and two byte structs with special cif->flags.
1150         * src/x86/ffitarget.h: Add special types for one and two byte structs.
1151         Updated copyright info.
1152         * src/x86/darwin.S (ffi_call_SYSV): Rewrite to use a jump table like
1153         sysv.S
1154         Remove code to pop args from the stack after call.
1155         Special-case signed/unsigned for int8/16, one and two byte structs.
1156         (ffi_closure_raw_SYSV): Handle FFI_TYPE_UINT8,
1157         FFI_TYPE_SINT8, FFI_TYPE_UINT16, FFI_TYPE_SINT16, FFI_TYPE_UINT32,
1158         FFI_TYPE_SINT32.
1159         Updated copyright info.
1160
1161 2007-12-08  David Daney  <ddaney@avtrex.com>
1162
1163         * src/mips/n32.S (ffi_call_N32):  Replace dadd with ADDU, dsub with
1164         SUBU, add with ADDU and use smaller code sequences.
1165
1166 2007-12-07  David Daney  <ddaney@avtrex.com>
1167
1168         * src/mips/ffi.c (ffi_prep_cif_machdep): Handle long double return
1169         type.
1170
1171 2007-12-06  David Daney  <ddaney@avtrex.com>
1172
1173         * include/ffi.h.in (FFI_SIZEOF_JAVA_RAW): Define if not already
1174         defined.
1175         (ffi_java_raw): New typedef.
1176         (ffi_java_raw_call, ffi_java_ptrarray_to_raw,
1177         ffi_java_raw_to_ptrarray): Change parameter types from ffi_raw to
1178         ffi_java_raw.
1179         (ffi_java_raw_closure) : Same.
1180         (ffi_prep_java_raw_closure, ffi_prep_java_raw_closure_loc): Change
1181         parameter types.
1182         * src/java_raw_api.c (ffi_java_raw_size):  Replace FFI_SIZEOF_ARG with
1183         FFI_SIZEOF_JAVA_RAW.
1184         (ffi_java_raw_to_ptrarray): Change type of raw to ffi_java_raw.
1185         Replace FFI_SIZEOF_ARG with FFI_SIZEOF_JAVA_RAW. Use
1186         sizeof(ffi_java_raw) for alignment calculations.
1187         (ffi_java_ptrarray_to_raw): Same.
1188         (ffi_java_rvalue_to_raw): Add special handling for FFI_TYPE_POINTER
1189         if FFI_SIZEOF_JAVA_RAW == 4.
1190         (ffi_java_raw_to_rvalue): Same.
1191         (ffi_java_raw_call): Change type of raw to ffi_java_raw.
1192         (ffi_java_translate_args): Same.
1193         (ffi_prep_java_raw_closure_loc, ffi_prep_java_raw_closure): Change
1194         parameter types.
1195         * src/mips/ffitarget.h (FFI_SIZEOF_JAVA_RAW): Define for N32 ABI.
1196
1197 2007-12-06  David Daney  <ddaney@avtrex.com>
1198
1199         * src/mips/n32.S (ffi_closure_N32): Use 64-bit add instruction on
1200         pointer values.
1201
1202 2007-12-01  Andreas Tobler  <a.tobler@schweiz.org>
1203
1204         PR libffi/31937
1205         * src/powerpc/ffitarget.h: Introduce new ABI FFI_LINUX_SOFT_FLOAT.
1206         Add local FFI_TYPE_UINT128 to handle soft-float long-double-128.
1207         * src/powerpc/ffi.c: Distinguish between __NO_FPRS__ and not and
1208         set the NUM_FPR_ARG_REGISTERS according to.
1209         Add support for potential soft-float support under hard-float
1210         architecture.
1211         (ffi_prep_args_SYSV): Set NUM_FPR_ARG_REGISTERS to 0 in case of
1212         FFI_LINUX_SOFT_FLOAT, handle float, doubles and long-doubles according
1213         to the FFI_LINUX_SOFT_FLOAT ABI.
1214         (ffi_prep_cif_machdep): Likewise.
1215         (ffi_closure_helper_SYSV): Likewise.
1216         * src/powerpc/ppc_closure.S: Make sure not to store float/double
1217         on archs where __NO_FPRS__ is true.
1218         Add FFI_TYPE_UINT128 support.
1219         * src/powerpc/sysv.S: Add support for soft-float long-double-128.
1220         Adjust copyright notice.
1221
1222 2007-11-25  Andreas Tobler  <a.tobler@schweiz.org>
1223
1224         * src/closures.c: Move defintion of MAYBE_UNUSED from here to ...
1225         * include/ffi_common.h: ... here.
1226         Update copyright.
1227
1228 2007-11-17  Andreas Tobler  <a.tobler@schweiz.org>
1229
1230         * src/powerpc/sysv.S: Load correct cr to compare if we have long double.
1231         * src/powerpc/linux64.S: Likewise.
1232         * src/powerpc/ffi.c: Add a comment to show which part goes into cr6.
1233         * testsuite/libffi.call/return_ldl.c: New test.
1234
1235 2007-09-04    <aph@redhat.com>
1236
1237         * src/arm/sysv.S (UNWIND): New.
1238         (Whole file): Conditionally compile unwinder directives.
1239         * src/arm/sysv.S: Add unwinder directives.
1240
1241         * src/arm/ffi.c (ffi_prep_args): Align structs by at least 4 bytes.
1242         Only treat r0 as a struct address if we're actually returning a
1243         struct by address.
1244         Only copy the bytes that are actually within a struct.
1245         (ffi_prep_cif_machdep): A Composite Type not larger than 4 bytes
1246         is returned in r0, not passed by address.
1247         (ffi_call): Allocate a word-sized temporary for the case where
1248         a composite is returned in r0.
1249         (ffi_prep_incoming_args_SYSV): Align as necessary.
1250
1251 2007-08-05  Steven Newbury  <s_j_newbury@yahoo.co.uk>
1252
1253         * src/arm/ffi.c (FFI_INIT_TRAMPOLINE): Use __clear_cache instead of
1254         directly using the sys_cacheflush syscall.
1255
1256 2007-07-27  Andrew Haley  <aph@redhat.com>
1257
1258         * src/arm/sysv.S (ffi_closure_SYSV): Add soft-float.
1259
1260 2007-09-03  Maciej W. Rozycki  <macro@linux-mips.org>
1261
1262         * Makefile.am: Unify MIPS_IRIX and MIPS_LINUX into MIPS.
1263         * configure.ac: Likewise.
1264         * Makefile.in: Regenerate.
1265         * include/Makefile.in: Likewise.
1266         * testsuite/Makefile.in: Likewise.
1267         * configure: Likewise.
1268
1269 2007-08-24  David Daney  <ddaney@avtrex.com>
1270
1271         * testsuite/libffi.call/return_sl.c: New test.
1272
1273 2007-08-10  David Daney  <ddaney@avtrex.com>
1274
1275         * testsuite/libffi.call/cls_multi_ushort.c,
1276         testsuite/libffi.call/cls_align_uint16.c,
1277         testsuite/libffi.call/nested_struct1.c,
1278         testsuite/libffi.call/nested_struct3.c,
1279         testsuite/libffi.call/cls_7_1_byte.c,
1280         testsuite/libffi.call/nested_struct5.c,
1281         testsuite/libffi.call/cls_double.c,
1282         testsuite/libffi.call/nested_struct7.c,
1283         testsuite/libffi.call/cls_sint.c,
1284         testsuite/libffi.call/nested_struct9.c,
1285         testsuite/libffi.call/cls_20byte1.c,
1286         testsuite/libffi.call/cls_multi_sshortchar.c,
1287         testsuite/libffi.call/cls_align_sint64.c,
1288         testsuite/libffi.call/cls_3byte2.c,
1289         testsuite/libffi.call/cls_multi_schar.c,
1290         testsuite/libffi.call/cls_multi_uchar.c,
1291         testsuite/libffi.call/cls_19byte.c,
1292         testsuite/libffi.call/cls_9byte1.c,
1293         testsuite/libffi.call/cls_align_float.c,
1294         testsuite/libffi.call/closure_fn1.c,
1295         testsuite/libffi.call/problem1.c,
1296         testsuite/libffi.call/closure_fn3.c,
1297         testsuite/libffi.call/cls_sshort.c,
1298         testsuite/libffi.call/closure_fn5.c,
1299         testsuite/libffi.call/cls_align_double.c,
1300         testsuite/libffi.call/nested_struct.c,
1301         testsuite/libffi.call/cls_2byte.c,
1302         testsuite/libffi.call/nested_struct10.c,
1303         testsuite/libffi.call/cls_4byte.c,
1304         testsuite/libffi.call/cls_6byte.c,
1305         testsuite/libffi.call/cls_8byte.c,
1306         testsuite/libffi.call/cls_multi_sshort.c,
1307         testsuite/libffi.call/cls_align_sint16.c,
1308         testsuite/libffi.call/cls_align_uint32.c,
1309         testsuite/libffi.call/cls_20byte.c,
1310         testsuite/libffi.call/cls_float.c,
1311         testsuite/libffi.call/nested_struct2.c,
1312         testsuite/libffi.call/cls_5_1_byte.c,
1313         testsuite/libffi.call/nested_struct4.c,
1314         testsuite/libffi.call/cls_24byte.c,
1315         testsuite/libffi.call/nested_struct6.c,
1316         testsuite/libffi.call/cls_64byte.c,
1317         testsuite/libffi.call/nested_struct8.c,
1318         testsuite/libffi.call/cls_uint.c,
1319         testsuite/libffi.call/cls_multi_ushortchar.c,
1320         testsuite/libffi.call/cls_schar.c,
1321         testsuite/libffi.call/cls_uchar.c,
1322         testsuite/libffi.call/cls_align_uint64.c,
1323         testsuite/libffi.call/cls_ulonglong.c,
1324         testsuite/libffi.call/cls_align_longdouble.c,
1325         testsuite/libffi.call/cls_1_1byte.c,
1326         testsuite/libffi.call/cls_12byte.c,
1327         testsuite/libffi.call/cls_3_1byte.c,
1328         testsuite/libffi.call/cls_3byte1.c,
1329         testsuite/libffi.call/cls_4_1byte.c,
1330         testsuite/libffi.call/cls_6_1_byte.c,
1331         testsuite/libffi.call/cls_16byte.c,
1332         testsuite/libffi.call/cls_18byte.c,
1333         testsuite/libffi.call/closure_fn0.c,
1334         testsuite/libffi.call/cls_9byte2.c,
1335         testsuite/libffi.call/closure_fn2.c,
1336         testsuite/libffi.call/closure_fn4.c,
1337         testsuite/libffi.call/cls_ushort.c,
1338         testsuite/libffi.call/closure_fn6.c,
1339         testsuite/libffi.call/cls_5byte.c,
1340         testsuite/libffi.call/cls_align_pointer.c,
1341         testsuite/libffi.call/cls_7byte.c,
1342         testsuite/libffi.call/cls_align_sint32.c,
1343         testsuite/libffi.special/unwindtest_ffi_call.cc,
1344         testsuite/libffi.special/unwindtest.cc: Remove xfail for mips64*-*-*.
1345
1346 2007-08-10  David Daney  <ddaney@avtrex.com>
1347
1348         PR libffi/28313
1349         * configure.ac: Don't treat mips64 as a special case.
1350         * Makefile.am (nodist_libffi_la_SOURCES): Add n32.S.
1351         * configure: Regenerate
1352         * Makefile.in: Ditto.
1353         * fficonfig.h.in: Ditto.
1354         * src/mips/ffitarget.h (REG_L, REG_S, SUBU, ADDU, SRL, LI): Indent.
1355         (LA, EH_FRAME_ALIGN, FDE_ADDR_BYTES): New preprocessor macros.
1356         (FFI_DEFAULT_ABI): Set for n64 case.
1357         (FFI_CLOSURES, FFI_TRAMPOLINE_SIZE): Define for n32 and n64 cases.
1358         * src/mips/n32.S (ffi_call_N32): Add debug macros and labels for FDE.
1359         (ffi_closure_N32): New function.
1360         (.eh_frame): New section
1361         * src/mips/o32.S: Clean up comments.
1362         (ffi_closure_O32): Pass ffi_closure parameter in $12.
1363         * src/mips/ffi.c: Use FFI_MIPS_N32 instead of
1364         _MIPS_SIM == _ABIN32 throughout.
1365         (FFI_MIPS_STOP_HERE): New, use in place of
1366         ffi_stop_here.
1367         (ffi_prep_args): Use unsigned long to hold pointer values.  Rewrite
1368         to support n32/n64 ABIs.
1369         (calc_n32_struct_flags): Rewrite.
1370         (calc_n32_return_struct_flags): Remove unused variable.  Reverse
1371         position of flag bits.
1372         (ffi_prep_cif_machdep): Rewrite n32 portion.
1373         (ffi_call): Enable for n64.  Add special handling for small structure
1374         return values.
1375         (ffi_prep_closure_loc): Add n32 and n64 support.
1376         (ffi_closure_mips_inner_O32): Add cast to silence warning.
1377         (copy_struct_N32, ffi_closure_mips_inner_N32): New functions.
1378
1379 2007-08-08  David Daney  <ddaney@avtrex.com>
1380
1381         * testsuite/libffi.call/ffitest.h (ffi_type_mylong): Remove definition.
1382         * testsuite/libffi.call/cls_align_uint16.c (main): Use correct type
1383         specifiers.
1384         * testsuite/libffi.call/nested_struct1.c (main): Ditto.
1385         * testsuite/libffi.call/cls_sint.c (main): Ditto.
1386         * testsuite/libffi.call/nested_struct9.c (main): Ditto.
1387         * testsuite/libffi.call/cls_20byte1.c (main): Ditto.
1388         * testsuite/libffi.call/cls_9byte1.c (main): Ditto.
1389         * testsuite/libffi.call/closure_fn1.c (main): Ditto.
1390         * testsuite/libffi.call/closure_fn3.c (main): Ditto.
1391         * testsuite/libffi.call/return_dbl2.c (main): Ditto.
1392         * testsuite/libffi.call/cls_sshort.c (main): Ditto.
1393         * testsuite/libffi.call/return_fl3.c (main): Ditto.
1394         * testsuite/libffi.call/closure_fn5.c (main): Ditto.
1395         * testsuite/libffi.call/nested_struct.c (main): Ditto.
1396         * testsuite/libffi.call/nested_struct10.c (main): Ditto.
1397         * testsuite/libffi.call/return_ll1.c (main): Ditto.
1398         * testsuite/libffi.call/cls_8byte.c (main): Ditto.
1399         * testsuite/libffi.call/cls_align_uint32.c (main): Ditto.
1400         * testsuite/libffi.call/cls_align_sint16.c (main): Ditto.
1401         * testsuite/libffi.call/cls_20byte.c (main): Ditto.
1402         * testsuite/libffi.call/nested_struct2.c (main): Ditto.
1403         * testsuite/libffi.call/cls_24byte.c (main): Ditto.
1404         * testsuite/libffi.call/nested_struct6.c (main): Ditto.
1405         * testsuite/libffi.call/cls_uint.c (main): Ditto.
1406         * testsuite/libffi.call/cls_12byte.c (main): Ditto.
1407         * testsuite/libffi.call/cls_16byte.c (main): Ditto.
1408         * testsuite/libffi.call/closure_fn0.c (main): Ditto.
1409         * testsuite/libffi.call/cls_9byte2.c (main): Ditto.
1410         * testsuite/libffi.call/closure_fn2.c (main): Ditto.
1411         * testsuite/libffi.call/return_dbl1.c (main): Ditto.
1412         * testsuite/libffi.call/closure_fn4.c (main): Ditto.
1413         * testsuite/libffi.call/closure_fn6.c (main): Ditto.
1414         * testsuite/libffi.call/cls_align_sint32.c (main): Ditto.
1415
1416 2007-08-07  Andrew Haley  <aph@redhat.com>
1417
1418         * src/x86/sysv.S (ffi_closure_raw_SYSV): Fix typo in previous
1419         checkin.
1420
1421 2007-08-06  Andrew Haley  <aph@redhat.com>
1422
1423         PR testsuite/32843
1424         * src/x86/sysv.S (ffi_closure_raw_SYSV): Handle FFI_TYPE_UINT8,
1425         FFI_TYPE_SINT8, FFI_TYPE_UINT16, FFI_TYPE_SINT16, FFI_TYPE_UINT32,
1426         FFI_TYPE_SINT32.
1427
1428 2007-08-02  David Daney  <ddaney@avtrex.com>
1429
1430         * testsuite/libffi.call/return_ul.c (main): Define return type as
1431         ffi_arg.  Use proper printf conversion specifier.
1432
1433 2007-07-30  Andrew Haley  <aph@redhat.com>
1434
1435         PR testsuite/32843
1436         * src/x86/ffi.c (ffi_prep_cif_machdep): in x86 case, add code for
1437         signed/unsigned int8/16.
1438         * src/x86/sysv.S (ffi_call_SYSV): Rewrite to:
1439         Use a jump table.
1440         Remove code to pop args from the stack after call.
1441         Special-case signed/unsigned int8/16.
1442         * testsuite/libffi.call/return_sc.c (main): Revert.
1443
1444 2007-07-26  Richard Guenther  <rguenther@suse.de>
1445
1446         PR testsuite/32843
1447         * testsuite/libffi.call/return_sc.c (main): Verify call
1448         result as signed char, not ffi_arg.
1449
1450 2007-07-16  Rainer Orth  <ro@TechFak.Uni-Bielefeld.DE>
1451
1452         * configure.ac (i?86-*-solaris2.1[0-9]): Set TARGET to X86_64.
1453         * configure: Regenerate.
1454
1455 2007-07-11  David Daney  <ddaney@avtrex.com>
1456
1457         * src/mips/ffi.c: Don't include sys/cachectl.h.
1458         (ffi_prep_closure_loc): Use __builtin___clear_cache() instead of
1459         cacheflush().
1460
1461 2007-05-18  Aurelien Jarno  <aurelien@aurel32.net>
1462
1463         * src/arm/ffi.c (ffi_prep_closure_loc): Renamed and ajusted
1464         from (ffi_prep_closure): ... this.
1465         (FFI_INIT_TRAMPOLINE): Adjust.
1466
1467 2005-12-31  Phil Blundell  <pb@reciva.com>
1468
1469         * src/arm/ffi.c (ffi_prep_incoming_args_SYSV,
1470         ffi_closure_SYSV_inner, ffi_prep_closure): New, add closure support.
1471         * src/arm/sysv.S(ffi_closure_SYSV): Likewise.
1472         * src/arm/ffitarget.h (FFI_TRAMPOLINE_SIZE): Likewise.
1473         (FFI_CLOSURES): Enable closure support.
1474
1475 2007-07-03  Andrew Haley  <aph@hedges.billgatliff.com>
1476
1477         * testsuite/libffi.call/cls_multi_ushort.c,
1478         testsuite/libffi.call/cls_align_uint16.c,
1479         testsuite/libffi.call/nested_struct1.c,
1480         testsuite/libffi.call/nested_struct3.c,
1481         testsuite/libffi.call/cls_7_1_byte.c,
1482         testsuite/libffi.call/cls_double.c,
1483         testsuite/libffi.call/nested_struct5.c,
1484         testsuite/libffi.call/nested_struct7.c,
1485         testsuite/libffi.call/cls_sint.c,
1486         testsuite/libffi.call/nested_struct9.c,
1487         testsuite/libffi.call/cls_20byte1.c,
1488         testsuite/libffi.call/cls_multi_sshortchar.c,
1489         testsuite/libffi.call/cls_align_sint64.c,
1490         testsuite/libffi.call/cls_3byte2.c,
1491         testsuite/libffi.call/cls_multi_schar.c,
1492         testsuite/libffi.call/cls_multi_uchar.c,
1493         testsuite/libffi.call/cls_19byte.c,
1494         testsuite/libffi.call/cls_9byte1.c,
1495         testsuite/libffi.call/cls_align_float.c,
1496         testsuite/libffi.call/closure_fn1.c,
1497         testsuite/libffi.call/problem1.c,
1498         testsuite/libffi.call/closure_fn3.c,
1499         testsuite/libffi.call/cls_sshort.c,
1500         testsuite/libffi.call/closure_fn5.c,
1501         testsuite/libffi.call/cls_align_double.c,
1502         testsuite/libffi.call/cls_2byte.c,
1503         testsuite/libffi.call/nested_struct.c,
1504         testsuite/libffi.call/nested_struct10.c,
1505         testsuite/libffi.call/cls_4byte.c,
1506         testsuite/libffi.call/cls_6byte.c,
1507         testsuite/libffi.call/cls_8byte.c,
1508         testsuite/libffi.call/cls_multi_sshort.c,
1509         testsuite/libffi.call/cls_align_uint32.c,
1510         testsuite/libffi.call/cls_align_sint16.c,
1511         testsuite/libffi.call/cls_float.c,
1512         testsuite/libffi.call/cls_20byte.c,
1513         testsuite/libffi.call/cls_5_1_byte.c,
1514         testsuite/libffi.call/nested_struct2.c,
1515         testsuite/libffi.call/cls_24byte.c,
1516         testsuite/libffi.call/nested_struct4.c,
1517         testsuite/libffi.call/nested_struct6.c,
1518         testsuite/libffi.call/cls_64byte.c,
1519         testsuite/libffi.call/nested_struct8.c,
1520         testsuite/libffi.call/cls_uint.c,
1521         testsuite/libffi.call/cls_multi_ushortchar.c,
1522         testsuite/libffi.call/cls_schar.c,
1523         testsuite/libffi.call/cls_uchar.c,
1524         testsuite/libffi.call/cls_align_uint64.c,
1525         testsuite/libffi.call/cls_ulonglong.c,
1526         testsuite/libffi.call/cls_align_longdouble.c,
1527         testsuite/libffi.call/cls_1_1byte.c,
1528         testsuite/libffi.call/cls_12byte.c,
1529         testsuite/libffi.call/cls_3_1byte.c,
1530         testsuite/libffi.call/cls_3byte1.c,
1531         testsuite/libffi.call/cls_4_1byte.c,
1532         testsuite/libffi.call/cls_6_1_byte.c,
1533         testsuite/libffi.call/cls_16byte.c,
1534         testsuite/libffi.call/cls_18byte.c,
1535         testsuite/libffi.call/closure_fn0.c,
1536         testsuite/libffi.call/cls_9byte2.c,
1537         testsuite/libffi.call/closure_fn2.c,
1538         testsuite/libffi.call/closure_fn4.c,
1539         testsuite/libffi.call/cls_ushort.c,
1540         testsuite/libffi.call/closure_fn6.c,
1541         testsuite/libffi.call/cls_5byte.c,
1542         testsuite/libffi.call/cls_align_pointer.c,
1543         testsuite/libffi.call/cls_7byte.c,
1544         testsuite/libffi.call/cls_align_sint32.c,
1545         testsuite/libffi.special/unwindtest_ffi_call.cc,
1546         testsuite/libffi.special/unwindtest.cc: Enable for ARM.
1547
1548 2007-07-05  H.J. Lu  <hongjiu.lu@intel.com>
1549
1550         * aclocal.m4: Regenerated.
1551
1552 2007-06-02  Paolo Bonzini  <bonzini@gnu.org>
1553
1554         * configure: Regenerate.
1555
1556 2007-05-23  Steve Ellcey  <sje@cup.hp.com>
1557
1558         * Makefile.in: Regenerate.
1559         * configure: Regenerate.
1560         * aclocal.m4: Regenerate.
1561         * include/Makefile.in: Regenerate.
1562         * testsuite/Makefile.in: Regenerate.
1563
1564 2007-05-10  Roman Zippel <zippel@linux-m68k.org>
1565
1566         * src/m68k/ffi.c (ffi_prep_incoming_args_SYSV,
1567         ffi_closure_SYSV_inner,ffi_prep_closure): New, add closure support.
1568         * src/m68k/sysv.S(ffi_closure_SYSV,ffi_closure_struct_SYSV): Likewise.
1569         * src/m68k/ffitarget.h (FFI_TRAMPOLINE_SIZE): Likewise.
1570         (FFI_CLOSURES): Enable closure support.
1571
1572 2007-05-10  Roman Zippel <zippel@linux-m68k.org>
1573
1574         * configure.ac (HAVE_AS_CFI_PSEUDO_OP): New test.
1575         * configure: Regenerate.
1576         * fficonfig.h.in: Regenerate.
1577         * src/m68k/sysv.S (CFI_STARTPROC,CFI_ENDPROC,
1578         CFI_OFFSET,CFI_DEF_CFA): New macros.
1579         (ffi_call_SYSV): Add callframe annotation.
1580
1581 2007-05-10  Roman Zippel <zippel@linux-m68k.org>
1582
1583         * src/m68k/ffi.c (ffi_prep_args,ffi_prep_cif_machdep): Fix
1584         numerous test suite failures.
1585         * src/m68k/sysv.S (ffi_call_SYSV): Likewise.
1586
1587 2007-04-11  Paolo Bonzini  <bonzini@gnu.org>
1588
1589         * Makefile.am (EXTRA_DIST): Bring up to date.
1590         * Makefile.in: Regenerate.
1591         * src/frv/eabi.S: Remove RCS keyword.
1592
1593 2007-04-06  Richard Henderson  <rth@redhat.com>
1594
1595         * configure.ac: Tidy target case.
1596         (HAVE_LONG_DOUBLE): Allow the target to override.
1597         * configure: Regenerate.
1598         * include/ffi.h.in: Don't define ffi_type_foo if
1599         LIBFFI_HIDE_BASIC_TYPES is defined.
1600         (ffi_type_longdouble): If not HAVE_LONG_DOUBLE, define
1601         to ffi_type_double.
1602         * types.c (LIBFFI_HIDE_BASIC_TYPES): Define.
1603         (FFI_TYPEDEF, ffi_type_void): Mark the data const.
1604         (ffi_type_longdouble): Special case for Alpha.  Don't define
1605         if long double == double.
1606
1607         * src/alpha/ffi.c (FFI_TYPE_LONGDOUBLE): Assert unique value.
1608         (ffi_prep_cif_machdep): Handle it as the 128-bit type.
1609         (ffi_call, ffi_closure_osf_inner): Likewise.
1610         (ffi_closure_osf_inner): Likewise.  Mark hidden.
1611         (ffi_call_osf, ffi_closure_osf): Mark hidden.
1612         * src/alpha/ffitarget.h (FFI_LAST_ABI): Tidy definition.
1613         * src/alpha/osf.S (ffi_call_osf, ffi_closure_osf): Mark hidden.
1614         (load_table): Handle 128-bit long double.
1615
1616         * testsuite/libffi.call/float4.c: Add -mieee for alpha.
1617
1618 2007-04-06  Tom Tromey  <tromey@redhat.com>
1619
1620         PR libffi/31491:
1621         * README: Fixed bug in example.
1622
1623 2007-04-03  Jakub Jelinek  <jakub@redhat.com>
1624
1625         * src/closures.c: Include sys/statfs.h.
1626         (_GNU_SOURCE): Define on Linux.
1627         (FFI_MMAP_EXEC_SELINUX): Define.
1628         (selinux_enabled): New variable.
1629         (selinux_enabled_check): New function.
1630         (is_selinux_enabled): Define.
1631         (dlmmap): Use it.
1632
1633 2007-03-24  Uros Bizjak  <ubizjak@gmail.com>
1634
1635         * testsuite/libffi.call/return_fl2.c (return_fl): Mark as static.
1636         Use 'volatile float sum' to create sum of floats to avoid false
1637         negative due to excess precision on ix86 targets.
1638         (main): Ditto.
1639
1640 2007-03-08  Alexandre Oliva  <aoliva@redhat.com>
1641
1642         * src/powerpc/ffi.c (flush_icache): Fix left-over from previous
1643         patch.
1644         (ffi_prep_closure_loc): Remove unneeded casts.  Add needed ones.
1645
1646 2007-03-07  Alexandre Oliva  <aoliva@redhat.com>
1647
1648         * include/ffi.h.in (ffi_closure_alloc, ffi_closure_free): New.
1649         (ffi_prep_closure_loc): New.
1650         (ffi_prep_raw_closure_loc): New.
1651         (ffi_prep_java_raw_closure_loc): New.
1652         * src/closures.c: New file.
1653         * src/dlmalloc.c [FFI_MMAP_EXEC_WRIT] (struct malloc_segment):
1654         Replace sflags with exec_offset.
1655         [FFI_MMAP_EXEC_WRIT] (mmap_exec_offset, add_segment_exec_offset,
1656         sub_segment_exec_offset): New macros.
1657         (get_segment_flags, set_segment_flags, check_segment_merge): New
1658         macros.
1659         (is_mmapped_segment, is_extern_segment): Use get_segment_flags.
1660         (add_segment, sys_alloc, create_mspace, create_mspace_with_base,
1661         destroy_mspace): Use new macros.
1662         (sys_alloc): Silence warning.
1663         * Makefile.am (libffi_la_SOURCES): Add src/closures.c.
1664         * Makefile.in: Rebuilt.
1665         * src/prep_cif [FFI_CLOSURES] (ffi_prep_closure): Implement in
1666         terms of ffi_prep_closure_loc.
1667         * src/raw_api.c (ffi_prep_raw_closure_loc): Renamed and adjusted
1668         from...
1669         (ffi_prep_raw_closure): ... this.  Re-implement in terms of the
1670         renamed version.
1671         * src/java_raw_api (ffi_prep_java_raw_closure_loc): Renamed and
1672         adjusted from...
1673         (ffi_prep_java_raw_closure): ... this.  Re-implement in terms of
1674         the renamed version.
1675         * src/alpha/ffi.c (ffi_prep_closure_loc): Renamed from
1676         (ffi_prep_closure): ... this.
1677         * src/pa/ffi.c: Likewise.
1678         * src/cris/ffi.c: Likewise.  Adjust.
1679         * src/frv/ffi.c: Likewise.
1680         * src/ia64/ffi.c: Likewise.
1681         * src/mips/ffi.c: Likewise.
1682         * src/powerpc/ffi_darwin.c: Likewise.
1683         * src/s390/ffi.c: Likewise.
1684         * src/sh/ffi.c: Likewise.
1685         * src/sh64/ffi.c: Likewise.
1686         * src/sparc/ffi.c: Likewise.
1687         * src/x86/ffi64.c: Likewise.
1688         * src/x86/ffi.c: Likewise.
1689         (FFI_INIT_TRAMPOLINE): Adjust.
1690         (ffi_prep_raw_closure_loc): Renamed and adjusted from...
1691         (ffi_prep_raw_closure): ... this.
1692         * src/powerpc/ffi.c (ffi_prep_closure_loc): Renamed from
1693         (ffi_prep_closure): ... this.
1694         (flush_icache): Adjust.
1695
1696 2007-03-07  Alexandre Oliva  <aoliva@redhat.com>
1697
1698         * src/dlmalloc.c: New file, imported version 2.8.3 of Doug
1699         Lea's malloc.
1700
1701 2007-03-01  Brooks Moses  <brooks.moses@codesourcery.com>
1702
1703         * Makefile.am: Add dummy install-pdf target.
1704         * Makefile.in: Regenerate
1705
1706 2007-02-13  Andreas Krebbel  <krebbel1@de.ibm.com>
1707
1708         * src/s390/ffi.c (ffi_prep_args, ffi_prep_cif_machdep,
1709         ffi_closure_helper_SYSV): Add long double handling.
1710
1711 2007-02-02  Jakub Jelinek  <jakub@redhat.com>
1712
1713         * src/powerpc/linux64.S (ffi_call_LINUX64): Move restore of r2
1714         immediately after bctrl instruction.
1715
1716 2007-01-18  Alexandre Oliva  <aoliva@redhat.com>
1717
1718         * Makefile.am (all-recursive, install-recursive,
1719         mostlyclean-recursive, clean-recursive, distclean-recursive,
1720         maintainer-clean-recursive): Add missing targets.
1721         * Makefile.in: Rebuilt.
1722
1723 2006-12-14  Andreas Tobler  <a.tobler@schweiz.org>
1724
1725         * configure.ac: Add TARGET for x86_64-*-darwin*.
1726         * Makefile.am (nodist_libffi_la_SOURCES): Add rules for 64-bit sources
1727         for X86_DARWIN.
1728         * src/x86/ffitarget.h: Set trampoline size for x86_64-*-darwin*.
1729         * src/x86/darwin64.S: New file for x86_64-*-darwin* support.
1730         * configure: Regenerate.
1731         * Makefile.in: Regenerate.
1732         * include/Makefile.in: Regenerate.
1733         * testsuite/Makefile.in: Regenerate.
1734         * testsuite/libffi.special/unwindtest_ffi_call.cc: New test case for
1735         ffi_call only.
1736
1737 2006-12-13  Andreas Tobler <a.tobler@schweiz.org>
1738
1739         * aclocal.m4: Regenerate with aclocal -I .. as written in the
1740         Makefile.am.
1741
1742 2006-10-31  Geoffrey Keating  <geoffk@apple.com>
1743
1744         * src/powerpc/ffi_darwin.c (darwin_adjust_aggregate_sizes): New.
1745         (ffi_prep_cif_machdep): Call darwin_adjust_aggregate_sizes for
1746         Darwin.
1747         * testsuite/libffi.call/nested_struct4.c: Remove Darwin XFAIL.
1748         * testsuite/libffi.call/nested_struct6.c: Remove Darwin XFAIL.
1749
1750 2006-10-10  Paolo Bonzini  <bonzini@gnu.org>
1751             Sandro Tolaini  <tolaini@libero.it>
1752
1753         * configure.ac [i*86-*-darwin*]: Set X86_DARWIN symbol and
1754         conditional.
1755         * configure: Regenerated.
1756         * Makefile.am (nodist_libffi_la_SOURCES) [X86_DARWIN]: New case.
1757         (EXTRA_DIST): Add src/x86/darwin.S.
1758         * Makefile.in: Regenerated.
1759         * include/Makefile.in: Regenerated.
1760         * testsuite/Makefile.in: Regenerated.
1761
1762         * src/x86/ffi.c (ffi_prep_cif_machdep) [X86_DARWIN]: Treat like
1763         X86_WIN32, and additionally align stack to 16 bytes.
1764         * src/x86/darwin.S: New, based on sysv.S.
1765         * src/prep_cif.c (ffi_prep_cif) [X86_DARWIN]: Align > 8-byte structs.
1766
1767 2006-09-12  David Daney  <ddaney@avtrex.com>
1768
1769         PR libffi/23935
1770         * include/Makefile.am: Install both ffi.h and ffitarget.h in
1771         $(libdir)/gcc/$(target_alias)/$(gcc_version)/include.
1772         * aclocal.m4: Regenerated for automake 1.9.6.
1773         * Makefile.in: Regenerated.
1774         * include/Makefile.in: Regenerated.
1775         * testsuite/Makefile.in: Regenerated.
1776
1777 2006-08-17  Andreas Tobler  <a.tobler@schweiz.ch>
1778
1779         * include/ffi_common.h (struct): Revert accidental commit.
1780
1781 2006-08-15  Andreas Tobler  <a.tobler@schweiz.ch>
1782
1783         * include/ffi_common.h: Remove lint directives.
1784         * include/ffi.h.in: Likewise.
1785
1786 2006-07-25  Torsten Schoenfeld  <kaffeetisch@gmx.de>
1787
1788         * include/ffi.h.in (ffi_type_ulong, ffi_type_slong): Define correctly
1789         for 32-bit architectures.
1790         * testsuite/libffi.call/return_ul.c: New test case.
1791
1792 2006-07-19  David Daney  <ddaney@avtrex.com>
1793
1794         * testsuite/libffi.call/closure_fn6.c: Remove xfail for mips,
1795         xfail remains for mips64.
1796
1797 2006-05-23  Carlos O'Donell  <carlos@codesourcery.com>
1798
1799         * Makefile.am: Add install-html target. Add install-html to .PHONY
1800         * Makefile.in: Regenerate.
1801         * aclocal.m4: Regenerate.
1802         * include/Makefile.in: Regenerate.
1803         * testsuite/Makefile.in: Regenerate.
1804
1805 2006-05-18  John David Anglin  <dave.anglin@nrc-cnrc.gc.ca>
1806
1807         * pa/ffi.c (ffi_prep_args_pa32): Load floating point arguments from
1808         stack slot.
1809
1810 2006-04-22  Andreas Tobler  <a.tobler@schweiz.ch>
1811
1812         * README: Remove notice about 'Crazy Comments'.
1813         * src/debug.c: Remove lint directives. Cleanup white spaces.
1814         * src/java_raw_api.c: Likewise.
1815         * src/prep_cif.c: Likewise.
1816         * src/raw_api.c: Likewise.
1817         * src/ffitest.c: Delete. No longer needed, all test cases migrated
1818         to the testsuite.
1819         * src/arm/ffi.c: Remove lint directives.
1820         * src/m32r/ffi.c: Likewise.
1821         * src/pa/ffi.c: Likewise.
1822         * src/powerpc/ffi.c: Likewise.
1823         * src/powerpc/ffi_darwin.c: Likewise.
1824         * src/sh/ffi.c: Likewise.
1825         * src/sh64/ffi.c: Likewise.
1826         * src/x86/ffi.c: Likewise.
1827         * testsuite/libffi.call/float2.c: Likewise.
1828         * testsuite/libffi.call/promotion.c: Likewise.
1829         * testsuite/libffi.call/struct1.c: Likewise.
1830
1831 2006-04-13  Andreas Tobler  <a.tobler@schweiz.ch>
1832
1833         * src/pa/hpux32.S: Correct unwind offset calculation for
1834         ffi_closure_pa32.
1835         * src/pa/linux.S: Likewise.
1836
1837 2006-04-12  James E Wilson  <wilson@specifix.com>
1838
1839         PR libgcj/26483
1840         * src/ia64/ffi.c (stf_spill, ldf_fill): Rewrite as macros.
1841         (hfa_type_load): Call stf_spill.
1842         (hfa_type_store): Call ldf_fill.
1843         (ffi_call): Adjust calls to above routines.  Add local temps for
1844         macro result.
1845
1846 2006-04-10  Matthias Klose  <doko@debian.org>
1847
1848         * testsuite/lib/libffi-dg.exp (libffi-init): Recognize multilib
1849         directory names containing underscores.
1850
1851 2006-04-07  James E Wilson  <wilson@specifix.com>
1852
1853         * testsuite/libffi.call/float4.c: New testcase.
1854
1855 2006-04-05  John David Anglin  <dave.anglin@nrc-cnrc.gc.ca>
1856             Andreas Tobler  <a.tobler@schweiz.ch>
1857
1858         * Makefile.am: Add PA_HPUX port.
1859         * Makefile.in: Regenerate.
1860         * include/Makefile.in: Likewise.
1861         * testsuite/Makefile.in: Likewise.
1862         * configure.ac: Add PA_HPUX rules.
1863         * configure: Regenerate.
1864         * src/pa/ffitarget.h: Rename linux target to PA_LINUX.
1865         Add PA_HPUX and PA64_HPUX.
1866         Rename FFI_LINUX ABI to FFI_PA32 ABI.
1867         (FFI_TRAMPOLINE_SIZE): Define for 32-bit HP-UX targets.
1868         (FFI_TYPE_SMALL_STRUCT2): Define.
1869         (FFI_TYPE_SMALL_STRUCT4): Likewise.
1870         (FFI_TYPE_SMALL_STRUCT8): Likewise.
1871         (FFI_TYPE_SMALL_STRUCT3): Redefine.
1872         (FFI_TYPE_SMALL_STRUCT5): Likewise.
1873         (FFI_TYPE_SMALL_STRUCT6): Likewise.
1874         (FFI_TYPE_SMALL_STRUCT7): Likewise.
1875         * src/pa/ffi.c (ROUND_DOWN): Delete.
1876         (fldw, fstw, fldd, fstd): Use '__asm__'.
1877         (ffi_struct_type): Add support for FFI_TYPE_SMALL_STRUCT2,
1878         FFI_TYPE_SMALL_STRUCT4 and FFI_TYPE_SMALL_STRUCT8.
1879         (ffi_prep_args_LINUX): Rename to ffi_prep_args_pa32. Update comment.
1880         Simplify incrementing of stack slot variable. Change type of local
1881         'n' to unsigned int.
1882         (ffi_size_stack_LINUX): Rename to ffi_size_stack_pa32. Handle long
1883         double on PA_HPUX.
1884         (ffi_prep_cif_machdep): Likewise.
1885         (ffi_call): Likewise.
1886         (ffi_closure_inner_LINUX): Rename to ffi_closure_inner_pa32. Change
1887         return type to ffi_status. Simplify incrementing of stack slot
1888         variable. Only copy floating point argument registers when PA_LINUX
1889         is true. Reformat debug statement.
1890         Add support for FFI_TYPE_SMALL_STRUCT2, FFI_TYPE_SMALL_STRUCT4 and
1891         FFI_TYPE_SMALL_STRUCT8.
1892         (ffi_closure_LINUX): Rename to ffi_closure_pa32. Add 'extern' to
1893         declaration.
1894         (ffi_prep_closure): Make linux trampoline conditional on PA_LINUX.
1895         Add nops to cache flush.  Add trampoline for PA_HPUX.
1896         * src/pa/hpux32.S: New file.
1897         * src/pa/linux.S (ffi_call_LINUX): Rename to ffi_call_pa32. Rename
1898         ffi_prep_args_LINUX to ffi_prep_args_pa32.
1899         Localize labels. Add support for 2, 4 and 8-byte small structs. Handle
1900         unaligned destinations in 3, 5, 6 and 7-byte small structs. Order
1901         argument type checks so that common argument types appear first.
1902         (ffi_closure_LINUX): Rename to ffi_closure_pa32. Rename
1903         ffi_closure_inner_LINUX to ffi_closure_inner_pa32.
1904
1905 2006-03-24  Alan Modra  <amodra@bigpond.net.au>
1906
1907         * src/powerpc/ffitarget.h (enum ffi_abi): Add FFI_LINUX.  Default
1908         for 32-bit using IBM extended double format.  Fix FFI_LAST_ABI.
1909         * src/powerpc/ffi.c (ffi_prep_args_SYSV): Handle linux variant of
1910         FFI_TYPE_LONGDOUBLE.
1911         (ffi_prep_args64): Assert using IBM extended double.
1912         (ffi_prep_cif_machdep): Don't munge FFI_TYPE_LONGDOUBLE type.
1913         Handle FFI_LINUX FFI_TYPE_LONGDOUBLE return and args.
1914         (ffi_call): Handle FFI_LINUX.
1915         (ffi_closure_helper_SYSV): Non FFI_LINUX long double return needs
1916         gpr3 return pointer as for struct return.  Handle FFI_LINUX
1917         FFI_TYPE_LONGDOUBLE return and args.  Don't increment "nf"
1918         unnecessarily.
1919         * src/powerpc/ppc_closure.S (ffi_closure_SYSV): Load both f1 and f2
1920         for FFI_TYPE_LONGDOUBLE.  Move epilogue insns into case table.
1921         Don't use r6 as pointer to results, instead use sp offset.  Don't
1922         make a special call to load lr with case table address, instead
1923         use offset from previous call.
1924         * src/powerpc/sysv.S (ffi_call_SYSV): Save long double return.
1925         * src/powerpc/linux64.S (ffi_call_LINUX64): Simplify long double
1926         return.
1927
1928 2006-03-15  Kaz Kojima  <kkojima@gcc.gnu.org>
1929
1930         * src/sh64/ffi.c (ffi_prep_cif_machdep): Handle float arguments
1931         passed with FP registers correctly.
1932         (ffi_closure_helper_SYSV): Likewise.
1933         * src/sh64/sysv.S: Likewise.
1934
1935 2006-03-01  Andreas Tobler  <a.tobler@schweiz.ch>
1936
1937         * testsuite/libffi.special/unwindtest.cc (closure_test_fn): Mark cif,
1938         args and userdata unused.
1939         (closure_test_fn1): Mark cif and userdata unused.
1940         (main): Remove unused res.
1941
1942 2006-02-28  Andreas Tobler  <a.tobler@schweiz.ch>
1943
1944         * testsuite/libffi.call/call.exp: Adjust FSF address. Add test runs for
1945         -O2, -O3, -Os and the warning flags -W -Wall.
1946         * testsuite/libffi.special/special.exp: Likewise.
1947         * testsuite/libffi.call/ffitest.h: Add an __UNUSED__ macro to mark
1948         unused parameter unused for gcc or else do nothing.
1949         * testsuite/libffi.special/ffitestcxx.h: Likewise.
1950         * testsuite/libffi.call/cls_12byte.c (cls_struct_12byte_gn): Mark cif
1951         and userdata unused.
1952         * testsuite/libffi.call/cls_16byte.c (cls_struct_16byte_gn): Likewise.
1953         * testsuite/libffi.call/cls_18byte.c (cls_struct_18byte_gn): Likewise.
1954         * testsuite/libffi.call/cls_19byte.c (cls_struct_19byte_gn): Likewise.
1955         * testsuite/libffi.call/cls_1_1byte.c (cls_struct_1_1byte_gn): Likewise.
1956         * testsuite/libffi.call/cls_20byte.c (cls_struct_20byte_gn): Likewise.
1957         * testsuite/libffi.call/cls_20byte1.c (cls_struct_20byte_gn): Likewise.
1958         * testsuite/libffi.call/cls_24byte.c (cls_struct_24byte_gn): Likewise.
1959         * testsuite/libffi.call/cls_2byte.c (cls_struct_2byte_gn): Likewise.
1960         * testsuite/libffi.call/cls_3_1byte.c (cls_struct_3_1byte_gn): Likewise.
1961         * testsuite/libffi.call/cls_3byte1.c (cls_struct_3byte_gn): Likewise.
1962         * testsuite/libffi.call/cls_3byte2.c (cls_struct_3byte_gn1): Likewise.
1963         * testsuite/libffi.call/cls_4_1byte.c (cls_struct_4_1byte_gn): Likewise.
1964         * testsuite/libffi.call/cls_4byte.c (cls_struct_4byte_gn): Likewise.
1965         * testsuite/libffi.call/cls_5_1_byte.c (cls_struct_5byte_gn): Likewise.
1966         * testsuite/libffi.call/cls_5byte.c (cls_struct_5byte_gn): Likewise.
1967         * testsuite/libffi.call/cls_64byte.c (cls_struct_64byte_gn): Likewise.
1968         * testsuite/libffi.call/cls_6_1_byte.c (cls_struct_6byte_gn): Likewise.
1969         * testsuite/libffi.call/cls_6byte.c (cls_struct_6byte_gn): Likewise.
1970         * testsuite/libffi.call/cls_7_1_byte.c (cls_struct_7byte_gn): Likewise.
1971         * testsuite/libffi.call/cls_7byte.c (cls_struct_7byte_gn): Likewise.
1972         * testsuite/libffi.call/cls_8byte.c (cls_struct_8byte_gn): Likewise.
1973         * testsuite/libffi.call/cls_9byte1.c (cls_struct_9byte_gn): Likewise.
1974         * testsuite/libffi.call/cls_9byte2.c (cls_struct_9byte_gn): Likewise.
1975         * testsuite/libffi.call/cls_align_double.c (cls_struct_align_gn):
1976         Likewise.
1977         * testsuite/libffi.call/cls_align_float.c (cls_struct_align_gn):
1978         Likewise.
1979         * testsuite/libffi.call/cls_align_longdouble.c (cls_struct_align_gn):
1980         Likewise.
1981         * testsuite/libffi.call/cls_align_pointer.c (cls_struct_align_fn): Cast
1982         void* to avoid compiler warning.
1983         (main): Likewise.
1984         (cls_struct_align_gn): Mark cif and userdata unused.
1985         * testsuite/libffi.call/cls_align_sint16.c (cls_struct_align_gn):
1986         Likewise.
1987         * testsuite/libffi.call/cls_align_sint32.c (cls_struct_align_gn):
1988         Likewise.
1989         * testsuite/libffi.call/cls_align_sint64.c (cls_struct_align_gn):
1990         Likewise.
1991         * testsuite/libffi.call/cls_align_uint16.c (cls_struct_align_gn):
1992         Likewise.
1993         * testsuite/libffi.call/cls_align_uint32.c (cls_struct_align_gn):
1994         Likewise.
1995         * testsuite/libffi.call/cls_double.c (cls_ret_double_fn): Likewise.
1996         * testsuite/libffi.call/cls_float.c (cls_ret_float_fn): Likewise.
1997         * testsuite/libffi.call/cls_multi_schar.c (test_func_gn): Mark cif and
1998         data unused.
1999         (main): Cast res_call to silence gcc.
2000         * testsuite/libffi.call/cls_multi_sshort.c (test_func_gn): Mark cif and
2001         data unused.
2002         (main): Cast res_call to silence gcc.
2003         * testsuite/libffi.call/cls_multi_sshortchar.c (test_func_gn): Mark cif
2004         and data unused.
2005         (main): Cast res_call to silence gcc.
2006         * testsuite/libffi.call/cls_multi_uchar.c (test_func_gn): Mark cif and
2007         data unused.
2008         (main): Cast res_call to silence gcc.
2009         * testsuite/libffi.call/cls_multi_ushort.c (test_func_gn): Mark cif and
2010         data unused.
2011         (main): Cast res_call to silence gcc.
2012         * testsuite/libffi.call/cls_multi_ushortchar.c (test_func_gn): Mark cif
2013         and data unused.
2014         (main): Cast res_call to silence gcc.
2015         * testsuite/libffi.call/cls_schar.c (cls_ret_schar_fn): Mark cif and
2016         userdata unused.
2017         (cls_ret_schar_fn): Cast printf parameter to silence gcc.
2018         * testsuite/libffi.call/cls_sint.c (cls_ret_sint_fn): Mark cif and
2019         userdata unused.
2020         (cls_ret_sint_fn): Cast printf parameter to silence gcc.
2021         * testsuite/libffi.call/cls_sshort.c (cls_ret_sshort_fn): Mark cif and
2022         userdata unused.
2023         (cls_ret_sshort_fn): Cast printf parameter to silence gcc.
2024         * testsuite/libffi.call/cls_uchar.c (cls_ret_uchar_fn):  Mark cif and
2025         userdata unused.
2026         (cls_ret_uchar_fn): Cast printf parameter to silence gcc.
2027         * testsuite/libffi.call/cls_uint.c (cls_ret_uint_fn): Mark cif and
2028         userdata unused.
2029         (cls_ret_uint_fn): Cast printf parameter to silence gcc.
2030         * testsuite/libffi.call/cls_ulonglong.c (cls_ret_ulonglong_fn): Mark cif
2031         and userdata unused.
2032         * testsuite/libffi.call/cls_ushort.c (cls_ret_ushort_fn): Mark cif and
2033         userdata unused.
2034         (cls_ret_ushort_fn): Cast printf parameter to silence gcc.
2035         * testsuite/libffi.call/float.c (floating): Remove unused parameter e.
2036         * testsuite/libffi.call/float1.c (main): Remove unused variable i.
2037         Cleanup white spaces.
2038         * testsuite/libffi.call/negint.c (checking): Remove unused variable i.
2039         * testsuite/libffi.call/nested_struct.c (cls_struct_combined_gn): Mark
2040         cif and userdata unused.
2041         * testsuite/libffi.call/nested_struct1.c (cls_struct_combined_gn):
2042         Likewise.
2043         * testsuite/libffi.call/nested_struct10.c (B_gn): Likewise.
2044         * testsuite/libffi.call/nested_struct2.c (B_fn): Adjust printf
2045         formatters to silence gcc.
2046         (B_gn): Mark cif and userdata unused.
2047         * testsuite/libffi.call/nested_struct3.c (B_gn): Mark cif and userdata
2048         unused.
2049         * testsuite/libffi.call/nested_struct4.c: Mention related PR.
2050         (B_gn): Mark cif and userdata unused.
2051         * testsuite/libffi.call/nested_struct5.c (B_gn): Mark cif and userdata
2052         unused.
2053         * testsuite/libffi.call/nested_struct6.c: Mention related PR.
2054         (B_gn): Mark cif and userdata unused.
2055         * testsuite/libffi.call/nested_struct7.c (B_gn): Mark cif and userdata
2056         unused.
2057         * testsuite/libffi.call/nested_struct8.c (B_gn): Likewise.
2058         * testsuite/libffi.call/nested_struct9.c (B_gn): Likewise.
2059         * testsuite/libffi.call/problem1.c (stub): Likewise.
2060         * testsuite/libffi.call/pyobjc-tc.c (main): Cast the result to silence
2061         gcc.
2062         * testsuite/libffi.call/return_fl2.c (return_fl): Add the note mentioned
2063         in the last commit for this test case in the test case itself.
2064         * testsuite/libffi.call/closure_fn0.c (closure_test_fn0): Mark cif as
2065         unused.
2066         * testsuite/libffi.call/closure_fn1.c (closure_test_fn1): Likewise.
2067         * testsuite/libffi.call/closure_fn2.c (closure_test_fn2): Likewise.
2068         * testsuite/libffi.call/closure_fn3.c (closure_test_fn3): Likewise.
2069         * testsuite/libffi.call/closure_fn4.c (closure_test_fn0): Likewise.
2070         * testsuite/libffi.call/closure_fn5.c (closure_test_fn5): Likewise.
2071         * testsuite/libffi.call/closure_fn6.c (closure_test_fn0): Likewise.
2072
2073 2006-02-22  Kaz Kojima  <kkojima@gcc.gnu.org>
2074
2075         * src/sh/sysv.S: Fix register numbers in the FDE for
2076         ffi_closure_SYSV.
2077
2078 2006-02-20  Andreas Tobler  <a.tobler@schweiz.ch>
2079
2080         * testsuite/libffi.call/return_fl2.c (return_fl): Remove static
2081         declaration to avoid a false negative on ix86. See PR323.
2082
2083 2006-02-18  Kaz Kojima  <kkojima@gcc.gnu.org>
2084
2085         * src/sh/ffi.c (ffi_closure_helper_SYSV): Remove unused variable
2086         and cast integer to void * if needed.  Update the pointer to
2087         the FP register saved area correctly.
2088
2089 2006-02-17  Andreas Tobler  <a.tobler@schweiz.ch>
2090
2091         * testsuite/libffi.call/nested_struct6.c: XFAIL this test until PR25630
2092         is fixed.
2093         * testsuite/libffi.call/nested_struct4.c: Likewise.
2094
2095 2006-02-16  Andreas Tobler  <a.tobler@schweiz.ch>
2096
2097         * testsuite/libffi.call/return_dbl.c: New test case.
2098         * testsuite/libffi.call/return_dbl1.c: Likewise.
2099         * testsuite/libffi.call/return_dbl2.c: Likewise.
2100         * testsuite/libffi.call/return_fl.c: Likewise.
2101         * testsuite/libffi.call/return_fl1.c: Likewise.
2102         * testsuite/libffi.call/return_fl2.c: Likewise.
2103         * testsuite/libffi.call/return_fl3.c: Likewise.
2104         * testsuite/libffi.call/closure_fn6.c: Likewise.
2105
2106         * testsuite/libffi.call/nested_struct2.c: Remove ffi_type_mylong
2107         definition.
2108         * testsuite/libffi.call/ffitest.h: Add ffi_type_mylong definition
2109         here to be used by other test cases too.
2110
2111         * testsuite/libffi.call/nested_struct10.c: New test case.
2112         * testsuite/libffi.call/nested_struct9.c: Likewise.
2113         * testsuite/libffi.call/nested_struct8.c: Likewise.
2114         * testsuite/libffi.call/nested_struct7.c: Likewise.
2115         * testsuite/libffi.call/nested_struct6.c: Likewise.
2116         * testsuite/libffi.call/nested_struct5.c: Likewise.
2117         * testsuite/libffi.call/nested_struct4.c: Likewise.
2118
2119 2006-01-21  Andreas Tobler  <a.tobler@schweiz.ch>
2120
2121         * configure.ac: Enable libffi for sparc64-*-freebsd*.
2122         * configure: Rebuilt.
2123
2124 2006-01-18  Jakub Jelinek  <jakub@redhat.com>
2125
2126         * src/powerpc/sysv.S (smst_two_register): Don't call __ashldi3,
2127         instead do the shifting inline.
2128         * src/powerpc/ppc_closure.S (ffi_closure_SYSV): Don't compute %r5
2129         shift count unconditionally.  Simplify load sequences for 1, 2, 3, 4
2130         and 8 byte structs, for the remaining struct sizes don't call
2131         __lshrdi3, instead do the shifting inline.
2132
2133 2005-12-07  Thiemo Seufer  <ths@networkno.de>
2134
2135         * src/mips/ffitarget.h: Remove obsolete sgidefs.h include. Add
2136         missing parentheses.
2137         * src/mips/o32.S (ffi_call_O32): Code formatting. Define
2138         and use A3_OFF, FP_OFF, RA_OFF. Micro-optimizations.
2139         (ffi_closure_O32): Likewise, but with newly defined A3_OFF2,
2140         A2_OFF2, A1_OFF2, A0_OFF2, RA_OFF2, FP_OFF2, S0_OFF2, GP_OFF2,
2141         V1_OFF2, V0_OFF2, FA_1_1_OFF2, FA_1_0_OFF2, FA_0_1_OFF2,
2142         FA_0_0_OFF2.
2143         * src/mips/ffi.c (ffi_prep_args): Code formatting. Fix
2144         endianness bugs.
2145         (ffi_prep_closure): Improve trampoline instruction scheduling.
2146         (ffi_closure_mips_inner_O32): Fix endianness bugs.
2147
2148 2005-12-03  Alan Modra  <amodra@bigpond.net.au>
2149
2150         * src/powerpc/ffi.c: Formatting.
2151         (ffi_prep_args_SYSV): Avoid possible aliasing problems by using unions.
2152         (ffi_prep_args64): Likewise.
2153
2154 2005-09-30  Geoffrey Keating  <geoffk@apple.com>
2155
2156         * testsuite/lib/libffi-dg.exp (libffi_target_compile): For
2157         darwin, use -shared-libgcc not -lgcc_s, and explain why.
2158
2159 2005-09-26  Tom Tromey  <tromey@redhat.com>
2160
2161         * testsuite/libffi.call/float1.c (value_type): New typedef.
2162         (CANARY): New define.
2163         (main): Check for result buffer overflow.
2164         * src/powerpc/linux64.S: Handle linux64 long double returns.
2165         * src/powerpc/ffi.c (FLAG_RETURNS_128BITS): New constant.
2166         (ffi_prep_cif_machdep): Handle linux64 long double returns.
2167
2168 2005-08-25  Alan Modra  <amodra@bigpond.net.au>
2169
2170         PR target/23404
2171         * src/powerpc/ffi.c (ffi_prep_args_SYSV): Correct placement of stack
2172         homed fp args.
2173         (ffi_status ffi_prep_cif_machdep): Correct stack sizing for same.
2174
2175 2005-08-11  Jakub Jelinek  <jakub@redhat.com>
2176
2177         * configure.ac (HAVE_HIDDEN_VISIBILITY_ATTRIBUTE): New test.
2178         (AH_BOTTOM): Add FFI_HIDDEN definition.
2179         * configure: Rebuilt.
2180         * fficonfig.h.in: Rebuilt.
2181         * src/powerpc/ffi.c (hidden): Remove.
2182         (ffi_closure_LINUX64, ffi_prep_args64, ffi_call_LINUX64,
2183         ffi_closure_helper_LINUX64): Use FFI_HIDDEN instead of hidden.
2184         * src/powerpc/linux64_closure.S (ffi_closure_LINUX64,
2185         .ffi_closure_LINUX64): Use FFI_HIDDEN instead of .hidden.
2186         * src/x86/ffi.c (ffi_closure_SYSV, ffi_closure_raw_SYSV): Remove,
2187         add FFI_HIDDEN to its prototype.
2188         (ffi_closure_SYSV_inner): New.
2189         * src/x86/sysv.S (ffi_closure_SYSV, ffi_closure_raw_SYSV): New.
2190         * src/x86/win32.S (ffi_closure_SYSV, ffi_closure_raw_SYSV): New.
2191
2192 2005-08-10  Alfred M. Szmidt  <ams@gnu.org>
2193
2194         PR libffi/21819:
2195         * configure: Rebuilt.
2196         * configure.ac: Handle i*86-*-gnu*.
2197
2198 2005-08-09  Jakub Jelinek  <jakub@redhat.com>
2199
2200         * src/powerpc/ppc_closure.S (ffi_closure_SYSV): Use
2201         DW_CFA_offset_extended_sf rather than
2202         DW_CFA_GNU_negative_offset_extended.
2203         * src/powerpc/sysv.S (ffi_call_SYSV): Likewise.
2204
2205 2005-07-22  SUGIOKA Toshinobu  <sugioka@itonet.co.jp>
2206
2207         * src/sh/sysv.S (ffi_call_SYSV): Stop argument popping correctly
2208         on sh3.
2209         (ffi_closure_SYSV): Change the stack layout for sh3 struct argument.
2210         * src/sh/ffi.c (ffi_prep_args): Fix sh3 argument copy, when it is
2211         partially on register.
2212         (ffi_closure_helper_SYSV): Likewise.
2213         (ffi_prep_cif_machdep): Don't set too many cif->flags.
2214
2215 2005-07-20  Kaz Kojima  <kkojima@gcc.gnu.org>
2216
2217         * src/sh/ffi.c (ffi_call): Handle small structures correctly.
2218         Remove empty line.
2219         * src/sh64/ffi.c (simple_type): Remove.
2220         (return_type): Handle small structures correctly.
2221         (ffi_prep_args): Likewise.
2222         (ffi_call): Likewise.
2223         (ffi_closure_helper_SYSV): Likewise.
2224         * src/sh64/sysv.S (ffi_call_SYSV): Handle 1, 2 and 4-byte return.
2225         Emit position independent code if PIC and remove wrong datalabel
2226         prefixes from EH data.
2227
2228 2005-07-19  Andreas Tobler  <a.tobler@schweiz.ch>
2229
2230         * Makefile.am (nodist_libffi_la_SOURCES): Add POWERPC_FREEBSD.
2231         * Makefile.in: Regenerate.
2232         * include/Makefile.in: Likewise.
2233         * testsuite/Makefile.in: Likewise.
2234         * configure.ac: Add POWERPC_FREEBSD rules.
2235         * configure: Regenerate.
2236         * src/powerpc/ffitarget.h: Add POWERPC_FREEBSD rules.
2237         (FFI_SYSV_TYPE_SMALL_STRUCT): Define.
2238         * src/powerpc/ffi.c: Add flags to handle small structure returns
2239         in ffi_call_SYSV.
2240         (ffi_prep_cif_machdep): Handle small structures for SYSV 4 ABI.
2241         Aka FFI_SYSV.
2242         (ffi_closure_helper_SYSV): Likewise.
2243         * src/powerpc/ppc_closure.S: Add return types for small structures.
2244         * src/powerpc/sysv.S: Add bits to handle small structures for
2245         final SYSV 4 ABI.
2246
2247 2005-07-10  Andreas Tobler  <a.tobler@schweiz.ch>
2248
2249         * testsuite/libffi.call/cls_5_1_byte.c: New test file.
2250         * testsuite/libffi.call/cls_6_1_byte.c: Likewise.
2251         * testsuite/libffi.call/cls_7_1_byte.c: Likewise.
2252
2253 2005-07-05  Randolph Chung  <tausq@debian.org>
2254
2255         * src/pa/ffi.c (ffi_struct_type): Rename FFI_TYPE_SMALL_STRUCT1
2256         as FFI_TYPE_SMALL_STRUCT3.  Break out handling for 5-7 byte
2257         structures.  Kill compilation warnings.
2258         (ffi_closure_inner_LINUX): Print return values as hex in debug
2259         message.  Rename FFI_TYPE_SMALL_STRUCT1 as FFI_TYPE_SMALL_STRUCT3.
2260         Properly handle 5-7 byte structure returns.
2261         * src/pa/ffitarget.h (FFI_TYPE_SMALL_STRUCT1)
2262         (FFI_TYPE_SMALL_STRUCT2): Remove.
2263         (FFI_TYPE_SMALL_STRUCT3, FFI_TYPE_SMALL_STRUCT5)
2264         (FFI_TYPE_SMALL_STRUCT6, FFI_TYPE_SMALL_STRUCT7): Define.
2265         * src/pa/linux.S: Mark source file as using PA1.1 assembly.
2266         (checksmst1, checksmst2): Remove.
2267         (checksmst3): Optimize handling of 3-byte struct returns.
2268         (checksmst567): Properly handle 5-7 byte struct returns.
2269
2270 2005-06-15  Rainer Orth  <ro@TechFak.Uni-Bielefeld.DE>
2271
2272         PR libgcj/21943
2273         * src/mips/n32.S: Enforce PIC code.
2274         * src/mips/o32.S: Likewise.
2275
2276 2005-06-15  Rainer Orth  <ro@TechFak.Uni-Bielefeld.DE>
2277
2278         * configure.ac: Treat i*86-*-solaris2.10 and up as X86_64.
2279         * configure: Regenerate.
2280
2281 2005-06-01  Alan Modra  <amodra@bigpond.net.au>
2282
2283         * src/powerpc/ppc_closure.S (ffi_closure_SYSV): Don't use JUMPTARGET
2284         to call ffi_closure_helper_SYSV.  Append @local instead.
2285         * src/powerpc/sysv.S (ffi_call_SYSV): Likewise for ffi_prep_args_SYSV.
2286
2287 2005-05-17  Kelley Cook  <kcook@gcc.gnu.org>
2288
2289         * configure.ac: Use AC_C_BIGENDIAN instead of AC_C_BIGENDIAN_CROSS.
2290         Use AC_CHECK_SIZEOF instead of AC_COMPILE_CHECK_SIZEOF.
2291         * Makefile.am (ACLOCAL_AMFLAGS): Remove -I ../config.
2292         * aclocal.m4, configure, fficonfig.h.in, Makefile.in,
2293         include/Makefile.in, testsuite/Makefile.in: Regenerate.
2294
2295 2005-05-09  Mike Stump  <mrs@apple.com>
2296
2297         * configure: Regenerate.
2298
2299 2005-05-08  Richard Henderson  <rth@redhat.com>
2300
2301         PR libffi/21285
2302         * src/alpha/osf.S: Update unwind into to match code.
2303
2304 2005-05-04  Andreas Degert <ad@papyrus-gmbh.de>
2305             Richard Henderson  <rth@redhat.com>
2306
2307         * src/x86/ffi64.c (ffi_prep_cif_machdep): Save sse-used flag in
2308         bit 11 of flags.
2309         (ffi_call): Mask return type field.  Pass ssecount to ffi_call_unix64.
2310         (ffi_prep_closure): Set carry bit if sse-used flag set.
2311         * src/x86/unix64.S (ffi_call_unix64): Add ssecount argument.
2312         Only load sse registers if ssecount non-zero.
2313         (ffi_closure_unix64): Only save sse registers if carry set on entry.
2314
2315 2005-04-29  Ralf Corsepius  <ralf.corsepius@rtems.org>
2316
2317         * configure.ac: Add i*86-*-rtems*, sparc*-*-rtems*,
2318         powerpc-*rtems*, arm*-*-rtems*, sh-*-rtems*.
2319         * configure: Regenerate.
2320
2321 2005-04-20  Hans-Peter Nilsson  <hp@axis.com>
2322
2323         * testsuite/lib/libffi-dg.exp (libffi-dg-test-1): In regsub use,
2324         have Tcl8.3-compatible intermediate variable.
2325
2326 2005-04-18  Simon Posnjak <simon.posnjak@siol.net>
2327             Hans-Peter Nilsson  <hp@axis.com>
2328
2329         * Makefile.am: Add CRIS support.
2330         * configure.ac: Likewise.
2331         * Makefile.in, configure, testsuite/Makefile.in,
2332         include/Makefile.in: Regenerate.
2333         * src/cris: New directory.
2334         * src/cris/ffi.c, src/cris/sysv.S, src/cris/ffitarget.h: New files.
2335         * src/prep_cif.c (ffi_prep_cif): Wrap in #ifndef __CRIS__.
2336
2337         * testsuite/lib/libffi-dg.exp (libffi-dg-test-1): Replace \n with
2338         \r?\n in output tests.
2339
2340 2005-04-12  Mike Stump  <mrs@apple.com>
2341
2342         * configure: Regenerate.
2343
2344 2005-03-30  Hans Boehm  <Hans.Boehm@hp.com>
2345
2346         * src/ia64/ffitarget.h (ffi_arg): Use long long instead of DI.
2347
2348 2005-03-30  Steve Ellcey  <sje@cup.hp.com>
2349
2350         * src/ia64/ffitarget.h (ffi_arg) ADD DI attribute.
2351         (ffi_sarg) Ditto.
2352         * src/ia64/unix.S (ffi_closure_unix): Extend gp
2353         to 64 bits in ILP32 mode.
2354         Load 64 bits even for short data.
2355
2356 2005-03-23  Mike Stump  <mrs@apple.com>
2357
2358         * src/powerpc/darwin.S: Update for -m64 multilib.
2359         * src/powerpc/darwin_closure.S: Likewise.
2360
2361 2005-03-21  Zack Weinberg  <zack@codesourcery.com>
2362
2363         * configure.ac: Do not invoke TL_AC_GCC_VERSION.
2364         Do not set tool_include_dir.
2365         * aclocal.m4, configure, Makefile.in, testsuite/Makefile.in:
2366         Regenerate.
2367         * include/Makefile.am: Set gcc_version and toollibffidir.
2368         * include/Makefile.in: Regenerate.
2369
2370 2005-02-22  Andrew Haley  <aph@redhat.com>
2371
2372         * src/powerpc/ffi.c (ffi_prep_cif_machdep): Bump alignment to
2373         odd-numbered register pairs for 64-bit integer types.
2374
2375 2005-02-23  Andreas Tobler  <a.tobler@schweiz.ch>
2376
2377         PR libffi/20104
2378         * testsuite/libffi.call/return_ll1.c: New test case.
2379
2380 2005-02-11  Janis Johnson  <janis187@us.ibm.com>
2381
2382         * testsuite/libffi.call/cls_align_longdouble.c: Remove dg-options.
2383         * testsuite/libffi.call/float.c: Ditto.
2384         * testsuite/libffi.call/float2.c: Ditto.
2385         * testsuite/libffi.call/float3.c: Ditto.
2386
2387 2005-02-08  Andreas Tobler  <a.tobler@schweiz.ch>
2388
2389         * src/frv/ffitarget.h: Remove PPC stuff which does not belong to frv.
2390
2391 2005-01-12  Eric Botcazou  <ebotcazou@libertysurf.fr>
2392
2393         * testsuite/libffi.special/special.exp (cxx_options): Add
2394         -shared-libgcc.
2395
2396 2004-12-31  Richard Henderson  <rth@redhat.com>
2397
2398         * src/types.c (FFI_AGGREGATE_TYPEDEF): Remove.
2399         (FFI_TYPEDEF): Rename from FFI_INTEGRAL_TYPEDEF.  Replace size and
2400         offset parameters with a type parameter; deduce size and structure
2401         alignment.  Update all users.
2402
2403 2004-12-31  Richard Henderson  <rth@redhat.com>
2404
2405         * src/types.c (FFI_TYPE_POINTER): Define with sizeof.
2406         (FFI_TYPE_LONGDOUBLE): Fix for ia64.
2407         * src/ia64/ffitarget.h (struct ffi_ia64_trampoline_struct): Move
2408         into ffi_prep_closure.
2409         * src/ia64/ia64_flags.h, src/ia64/ffi.c, src/ia64/unix.S: Rewrite
2410         from scratch.
2411
2412 2004-12-27  Richard Henderson  <rth@redhat.com>
2413
2414         * src/x86/unix64.S: Fix typo in unwind info.
2415
2416 2004-12-25  Richard Henderson  <rth@redhat.com>
2417
2418         * src/x86/ffi64.c (struct register_args): Rename from stackLayout.
2419         (enum x86_64_reg_class): Add X86_64_COMPLEX_X87_CLASS.
2420         (merge_classes): Check for it.
2421         (SSE_CLASS_P): New.
2422         (classify_argument): Pass byte_offset by value; perform all updates
2423         inside struct case.
2424         (examine_argument): Add classes argument; handle
2425         X86_64_COMPLEX_X87_CLASS.
2426         (ffi_prep_args): Merge into ...
2427         (ffi_call): ... here.  Share stack frame with ffi_call_unix64.
2428         (ffi_prep_cif_machdep): Setup cif->flags for proper structure return.
2429         (ffi_fill_return_value): Remove.
2430         (ffi_prep_closure): Remove dead assert.
2431         (ffi_closure_unix64_inner): Rename from ffi_closure_UNIX64_inner.
2432         Rewrite to use struct register_args instead of va_list.  Create
2433         flags for handling structure returns.
2434         * src/x86/unix64.S: Remove dead strings.
2435         (ffi_call_unix64): Rename from ffi_call_UNIX64.  Rewrite to share
2436         stack frame with ffi_call.  Handle structure returns properly.
2437         (float2sse, floatfloat2sse, double2sse): Remove.
2438         (sse2float, sse2double, sse2floatfloat): Remove.
2439         (ffi_closure_unix64): Rename from ffi_closure_UNIX64.  Rewrite
2440         to handle structure returns properly.
2441
2442 2004-12-08  David Edelsohn  <edelsohn@gnu.org>
2443
2444         * Makefile.am (AM_MAKEFLAGS): Remove duplicate LIBCFLAGS and
2445         PICFLAG.
2446         * Makefile.in: Regenerated.
2447
2448 2004-12-02  Richard Sandiford  <rsandifo@redhat.com>
2449
2450         * configure.ac: Use TL_AC_GCC_VERSION to set gcc_version.
2451         * configure, aclocal.m4, Makefile.in: Regenerate.
2452         * include/Makefile.in, testsuite/Makefile.in: Regenerate.
2453
2454 2004-11-29  Kelley Cook  <kcook@gcc.gnu.org>
2455
2456         * configure: Regenerate for libtool change.
2457
2458 2004-11-25  Kelley Cook  <kcook@gcc.gnu.org>
2459
2460         * configure: Regenerate for libtool reversion.
2461
2462 2004-11-24  Kelley Cook  <kcook@gcc.gnu.org>
2463
2464         * configure: Regenerate for libtool change.
2465
2466 2004-11-23  John David Anglin  <dave.anglin@nrc-cnrc.gc.ca>
2467
2468         * testsuite/lib/libffi-dg.exp: Use new procs in target-libpath.exp.
2469
2470 2004-11-23  Richard Sandiford  <rsandifo@redhat.com>
2471
2472         * src/mips/o32.S (ffi_call_O32, ffi_closure_O32): Use jalr instead
2473         of jal.  Use an absolute encoding for the frame information.
2474
2475 2004-11-23  Kelley Cook  <kcook@gcc.gnu.org>
2476
2477         * Makefile.am: Remove no-dependencies.  Add ACLOCAL_AMFLAGS.
2478         * acinclude.m4: Delete logic for sincludes.
2479         * aclocal.m4, Makefile.in, configure: Regenerate.
2480         * include/Makefile: Likewise.
2481         * testsuite/Makefile: Likewise.
2482
2483 2004-11-22  Eric Botcazou  <ebotcazou@libertysurf.fr>
2484
2485         * src/sparc/ffi.c (ffi_prep_closure): Align doubles and 64-bit integers
2486         on a 8-byte boundary.
2487         * src/sparc/v8.S (ffi_closure_v8): Reserve frame space for arguments.
2488
2489 2004-10-27  Richard Earnshaw  <rearnsha@arm.com>
2490
2491         * src/arm/ffi.c (ffi_prep_cif_machdep): Handle functions that return
2492         long long values.  Round stack allocation to a multiple of 8 bytes
2493         for ATPCS compatibility.
2494         * src/arm/sysv.S (ffi_call_SYSV): Rework to avoid use of APCS register
2495         names.  Handle returning long long types.  Add Thumb and interworking
2496         support.  Improve soft-float code.
2497
2498 2004-10-27  Richard Earnshaw  <rearnsha@arm.com>
2499
2500         * testsuite/lib/libffi-db.exp (load_gcc_lib): New function.
2501         (libffi_exit): New function.
2502         (libffi_init): Build the testglue wrapper if needed.
2503
2504 2004-10-25  Eric Botcazou  <ebotcazou@libertysurf.fr>
2505
2506         PR other/18138
2507         * testsuite/lib/libffi-dg.exp: Accept more than one multilib libgcc.
2508
2509 2004-10-25  Kazuhiro Inaoka <inaoka.kazuhiro@renesas.com>
2510
2511         * src/m32r/libffitarget.h (FFI_CLOSURES): Set to 0.
2512
2513 2004-10-20  Kaz Kojima  <kkojima@gcc.gnu.org>
2514
2515         * src/sh/sysv.S (ffi_call_SYSV): Don't align for double data.
2516         * testsuite/libffi.call/float3.c: New test case.
2517
2518 2004-10-18  Kaz Kojima  <kkojima@gcc.gnu.org>
2519
2520         * src/sh/ffi.c (ffi_prep_closure): Set T bit in trampoline for
2521         the function returning a structure pointed with R2.
2522         * src/sh/sysv.S (ffi_closure_SYSV): Use R2 as the pointer to
2523         the structure return value if T bit set.  Emit position
2524         independent code and EH data if PIC.
2525
2526 2004-10-13  Kazuhiro Inaoka  <inaoka.kazuhiro@renesas.com>
2527
2528         * Makefile.am: Add m32r support.
2529         * configure.ac: Likewise.
2530         * Makefile.in: Regenerate.
2531         * confiugre: Regenerate.
2532         * src/types.c: Add m32r port to FFI_INTERNAL_TYPEDEF
2533         (uint64, sint64, double, longdouble)
2534         * src/m32r: New directory.
2535         * src/m32r/ffi.c: New file.
2536         * src/m32r/sysv.S: Likewise.
2537         * src/m32r/ffitarget.h: Likewise.
2538
2539 2004-10-02  Kaz Kojima  <kkojima@gcc.gnu.org>
2540
2541         * testsuite/libffi.call/negint.c: New test case.
2542
2543 2004-09-14  H.J. Lu  <hongjiu.lu@intel.com>
2544
2545         PR libgcj/17465
2546         * testsuite/lib/libffi-dg.exp: Don't use global ld_library_path.
2547         Set up LD_LIBRARY_PATH, SHLIB_PATH, LD_LIBRARYN32_PATH,
2548         LD_LIBRARY64_PATH, LD_LIBRARY_PATH_32, LD_LIBRARY_PATH_64 and
2549         DYLD_LIBRARY_PATH.
2550
2551 2004-09-05  Andreas Tobler  <a.tobler@schweiz.ch>
2552
2553         * testsuite/libffi.call/many_win32.c: Remove whitespaces.
2554         * testsuite/libffi.call/promotion.c: Likewise.
2555         * testsuite/libffi.call/return_ll.c: Remove unused var. Cleanup
2556         whitespaces.
2557         * testsuite/libffi.call/return_sc.c: Likewise.
2558         * testsuite/libffi.call/return_uc.c: Likewise.
2559
2560 2004-09-05  Andreas Tobler  <a.tobler@schweiz.ch>
2561
2562         * src/powerpc/darwin.S: Fix comments and identation.
2563         * src/powerpc/darwin_closure.S: Likewise.
2564
2565 2004-09-02  Andreas Tobler  <a.tobler@schweiz.ch>
2566
2567         * src/powerpc/ffi_darwin.c: Add flag for longdouble return values.
2568         (ffi_prep_args): Handle longdouble arguments.
2569         (ffi_prep_cif_machdep): Set flags for longdouble. Calculate space for
2570         longdouble.
2571         (ffi_closure_helper_DARWIN): Add closure handling for longdouble.
2572         * src/powerpc/darwin.S (_ffi_call_DARWIN): Add handling of longdouble
2573         values.
2574         * src/powerpc/darwin_closure.S (_ffi_closure_ASM): Likewise.
2575         * src/types.c: Defined longdouble size and alignment for darwin.
2576
2577 2004-09-02  Andreas Tobler  <a.tobler@schweiz.ch>
2578
2579         * src/powerpc/aix.S: Remove whitespaces.
2580         * src/powerpc/aix_closure.S: Likewise.
2581         * src/powerpc/asm.h: Likewise.
2582         * src/powerpc/ffi.c: Likewise.
2583         * src/powerpc/ffitarget.h: Likewise.
2584         * src/powerpc/linux64.S: Likewise.
2585         * src/powerpc/linux64_closure.S: Likewise.
2586         * src/powerpc/ppc_closure.S: Likewise.
2587         * src/powerpc/sysv.S: Likewise.
2588
2589 2004-08-30  Anthony Green  <green@redhat.com>
2590
2591         * Makefile.am: Add frv support.
2592         * Makefile.in, testsuite/Makefile.in: Rebuilt.
2593         * configure.ac: Read configure.host.
2594         * configure.in: Read configure.host.
2595         * configure.host: New file.  frv-elf needs libgloss.
2596         * include/ffi.h.in: Force ffi_closure to have a nice big (8)
2597         alignment.  This is needed to frv and shouldn't harm the others.
2598         * include/ffi_common.h (ALIGN_DOWN): New macro.
2599         * src/frv/ffi.c, src/frv/ffitarget.h, src/frv/eabi.S: New files.
2600
2601 2004-08-24  David Daney  <daney@avtrex.com>
2602
2603         * testsuite/libffi.call/closure_fn0.c: Xfail mips64* instead of mips*.
2604         * testsuite/libffi.call/closure_fn1.c: Likewise.
2605         * testsuite/libffi.call/closure_fn2.c  Likewise.
2606         * testsuite/libffi.call/closure_fn3.c: Likewise.
2607         * testsuite/libffi.call/closure_fn4.c: Likewise.
2608         * testsuite/libffi.call/closure_fn5.c: Likewise.
2609         * testsuite/libffi.call/cls_18byte.c: Likewise.
2610         * testsuite/libffi.call/cls_19byte.c: Likewise.
2611         * testsuite/libffi.call/cls_1_1byte.c: Likewise.
2612         * testsuite/libffi.call/cls_20byte.c: Likewise.
2613         * testsuite/libffi.call/cls_20byte1.c: Likewise.
2614         * testsuite/libffi.call/cls_24byte.c: Likewise.
2615         * testsuite/libffi.call/cls_2byte.c: Likewise.
2616         * testsuite/libffi.call/cls_3_1byte.c: Likewise.
2617         * testsuite/libffi.call/cls_3byte1.c: Likewise.
2618         * testsuite/libffi.call/cls_3byte2.c: Likewise.
2619         * testsuite/libffi.call/cls_4_1byte.c: Likewise.
2620         * testsuite/libffi.call/cls_4byte.c: Likewise.
2621         * testsuite/libffi.call/cls_64byte.c: Likewise.
2622         * testsuite/libffi.call/cls_6byte.c: Likewise.
2623         * testsuite/libffi.call/cls_7byte.c: Likewise.
2624         * testsuite/libffi.call/cls_8byte.c: Likewise.
2625         * testsuite/libffi.call/cls_9byte1.c: Likewise.
2626         * testsuite/libffi.call/cls_9byte2.c: Likewise.
2627         * testsuite/libffi.call/cls_align_double.c: Likewise.
2628         * testsuite/libffi.call/cls_align_float.c: Likewise.
2629         * testsuite/libffi.call/cls_align_longdouble.c: Likewise.
2630         * testsuite/libffi.call/cls_align_pointer.c: Likewise.
2631         * testsuite/libffi.call/cls_align_sint16.c: Likewise.
2632         * testsuite/libffi.call/cls_align_sint32.c: Likewise.
2633         * testsuite/libffi.call/cls_align_sint64.c: Likewise.
2634         * testsuite/libffi.call/cls_align_uint16.c: Likewise.
2635         * testsuite/libffi.call/cls_align_uint32.c: Likewise.
2636         * testsuite/libffi.call/cls_align_uint64.c: Likewise.
2637         * testsuite/libffi.call/cls_double.c: Likewise.
2638         * testsuite/libffi.call/cls_float.c: Likewise.
2639         * testsuite/libffi.call/cls_multi_schar.c: Likewise.
2640         * testsuite/libffi.call/cls_multi_sshort.c: Likewise.
2641         * testsuite/libffi.call/cls_multi_sshortchar.c: Likewise.
2642         * testsuite/libffi.call/cls_multi_uchar.c: Likewise.
2643         * testsuite/libffi.call/cls_multi_ushort.c: Likewise.
2644         * testsuite/libffi.call/cls_multi_ushortchar.c: Likewise.
2645         * testsuite/libffi.call/cls_schar.c: Likewise.
2646         * testsuite/libffi.call/cls_sint.c: Likewise.
2647         * testsuite/libffi.call/cls_sshort.c: Likewise.
2648         * testsuite/libffi.call/cls_uchar.c: Likewise.
2649         * testsuite/libffi.call/cls_uint.c: Likewise.
2650         * testsuite/libffi.call/cls_ulonglong.c: Likewise.
2651         * testsuite/libffi.call/cls_ushort.c: Likewise.
2652         * testsuite/libffi.call/nested_struct.c: Likewise.
2653         * testsuite/libffi.call/nested_struct1.c: Likewise.
2654         * testsuite/libffi.call/nested_struct2.c: Likewise.
2655         * testsuite/libffi.call/nested_struct3.c: Likewise.
2656         * testsuite/libffi.call/problem1.c: Likewise.
2657         * testsuite/libffi.special/unwindtest.cc: Likewise.
2658         * testsuite/libffi.call/cls_12byte.c: Likewise and set return value
2659         to zero.
2660         * testsuite/libffi.call/cls_16byte.c: Likewise.
2661         * testsuite/libffi.call/cls_5byte.c: Likewise.
2662
2663 2004-08-23  David Daney <daney@avtrex.com>
2664
2665         PR libgcj/13141
2666         * src/mips/ffitarget.h (FFI_O32_SOFT_FLOAT): New ABI.
2667         * src/mips/ffi.c (ffi_prep_args): Fix alignment calculation.
2668         (ffi_prep_cif_machdep): Handle FFI_O32_SOFT_FLOAT floating point
2669         parameters and return types.
2670         (ffi_call): Handle FFI_O32_SOFT_FLOAT ABI.
2671         (ffi_prep_closure): Ditto.
2672         (ffi_closure_mips_inner_O32): Handle FFI_O32_SOFT_FLOAT ABI, fix
2673         alignment calculations.
2674         * src/mips/o32.S (ffi_closure_O32): Don't use floating point
2675         instructions if FFI_O32_SOFT_FLOAT, make stack frame ABI compliant.
2676
2677 2004-08-14  Casey Marshall <csm@gnu.org>
2678
2679         * src/mips/ffi.c (ffi_pref_cif_machdep): set `cif->flags' to
2680         contain `FFI_TYPE_UINT64' as return type for any 64-bit
2681         integer (O32 ABI only).
2682         (ffi_prep_closure): new function.
2683         (ffi_closure_mips_inner_O32): new function.
2684         * src/mips/ffitarget.h: Define `FFI_CLOSURES' and
2685         `FFI_TRAMPOLINE_SIZE' appropriately if the ABI is o32.
2686         * src/mips/o32.S (ffi_call_O32): add labels for .eh_frame. Return
2687         64 bit integers correctly.
2688         (ffi_closure_O32): new function.
2689         Added DWARF-2 unwind info for both functions.
2690
2691 2004-08-10  Andrew Haley  <aph@redhat.com>
2692
2693         * src/x86/ffi64.c (ffi_prep_args ): 8-align all stack arguments.
2694
2695 2004-08-01  Robert Millan  <robertmh@gnu.org>
2696
2697         * configure.ac: Detect knetbsd-gnu and kfreebsd-gnu.
2698         * configure: Regenerate.
2699
2700 2004-07-30  Maciej W. Rozycki  <macro@linux-mips.org>
2701
2702         * acinclude.m4 (AC_FUNC_MMAP_BLACKLIST): Check for <sys/mman.h>
2703         and mmap() explicitly instead of relying on preset autoconf cache
2704         variables.
2705         * aclocal.m4: Regenerate.
2706         * configure: Regenerate.
2707
2708 2004-07-11  Ulrich Weigand  <uweigand@de.ibm.com>
2709
2710         * src/s390/ffi.c (ffi_prep_args): Fix C aliasing violation.
2711         (ffi_check_float_struct): Remove unused prototype.
2712
2713 2004-06-30  Geoffrey Keating  <geoffk@apple.com>
2714
2715         * src/powerpc/ffi_darwin.c (flush_icache): ';' is a comment
2716         character on Darwin, use '\n\t' instead.
2717
2718 2004-06-26  Matthias Klose  <doko@debian.org>
2719
2720         * libtool-version: Fix typo in revision/age.
2721
2722 2004-06-17  Matthias Klose  <doko@debian.org>
2723
2724         * libtool-version: New.
2725         * Makefile.am (libffi_la_LDFLAGS): Use -version-info for soname.
2726         * Makefile.in: Regenerate.
2727
2728 2004-06-15  Paolo Bonzini  <bonzini@gnu.org>
2729
2730         * Makefile.am: Remove useless multilib rules.
2731         * Makefile.in: Regenerate.
2732         * aclocal.m4: Regenerate with automake 1.8.5.
2733         * configure.ac: Remove useless multilib configury.
2734         * configure: Regenerate.
2735
2736 2004-06-15  Paolo Bonzini  <bonzini@gnu.org>
2737
2738         * .cvsignore: New file.
2739
2740 2004-06-10  Jakub Jelinek  <jakub@redhat.com>
2741
2742         * src/ia64/unix.S (ffi_call_unix): Insert group barrier break
2743         fp_done.
2744         (ffi_closure_UNIX): Fix f14/f15 adjustment if FLOAT_SZ is ever
2745         changed from 8.
2746
2747 2004-06-06  Sean McNeil  <sean@mcneil.com>
2748
2749         * configure.ac: Add x86_64-*-freebsd* support.
2750         * configure: Regenerate.
2751
2752 2004-04-26  Joe Buck <jbuck@welsh-buck.org>
2753
2754         Bug 15093
2755         * configure.ac: Test for existence of mmap and sys/mman.h before
2756         checking blacklist.  Fix suggested by Jim Wilson.
2757         * configure: Regenerate.
2758
2759 2004-04-26  Matt Austern  <austern@apple.com>
2760
2761         * src/powerpc/darwin.S: Go through a non-lazy pointer for initial
2762         FDE location.
2763         * src/powerpc/darwin_closure.S: Likewise.
2764
2765 2004-04-24  Andreas Tobler  <a.tobler@schweiz.ch>
2766
2767         * testsuite/libffi.call/cls_multi_schar.c (main): Fix initialization
2768         error. Reported by Thomas Heller <theller@python.net>.
2769         * testsuite/libffi.call/cls_multi_sshort.c (main): Likewise.
2770         * testsuite/libffi.call/cls_multi_ushort.c (main): Likewise.
2771
2772 2004-03-20  Matthias Klose  <doko@debian.org>
2773
2774         * src/pa/linux.S: Fix typo.
2775
2776 2004-03-19  Matthias Klose  <doko@debian.org>
2777
2778         * Makefile.am: Update.
2779         * Makefile.in: Regenerate.
2780         * src/pa/ffi.h.in: Remove.
2781         * src/pa/ffitarget.h: New file.
2782
2783 2004-02-10  Randolph Chung  <tausq@debian.org>
2784
2785         * Makefile.am: Add PA support.
2786         * Makefile.in: Regenerate.
2787         * include/Makefile.in: Regenerate.
2788         * configure.ac: Add PA target.
2789         * configure: Regenerate.
2790         * src/pa/ffi.c: New file.
2791         * src/pa/ffi.h.in: Add PA support.
2792         * src/pa/linux.S: New file.
2793         * prep_cif.c: Add PA support.
2794
2795 2004-03-16  Hosaka Yuji  <hos@tamanegi.org>
2796
2797         * src/types.c: Fix alignment size of X86_WIN32 case int64 and
2798         double.
2799         * src/x86/ffi.c (ffi_prep_args): Replace ecif->cif->rtype->type
2800         with ecif->cif->flags.
2801         (ffi_call, ffi_prep_incoming_args_SYSV): Replace cif->rtype->type
2802         with cif->flags.
2803         (ffi_prep_cif_machdep): Add X86_WIN32 struct case.
2804         (ffi_closure_SYSV): Add 1 or 2-bytes struct case for X86_WIN32.
2805         * src/x86/win32.S (retstruct1b, retstruct2b, sc_retstruct1b,
2806         sc_retstruct2b): Add for 1 or 2-bytes struct case.
2807
2808 2004-03-15 Kelley Cook <kcook@gcc.gnu.org>
2809
2810         * configure.in: Rename file to ...
2811         * configure.ac: ... this.
2812         * fficonfig.h.in: Regenerate.
2813         * Makefile.in: Regenerate.
2814         * include/Makefile.in: Regenerate.
2815         * testsuite/Makefile.in: Regenerate.
2816
2817 2004-03-12  Matt Austern  <austern@apple.com>
2818
2819         * src/powerpc/darwin.S: Fix EH information so it corresponds to
2820         changes in EH format resulting from addition of linkonce support.
2821         * src/powerpc/darwin_closure.S: Likewise.
2822
2823 2004-03-11  Andreas Tobler  <a.tobler@schweiz.ch>
2824             Paolo Bonzini  <bonzini@gnu.org>
2825
2826         * Makefile.am (AUTOMAKE_OPTIONS): Set them.
2827         Remove VPATH. Remove rules for object files. Remove multilib support.
2828         (AM_CCASFLAGS): Add.
2829         * configure.in (AC_CONFIG_HEADERS): Relace AM_CONFIG_HEADER.
2830         (AC_PREREQ): Bump version to 2.59.
2831         (AC_INIT): Fill with version info and bug address.
2832         (ORIGINAL_LD_FOR_MULTILIBS): Remove.
2833         (AM_ENABLE_MULTILIB): Use this instead of AC_ARG_ENABLE.
2834         De-precious CC so that the right flags are passed down to multilibs.
2835         (AC_MSG_ERROR): Replace obsolete macro AC_ERROR.
2836         (AC_CONFIG_FILES): Replace obsolete macro AC_LINK_FILES.
2837         (AC_OUTPUT): Reorganize the output with AC_CONFIG_COMMANDS.
2838         * configure: Rebuilt.
2839         * aclocal.m4: Likewise.
2840         * Makefile.in, include/Makefile.in, testsuite/Makefile.in: Likewise.
2841         * fficonfig.h.in: Likewise.
2842
2843 2004-03-11  Andreas Schwab  <schwab@suse.de>
2844
2845         * src/ia64/ffi.c (ffi_prep_incoming_args_UNIX): Get floating point
2846         arguments from fp registers only for the first 8 parameter slots.
2847         Don't convert a float parameter when passed in memory.
2848
2849 2004-03-09  Hans-Peter Nilsson  <hp@axis.com>
2850
2851         * configure: Regenerate for config/accross.m4 correction.
2852
2853 2004-02-25  Matt Kraai  <kraai@alumni.cmu.edu>
2854
2855         * src/powerpc/ffi.c (ffi_prep_args_SYSV): Change
2856         ecif->cif->bytes to bytes.
2857         (ffi_prep_cif_machdep): Add braces around nested if statement.
2858
2859 2004-02-09  Alan Modra  <amodra@bigpond.net.au>
2860
2861         * src/types.c (pointer): POWERPC64 has 8 byte pointers.
2862
2863         * src/powerpc/ffi.c (ffi_prep_args64): Correct long double handling.
2864         (ffi_closure_helper_LINUX64): Fix typo.
2865         * testsuite/libffi.call/cls_align_longdouble.c: Pass -mlong-double-128
2866         for powerpc64-*-*.
2867         * testsuite/libffi.call/float.c: Likewise.
2868         * testsuite/libffi.call/float2.c: Likewise.
2869
2870 2004-02-08  Alan Modra  <amodra@bigpond.net.au>
2871
2872         * src/powerpc/ffi.c (ffi_prep_cif_machdep <FFI_LINUX64>): Correct
2873         long double function return and long double arg handling.
2874         (ffi_closure_helper_LINUX64): Formatting.  Delete unused "ng" var.
2875         Use "end_pfr" instead of "nf".  Correct long double handling.
2876         Localise "temp".
2877         * src/powerpc/linux64.S (ffi_call_LINUX64): Save f2 long double
2878         return value.
2879         * src/powerpc/linux64_closure.S (ffi_closure_LINUX64): Allocate
2880         space for long double return value.  Adjust stack frame and offsets.
2881         Load f2 long double return.
2882
2883 2004-02-07  Alan Modra  <amodra@bigpond.net.au>
2884
2885         * src/types.c: Use 16 byte long double for POWERPC64.
2886
2887 2004-01-25  Eric Botcazou  <ebotcazou@libertysurf.fr>
2888
2889         * src/sparc/ffi.c (ffi_prep_args_v9): Shift the parameter array
2890         when the structure return address is passed in %o0.
2891         (ffi_V9_return_struct): Rename into ffi_v9_layout_struct.
2892         (ffi_v9_layout_struct): Align the field following a nested structure
2893         on a word boundary.  Use memmove instead of memcpy.
2894         (ffi_call): Update call to ffi_V9_return_struct.
2895         (ffi_prep_closure): Define 'ctx' only for V8.
2896         (ffi_closure_sparc_inner): Clone into ffi_closure_sparc_inner_v8
2897         and ffi_closure_sparc_inner_v9.
2898         (ffi_closure_sparc_inner_v8): Return long doubles by reference.
2899         Always skip the structure return address.  For structures and long
2900         doubles, copy the argument directly.
2901         (ffi_closure_sparc_inner_v9): Skip the structure return address only
2902         if required.  Shift the maximum floating-point slot accordingly.  For
2903         big structures, copy the argument directly; otherwise, left-justify the
2904         argument and call ffi_v9_layout_struct to lay out the structure on
2905         the stack.
2906         * src/sparc/v8.S: Undef STACKFRAME before defining it.
2907         (ffi_closure_v8): Pass the structure return address.  Update call to
2908         ffi_closure_sparc_inner_v8.  Short-circuit FFI_TYPE_INT handling.
2909         Skip the 'unimp' insn when returning long doubles and structures.
2910         * src/sparc/v9.S: Undef STACKFRAME before defining it.
2911         (ffi_closure_v9): Increase the frame size by 2 words.  Short-circuit
2912         FFI_TYPE_INT handling.  Load structures both in integers and
2913         floating-point registers on return.
2914         * README: Update status of the SPARC port.
2915
2916 2004-01-24  Andreas Tobler  <a.tobler@schweiz.ch>
2917
2918         * testsuite/libffi.call/pyobjc-tc.c (main): Treat result value
2919         as of type ffi_arg.
2920         * testsuite/libffi.call/struct3.c (main): Fix CHECK.
2921
2922 2004-01-22  Ulrich Weigand  <uweigand@de.ibm.com>
2923
2924         * testsuite/libffi.call/cls_uint.c (cls_ret_uint_fn): Treat result
2925         value as of type ffi_arg, not unsigned int.
2926
2927 2004-01-21  Michael Ritzert  <ritzert@t-online.de>
2928
2929         * ffi64.c (ffi_prep_args): Cast the RHS of an assignment instead
2930         of the LHS.
2931
2932 2004-01-12  Andreas Tobler  <a.tobler@schweiz.ch>
2933
2934         * testsuite/lib/libffi-dg.exp: Set LD_LIBRARY_PATH_32 for
2935         Solaris.
2936
2937 2004-01-08  Rainer Orth  <ro@TechFak.Uni-Bielefeld.DE>
2938
2939         * testsuite/libffi.call/ffitest.h (allocate_mmap): Cast MAP_FAILED
2940         to void *.
2941
2942 2003-12-10  Richard Henderson  <rth@redhat.com>
2943
2944         * testsuite/libffi.call/cls_align_pointer.c: Cast pointers to
2945         size_t instead of int.
2946
2947 2003-12-04  Hosaka Yuji  <hos@tamanegi.org>
2948
2949         * testsuite/libffi.call/many_win32.c: Include <float.h>.
2950         * testsuite/libffi.call/many_win32.c (main): Replace variable
2951         int i with unsigned long ul.
2952
2953         * testsuite/libffi.call/cls_align_uint64.c: New test case.
2954         * testsuite/libffi.call/cls_align_sint64.c: Likewise.
2955         * testsuite/libffi.call/cls_align_uint32.c: Likewise.
2956         * testsuite/libffi.call/cls_align_sint32.c: Likewise.
2957         * testsuite/libffi.call/cls_align_uint16.c: Likewise.
2958         * testsuite/libffi.call/cls_align_sint16.c: Likewise.
2959         * testsuite/libffi.call/cls_align_float.c: Likewise.
2960         * testsuite/libffi.call/cls_align_double.c: Likewise.
2961         * testsuite/libffi.call/cls_align_longdouble.c: Likewise.
2962         * testsuite/libffi.call/cls_align_pointer.c: Likewise.
2963
2964 2003-12-02  Hosaka Yuji  <hos@tamanegi.org>
2965
2966         PR other/13221
2967         * src/x86/ffi.c (ffi_prep_args, ffi_prep_incoming_args_SYSV):
2968         Align arguments to 32 bits.
2969
2970 2003-12-01  Andreas Tobler  <a.tobler@schweiz.ch>
2971
2972         PR other/13221
2973         * testsuite/libffi.call/cls_multi_sshort.c: New test case.
2974         * testsuite/libffi.call/cls_multi_sshortchar.c: Likewise.
2975         * testsuite/libffi.call/cls_multi_uchar.c: Likewise.
2976         * testsuite/libffi.call/cls_multi_schar.c: Likewise.
2977         * testsuite/libffi.call/cls_multi_ushortchar.c: Likewise.
2978         * testsuite/libffi.call/cls_multi_ushort.c: Likewise.
2979
2980         * testsuite/libffi.special/unwindtest.cc: Cosmetics.
2981
2982 2003-11-26  Kaveh R. Ghazi  <ghazi@caip.rutgers.edu>
2983
2984         * testsuite/libffi.call/ffitest.h: Include <fcntl.h>.
2985         * testsuite/libffi.special/ffitestcxx.h: Likewise.
2986
2987 2003-11-22  Andreas Tobler  <a.tobler@schweiz.ch>
2988
2989         * Makefile.in: Rebuilt.
2990         * configure: Likewise.
2991         * testsuite/libffi.special/unwindtest.cc: Convert the mmap to
2992         the right type.
2993
2994 2003-11-21  Andreas Jaeger  <aj@suse.de>
2995             Andreas Tobler  <a.tobler@schweiz.ch>
2996
2997         * acinclude.m4: Add AC_FUNC_MMAP_BLACKLIST.
2998         * configure.in: Call AC_FUNC_MMAP_BLACKLIST.
2999         * Makefile.in: Rebuilt.
3000         * aclocal.m4: Likewise.
3001         * configure: Likewise.
3002         * fficonfig.h.in: Likewise.
3003         * testsuite/lib/libffi-dg.exp: Add include dir.
3004         * testsuite/libffi.call/ffitest.h: Add MMAP definitions.
3005         * testsuite/libffi.special/ffitestcxx.h: Likewise.
3006         * testsuite/libffi.call/closure_fn0.c: Use MMAP functionality
3007         for ffi_closure if available.
3008         * testsuite/libffi.call/closure_fn1.c: Likewise.
3009         * testsuite/libffi.call/closure_fn2.c: Likewise.
3010         * testsuite/libffi.call/closure_fn3.c: Likewise.
3011         * testsuite/libffi.call/closure_fn4.c: Likewise.
3012         * testsuite/libffi.call/closure_fn5.c: Likewise.
3013         * testsuite/libffi.call/cls_12byte.c: Likewise.
3014         * testsuite/libffi.call/cls_16byte.c: Likewise.
3015         * testsuite/libffi.call/cls_18byte.c: Likewise.
3016         * testsuite/libffi.call/cls_19byte.c: Likewise.
3017         * testsuite/libffi.call/cls_1_1byte.c: Likewise.
3018         * testsuite/libffi.call/cls_20byte.c: Likewise.
3019         * testsuite/libffi.call/cls_20byte1.c: Likewise.
3020         * testsuite/libffi.call/cls_24byte.c: Likewise.
3021         * testsuite/libffi.call/cls_2byte.c: Likewise.
3022         * testsuite/libffi.call/cls_3_1byte.c: Likewise.
3023         * testsuite/libffi.call/cls_3byte1.c: Likewise.
3024         * testsuite/libffi.call/cls_3byte2.c: Likewise.
3025         * testsuite/libffi.call/cls_4_1byte.c: Likewise.
3026         * testsuite/libffi.call/cls_4byte.c: Likewise.
3027         * testsuite/libffi.call/cls_5byte.c: Likewise.
3028         * testsuite/libffi.call/cls_64byte.c: Likewise.
3029         * testsuite/libffi.call/cls_6byte.c: Likewise.
3030         * testsuite/libffi.call/cls_7byte.c: Likewise.
3031         * testsuite/libffi.call/cls_8byte.c: Likewise.
3032         * testsuite/libffi.call/cls_9byte1.c: Likewise.
3033         * testsuite/libffi.call/cls_9byte2.c: Likewise.
3034         * testsuite/libffi.call/cls_double.c: Likewise.
3035         * testsuite/libffi.call/cls_float.c: Likewise.
3036         * testsuite/libffi.call/cls_schar.c: Likewise.
3037         * testsuite/libffi.call/cls_sint.c: Likewise.
3038         * testsuite/libffi.call/cls_sshort.c: Likewise.
3039         * testsuite/libffi.call/cls_uchar.c: Likewise.
3040         * testsuite/libffi.call/cls_uint.c: Likewise.
3041         * testsuite/libffi.call/cls_ulonglong.c: Likewise.
3042         * testsuite/libffi.call/cls_ushort.c: Likewise.
3043         * testsuite/libffi.call/nested_struct.c: Likewise.
3044         * testsuite/libffi.call/nested_struct1.c: Likewise.
3045         * testsuite/libffi.call/nested_struct2.c: Likewise.
3046         * testsuite/libffi.call/nested_struct3.c: Likewise.
3047         * testsuite/libffi.call/problem1.c: Likewise.
3048         * testsuite/libffi.special/unwindtest.cc: Likewise.
3049
3050 2003-11-20  Andreas Tobler  <a.tobler@schweiz.ch>
3051
3052         * testsuite/lib/libffi-dg.exp: Make the -lgcc_s conditional.
3053
3054 2003-11-19  Andreas Tobler  <a.tobler@schweiz.ch>
3055
3056         * testsuite/lib/libffi-dg.exp: Add DYLD_LIBRARY_PATH for darwin.
3057         Add -lgcc_s to additional flags.
3058
3059 2003-11-12  Andreas Tobler  <a.tobler@schweiz.ch>
3060
3061         * configure.in, include/Makefile.am: PR libgcj/11147, install
3062         the ffitarget.h header file in a gcc versioned and target
3063         dependent place.
3064         * configure: Regenerated.
3065         * Makefile.in, include/Makefile.in: Likewise.
3066         * testsuite/Makefile.in: Likewise.
3067
3068 2003-11-09  Andreas Tobler  <a.tobler@schweiz.ch>
3069
3070         * testsuite/libffi.call/closure_fn0.c: Print result and check
3071         with dg-output to make debugging easier.
3072         * testsuite/libffi.call/closure_fn1.c: Likewise.
3073         * testsuite/libffi.call/closure_fn2.c: Likewise.
3074         * testsuite/libffi.call/closure_fn3.c: Likewise.
3075         * testsuite/libffi.call/closure_fn4.c: Likewise.
3076         * testsuite/libffi.call/closure_fn5.c: Likewise.
3077         * testsuite/libffi.call/cls_12byte.c: Likewise.
3078         * testsuite/libffi.call/cls_16byte.c: Likewise.
3079         * testsuite/libffi.call/cls_18byte.c: Likewise.
3080         * testsuite/libffi.call/cls_19byte.c: Likewise.
3081         * testsuite/libffi.call/cls_1_1byte.c: Likewise.
3082         * testsuite/libffi.call/cls_20byte.c: Likewise.
3083         * testsuite/libffi.call/cls_20byte1.c: Likewise.
3084         * testsuite/libffi.call/cls_24byte.c: Likewise.
3085         * testsuite/libffi.call/cls_2byte.c: Likewise.
3086         * testsuite/libffi.call/cls_3_1byte.c: Likewise.
3087         * testsuite/libffi.call/cls_3byte1.c: Likewise.
3088         * testsuite/libffi.call/cls_3byte2.c: Likewise.
3089         * testsuite/libffi.call/cls_4_1byte.c: Likewise.
3090         * testsuite/libffi.call/cls_4byte.c: Likewise.
3091         * testsuite/libffi.call/cls_5byte.c: Likewise.
3092         * testsuite/libffi.call/cls_64byte.c: Likewise.
3093         * testsuite/libffi.call/cls_6byte.c: Likewise.
3094         * testsuite/libffi.call/cls_7byte.c: Likewise.
3095         * testsuite/libffi.call/cls_8byte.c: Likewise.
3096         * testsuite/libffi.call/cls_9byte1.c: Likewise.
3097         * testsuite/libffi.call/cls_9byte2.c: Likewise.
3098         * testsuite/libffi.call/cls_double.c: Likewise.
3099         * testsuite/libffi.call/cls_float.c: Likewise.
3100         * testsuite/libffi.call/cls_schar.c: Likewise.
3101         * testsuite/libffi.call/cls_sint.c: Likewise.
3102         * testsuite/libffi.call/cls_sshort.c: Likewise.
3103         * testsuite/libffi.call/cls_uchar.c: Likewise.
3104         * testsuite/libffi.call/cls_uint.c: Likewise.
3105         * testsuite/libffi.call/cls_ulonglong.c: Likewise.
3106         * testsuite/libffi.call/cls_ushort.c: Likewise.
3107         * testsuite/libffi.call/problem1.c: Likewise.
3108
3109         * testsuite/libffi.special/unwindtest.cc: Make ffi_closure
3110         static.
3111
3112 2003-11-08  Andreas Tobler  <a.tobler@schweiz.ch>
3113
3114         * testsuite/libffi.call/cls_9byte2.c: New test case.
3115         * testsuite/libffi.call/cls_9byte1.c: Likewise.
3116         * testsuite/libffi.call/cls_64byte.c: Likewise.
3117         * testsuite/libffi.call/cls_20byte1.c: Likewise.
3118         * testsuite/libffi.call/cls_19byte.c: Likewise.
3119         * testsuite/libffi.call/cls_18byte.c: Likewise.
3120         * testsuite/libffi.call/closure_fn4.c: Likewise.
3121         * testsuite/libffi.call/closure_fn5.c: Likewise.
3122         * testsuite/libffi.call/cls_schar.c: Likewise.
3123         * testsuite/libffi.call/cls_sint.c: Likewise.
3124         * testsuite/libffi.call/cls_sshort.c: Likewise.
3125         * testsuite/libffi.call/nested_struct2.c: Likewise.
3126         * testsuite/libffi.call/nested_struct3.c: Likewise.
3127
3128 2003-11-08  Andreas Tobler  <a.tobler@schweiz.ch>
3129
3130         * testsuite/libffi.call/cls_double.c: Do a check on the result.
3131         * testsuite/libffi.call/cls_uchar.c: Likewise.
3132         * testsuite/libffi.call/cls_uint.c: Likewise.
3133         * testsuite/libffi.call/cls_ulonglong.c: Likewise.
3134         * testsuite/libffi.call/cls_ushort.c: Likewise.
3135         * testsuite/libffi.call/return_sc.c: Cleanup whitespaces.
3136
3137 2003-11-06  Andreas Tobler  <a.tobler@schweiz.ch>
3138
3139         * src/prep_cif.c (ffi_prep_cif): Move the validity check after
3140         the initialization.
3141
3142 2003-10-23  Andreas Tobler  <a.tobler@schweiz.ch>
3143
3144         * src/java_raw_api.c (ffi_java_ptrarray_to_raw): Replace
3145         FFI_ASSERT(FALSE) with FFI_ASSERT(0).
3146
3147 2003-10-22  David Daney  <ddaney@avtrex.com>
3148
3149         * src/mips/ffitarget.h: Replace undefined UINT32 and friends with
3150         __attribute__((__mode__(__SI__))) and friends.
3151
3152 2003-10-22  Andreas Schwab  <schwab@suse.de>
3153
3154         * src/ia64/ffi.c: Replace FALSE/TRUE with false/true.
3155
3156 2003-10-21  Andreas Tobler  <a.tobler@schweiz.ch>
3157
3158         * configure.in: AC_LINK_FILES(ffitarget.h).
3159         * configure: Regenerate.
3160         * Makefile.in: Likewise.
3161         * include/Makefile.in: Likewise.
3162         * testsuite/Makefile.in: Likewise.
3163         * fficonfig.h.in: Likewise.
3164
3165 2003-10-21  Paolo Bonzini  <bonzini@gnu.org>
3166             Richard Henderson  <rth@redhat.com>
3167
3168         Avoid that ffi.h includes fficonfig.h.
3169
3170         * Makefile.am (EXTRA_DIST): Include ffitarget.h files
3171         (TARGET_SRC_MIPS_GCC): Renamed to TARGET_SRC_MIPS_IRIX.
3172         (TARGET_SRC_MIPS_SGI): Removed.
3173         (MIPS_GCC): Renamed to TARGET_SRC_MIPS_IRIX.
3174         (MIPS_SGI): Removed.
3175         (CLEANFILES): Removed.
3176         (mostlyclean-am, clean-am, mostlyclean-sub, clean-sub): New
3177         targets.
3178         * acconfig.h: Removed.
3179         * configure.in: Compute sizeofs only for double and long double.
3180         Use them to define and subst HAVE_LONG_DOUBLE.  Include comments
3181         into AC_DEFINE instead of using acconfig.h.  Create
3182         include/ffitarget.h instead of include/fficonfig.h.  Rename
3183         MIPS_GCC to MIPS_IRIX, drop MIPS_SGI since we are in gcc's tree.
3184         AC_DEFINE EH_FRAME_FLAGS.
3185         * include/Makefile.am (DISTCLEANFILES): New automake macro.
3186         (hack_DATA): Add ffitarget.h.
3187         * include/ffi.h.in: Remove all system specific definitions.
3188         Declare raw API even if it is not installed, why bother?
3189         Use limits.h instead of SIZEOF_* to define ffi_type_*.  Do
3190         not define EH_FRAME_FLAGS, it is in fficonfig.h now.  Include
3191         ffitarget.h instead of fficonfig.h.  Remove ALIGN macro.
3192         (UINT_ARG, INT_ARG): Removed, use ffi_arg and ffi_sarg instead.
3193         * include/ffi_common.h (bool): Do not define.
3194         (ffi_assert): Accept failed assertion.
3195         (ffi_type_test): Return void and accept file/line.
3196         (FFI_ASSERT): Pass stringized failed assertion.
3197         (FFI_ASSERT_AT): New macro.
3198         (FFI_ASSERT_VALID_TYPE): New macro.
3199         (UINT8, SINT8, UINT16, SINT16, UINT32, SINT32,
3200         UINT64, SINT64): Define here with gcc's __attribute__ macro
3201         instead of in ffi.h
3202         (FLOAT32, ALIGN): Define here instead of in ffi.h
3203         * include/ffi-mips.h: Removed.  Its content moved to
3204         src/mips/ffitarget.h after separating assembly and C sections.
3205         * src/alpha/ffi.c, src/alpha/ffi.c, src/java_raw_api.c
3206         src/prep_cif.c, src/raw_api.c, src/ia64/ffi.c,
3207         src/mips/ffi.c, src/mips/n32.S, src/mips/o32.S,
3208         src/mips/ffitarget.h, src/sparc/ffi.c, src/x86/ffi64.c:
3209         SIZEOF_ARG -> FFI_SIZEOF_ARG.
3210         * src/ia64/ffi.c: Include stdbool.h (provided by GCC 2.95+).
3211         * src/debug.c (ffi_assert): Accept stringized failed assertion.
3212         (ffi_type_test): Rewritten.
3213         * src/prep-cif.c (initialize_aggregate, ffi_prep_cif): Call
3214         FFI_ASSERT_VALID_TYPE.
3215         * src/alpha/ffitarget.h, src/arm/ffitarget.h,
3216         src/ia64/ffitarget.h, src/m68k/ffitarget.h,
3217         src/mips/ffitarget.h, src/powerpc/ffitarget.h,
3218         src/s390/ffitarget.h, src/sh/ffitarget.h,
3219         src/sh64/ffitarget.h, src/sparc/ffitarget.h,
3220         src/x86/ffitarget.h: New files.
3221         * src/alpha/osf.S, src/arm/sysv.S, src/ia64/unix.S,
3222         src/m68k/sysv.S, src/mips/n32.S, src/mips/o32.S,
3223         src/powerpc/aix.S, src/powerpc/darwin.S,
3224         src/powerpc/ffi_darwin.c, src/powerpc/linux64.S,
3225         src/powerpc/linux64_closure.S, src/powerpc/ppc_closure.S,
3226         src/powerpc/sysv.S, src/s390/sysv.S, src/sh/sysv.S,
3227         src/sh64/sysv.S, src/sparc/v8.S, src/sparc/v9.S,
3228         src/x86/sysv.S, src/x86/unix64.S, src/x86/win32.S:
3229         include fficonfig.h
3230
3231 2003-10-20  Rainer Orth  <ro@TechFak.Uni-Bielefeld.DE>
3232
3233         * src/mips/ffi.c: Use _ABIN32, _ABIO32 instead of external
3234         _MIPS_SIM_NABI32, _MIPS_SIM_ABI32.
3235
3236 2003-10-19  Andreas Tobler  <a.tobler@schweiz.ch>
3237
3238         * src/powerpc/ffi_darwin.c (ffi_prep_args): Declare bytes again.
3239         Used when FFI_DEBUG = 1.
3240
3241 2003-10-14  Alan Modra  <amodra@bigpond.net.au>
3242
3243         * src/types.c (double, longdouble): Default POWERPC64 to 8 byte size
3244         and align.
3245
3246 2003-10-06  Rainer Orth  <ro@TechFak.Uni-Bielefeld.DE>
3247
3248         * include/ffi_mips.h: Define FFI_MIPS_N32 for N32/N64 ABIs,
3249         FFI_MIPS_O32 for O32 ABI.
3250
3251 2003-10-01  Andreas Tobler  <a.tobler@schweiz.ch>
3252
3253         * testsuite/lib/libffi-dg.exp: Set LD_LIBRARY_PATH_64 for
3254         SPARC64. Cleanup whitespaces.
3255
3256 2003-09-19  Andreas Tobler  <a.tobler@schweiz.ch>
3257
3258         * testsuite/libffi.call/closure_fn0.c: Xfail mips, arm,
3259         strongarm, xscale. Cleanup whitespaces.
3260         * testsuite/libffi.call/closure_fn1.c: Likewise.
3261         * testsuite/libffi.call/closure_fn2.c: Likewise.
3262         * testsuite/libffi.call/closure_fn3.c: Likewise.
3263         * testsuite/libffi.call/cls_12byte.c: Likewise.
3264         * testsuite/libffi.call/cls_16byte.c: Likewise.
3265         * testsuite/libffi.call/cls_1_1byte.c: Likewise.
3266         * testsuite/libffi.call/cls_20byte.c: Likewise.
3267         * testsuite/libffi.call/cls_24byte.c: Likewise.
3268         * testsuite/libffi.call/cls_2byte.c: Likewise.
3269         * testsuite/libffi.call/cls_3_1byte.c: Likewise.
3270         * testsuite/libffi.call/cls_3byte1.c: Likewise.
3271         * testsuite/libffi.call/cls_3byte2.c: Likewise.
3272         * testsuite/libffi.call/cls_4_1byte.c: Likewise.
3273         * testsuite/libffi.call/cls_4byte.c: Likewise.
3274         * testsuite/libffi.call/cls_5byte.c: Likewise.
3275         * testsuite/libffi.call/cls_6byte.c: Likewise.
3276         * testsuite/libffi.call/cls_7byte.c: Likewise.
3277         * testsuite/libffi.call/cls_8byte.c: Likewise.
3278         * testsuite/libffi.call/cls_double.c: Likewise.
3279         * testsuite/libffi.call/cls_float.c: Likewise.
3280         * testsuite/libffi.call/cls_uchar.c: Likewise.
3281         * testsuite/libffi.call/cls_uint.c: Likewise.
3282         * testsuite/libffi.call/cls_ulonglong.c: Likewise.
3283         * testsuite/libffi.call/cls_ushort.c: Likewise.
3284         * testsuite/libffi.call/nested_struct.c: Likewise.
3285         * testsuite/libffi.call/nested_struct1.c: Likewise.
3286         * testsuite/libffi.call/problem1.c: Likewise.
3287         * testsuite/libffi.special/unwindtest.cc: Likewise.
3288         * testsuite/libffi.call/pyobjc-tc.c: Cleanup whitespaces.
3289
3290 2003-09-18  David Edelsohn  <edelsohn@gnu.org>
3291
3292         * src/powerpc/aix.S: Cleanup whitespaces.
3293         * src/powerpc/aix_closure.S: Likewise.
3294
3295 2003-09-18  Andreas Tobler  <a.tobler@schweiz.ch>
3296
3297         * src/powerpc/darwin.S: Cleanup whitespaces, comment formatting.
3298         * src/powerpc/darwin_closure.S: Likewise.
3299         * src/powerpc/ffi_darwin.c: Likewise.
3300
3301 2003-09-18  Andreas Tobler  <a.tobler@schweiz.ch>
3302             David Edelsohn  <edelsohn@gnu.org>
3303
3304         * src/types.c (double): Add AIX and Darwin to the right TYPEDEF.
3305         * src/powerpc/aix_closure.S: Remove the pointer to the outgoing
3306         parameter stack.
3307         * src/powerpc/darwin_closure.S: Likewise.
3308         * src/powerpc/ffi_darwin.c (ffi_prep_args): Handle structures
3309         according to the Darwin/AIX ABI.
3310         (ffi_prep_cif_machdep): Likewise.
3311         (ffi_closure_helper_DARWIN): Likewise.
3312         Remove the outgoing parameter stack logic. Simplify the evaluation
3313         of the different CASE types.
3314         (ffi_prep_clousure): Avoid the casts on lvalues. Change the branch
3315         statement in the trampoline code.
3316
3317 2003-09-18  Kaz Kojima  <kkojima@gcc.gnu.org>
3318
3319         * src/sh/ffi.c (ffi_prep_args): Take account into the alignement
3320         for the register size.
3321         (ffi_closure_helper_SYSV): Handle the structure return value
3322         address correctly.
3323         (ffi_closure_helper_SYSV): Return the appropriate type when
3324         the registers are used for the structure return value.
3325         * src/sh/sysv.S (ffi_closure_SYSV): Fix the stack layout for
3326         the 64-bit return value.  Update copyright years.
3327
3328 2003-09-17  Rainer Orth  <ro@TechFak.Uni-Bielefeld.DE>
3329
3330         * testsuite/lib/libffi-dg.exp (libffi_target_compile): Search in
3331         srcdir for ffi_mips.h.
3332
3333 2003-09-12  Alan Modra  <amodra@bigpond.net.au>
3334
3335         * src/prep_cif.c (initialize_aggregate): Include tail padding in
3336         structure size.
3337         * src/powerpc/linux64_closure.S (ffi_closure_LINUX64): Correct
3338         placement of float result.
3339         * testsuite/libffi.special/unwindtest.cc (closure_test_fn1): Correct
3340         cast of "resp" for big-endian 64 bit machines.
3341
3342 2003-09-11  Alan Modra  <amodra@bigpond.net.au>
3343
3344         * src/types.c (double, longdouble): Merge identical SH and ARM
3345         typedefs, and add POWERPC64.
3346         * src/powerpc/ffi.c (ffi_prep_args64): Correct next_arg calc for
3347         struct split over gpr and rest.
3348         (ffi_prep_cif_machdep): Correct intarg_count for structures.
3349         * src/powerpc/linux64.S (ffi_call_LINUX64): Fix gpr offsets.
3350
3351 2003-09-09  Andreas Tobler  <a.tobler@schweiz.ch>
3352
3353         * src/powerpc/ffi.c (ffi_closure_helper_SYSV) Handle struct
3354         passing correctly.
3355
3356 2003-09-09  Alan Modra  <amodra@bigpond.net.au>
3357
3358         * configure: Regenerate.
3359
3360 2003-09-04  Andreas Tobler  <a.tobler@schweiz.ch>
3361
3362         * Makefile.am: Remove build rules for ffitest.
3363         * Makefile.in: Rebuilt.
3364
3365 2003-09-04  Andreas Tobler  <a.tobler@schweiz.ch>
3366
3367         * src/java_raw_api.c: Include <stdlib.h> to fix compiler warning
3368         about implicit declaration of abort().
3369
3370 2003-09-04  Andreas Tobler  <a.tobler@schweiz.ch>
3371
3372         * Makefile.am: Add dejagnu test framework. Fixes PR other/11411.
3373         * Makefile.in: Rebuilt.
3374         * configure.in: Add dejagnu test framework.
3375         * configure: Rebuilt.
3376
3377         * testsuite/Makefile.am: New file.
3378         * testsuite/Makefile.in: Built
3379         * testsuite/lib/libffi-dg.exp: New file.
3380         * testsuite/config/default.exp: Likewise.
3381         * testsuite/libffi.call/call.exp: Likewise.
3382         * testsuite/libffi.call/ffitest.h: Likewise.
3383         * testsuite/libffi.call/closure_fn0.c: Likewise.
3384         * testsuite/libffi.call/closure_fn1.c: Likewise.
3385         * testsuite/libffi.call/closure_fn2.c: Likewise.
3386         * testsuite/libffi.call/closure_fn3.c: Likewise.
3387         * testsuite/libffi.call/cls_1_1byte.c: Likewise.
3388         * testsuite/libffi.call/cls_3_1byte.c: Likewise.
3389         * testsuite/libffi.call/cls_4_1byte.c: Likewise.
3390         * testsuite/libffi.call/cls_2byte.c: Likewise.
3391         * testsuite/libffi.call/cls_3byte1.c: Likewise.
3392         * testsuite/libffi.call/cls_3byte2.c: Likewise.
3393         * testsuite/libffi.call/cls_4byte.c: Likewise.
3394         * testsuite/libffi.call/cls_5byte.c: Likewise.
3395         * testsuite/libffi.call/cls_6byte.c: Likewise.
3396         * testsuite/libffi.call/cls_7byte.c: Likewise.
3397         * testsuite/libffi.call/cls_8byte.c: Likewise.
3398         * testsuite/libffi.call/cls_12byte.c: Likewise.
3399         * testsuite/libffi.call/cls_16byte.c: Likewise.
3400         * testsuite/libffi.call/cls_20byte.c: Likewise.
3401         * testsuite/libffi.call/cls_24byte.c: Likewise.
3402         * testsuite/libffi.call/cls_double.c: Likewise.
3403         * testsuite/libffi.call/cls_float.c: Likewise.
3404         * testsuite/libffi.call/cls_uchar.c: Likewise.
3405         * testsuite/libffi.call/cls_uint.c: Likewise.
3406         * testsuite/libffi.call/cls_ulonglong.c: Likewise.
3407         * testsuite/libffi.call/cls_ushort.c: Likewise.
3408         * testsuite/libffi.call/float.c: Likewise.
3409         * testsuite/libffi.call/float1.c: Likewise.
3410         * testsuite/libffi.call/float2.c: Likewise.
3411         * testsuite/libffi.call/many.c: Likewise.
3412         * testsuite/libffi.call/many_win32.c: Likewise.
3413         * testsuite/libffi.call/nested_struct.c: Likewise.
3414         * testsuite/libffi.call/nested_struct1.c: Likewise.
3415         * testsuite/libffi.call/pyobjc-tc.c: Likewise.
3416         * testsuite/libffi.call/problem1.c: Likewise.
3417         * testsuite/libffi.call/promotion.c: Likewise.
3418         * testsuite/libffi.call/return_ll.c: Likewise.
3419         * testsuite/libffi.call/return_sc.c: Likewise.
3420         * testsuite/libffi.call/return_uc.c: Likewise.
3421         * testsuite/libffi.call/strlen.c: Likewise.
3422         * testsuite/libffi.call/strlen_win32.c: Likewise.
3423         * testsuite/libffi.call/struct1.c: Likewise.
3424         * testsuite/libffi.call/struct2.c: Likewise.
3425         * testsuite/libffi.call/struct3.c: Likewise.
3426         * testsuite/libffi.call/struct4.c: Likewise.
3427         * testsuite/libffi.call/struct5.c: Likewise.
3428         * testsuite/libffi.call/struct6.c: Likewise.
3429         * testsuite/libffi.call/struct7.c: Likewise.
3430         * testsuite/libffi.call/struct8.c: Likewise.
3431         * testsuite/libffi.call/struct9.c: Likewise.
3432         * testsuite/libffi.special/special.exp: New file.
3433         * testsuite/libffi.special/ffitestcxx.h: Likewise.
3434         * testsuite/libffi.special/unwindtest.cc: Likewise.
3435
3436
3437 2003-08-13  Kaz Kojima  <kkojima@gcc.gnu.org>
3438
3439         * src/sh/ffi.c (OFS_INT16): Set 0 for little endian case.  Update
3440         copyright years.
3441
3442 2003-08-02  Alan Modra  <amodra@bigpond.net.au>
3443
3444         * src/powerpc/ffi.c (ffi_prep_args64): Modify for changed gcc
3445         structure passing.
3446         (ffi_closure_helper_LINUX64): Likewise.
3447         * src/powerpc/linux64.S: Remove code writing to parm save area.
3448         * src/powerpc/linux64_closure.S (ffi_closure_LINUX64): Use return
3449         address in lr from ffi_closure_helper_LINUX64 call to calculate
3450         table address.  Optimize function tail.
3451
3452 2003-07-28  Andreas Tobler  <a.tobler@schweiz.ch>
3453
3454         * src/sparc/ffi.c: Handle all floating point registers.
3455         * src/sparc/v9.S: Likewise. Fixes second part of PR target/11410.
3456
3457 2003-07-11  Gerald Pfeifer  <pfeifer@dbai.tuwien.ac.at>
3458
3459         * README: Note that libffi is not part of GCC.  Update the project
3460         URL and status.
3461
3462 2003-06-19  Franz Sirl  <Franz.Sirl-kernel@lauterbach.com>
3463
3464         * src/powerpc/ppc_closure.S: Include ffi.h.
3465
3466 2003-06-13  Rainer Orth  <ro@TechFak.Uni-Bielefeld.DE>
3467
3468         * src/x86/sysv.S: Avoid gas-only .uleb128/.sleb128 directives.
3469         Use C style comments.
3470
3471 2003-06-13  Kaz Kojima  <kkojima@rr.iij4u.or.jp>
3472
3473         * Makefile.am: Add SHmedia support.  Fix a typo of SH support.
3474         * Makefile.in: Regenerate.
3475         * configure.in (sh64-*-linux*, sh5*-*-linux*): Add target.
3476         * configure: Regenerate.
3477         * include/ffi.h.in: Add SHmedia support.
3478         * src/sh64/ffi.c: New file.
3479         * src/sh64/sysv.S: New file.
3480
3481 2003-05-16  Jakub Jelinek  <jakub@redhat.com>
3482
3483         * configure.in (HAVE_RO_EH_FRAME): Check whether .eh_frame section
3484         should be read-only.
3485         * configure: Rebuilt.
3486         * fficonfig.h.in: Rebuilt.
3487         * include/ffi.h.in (EH_FRAME_FLAGS): Define.
3488         * src/alpha/osf.S: Use EH_FRAME_FLAGS.
3489         * src/powerpc/linux64.S: Likewise.
3490         * src/powerpc/linux64_closure.S: Likewise.  Include ffi.h.
3491         * src/powerpc/sysv.S: Use EH_FRAME_FLAGS.  Use pcrel encoding
3492         if -fpic/-fPIC/-mrelocatable.
3493         * src/powerpc/powerpc_closure.S: Likewise.
3494         * src/sparc/v8.S: If HAVE_RO_EH_FRAME is defined, don't include
3495         #write in .eh_frame flags.
3496         * src/sparc/v9.S: Likewise.
3497         * src/x86/unix64.S: Use EH_FRAME_FLAGS.
3498         * src/x86/sysv.S: Likewise.  Use pcrel encoding if -fpic/-fPIC.
3499         * src/s390/sysv.S: Use EH_FRAME_FLAGS.  Include ffi.h.
3500
3501 2003-05-07  Jeff Sturm  <jsturm@one-point.com>
3502
3503         Fixes PR bootstrap/10656
3504         * configure.in (HAVE_AS_REGISTER_PSEUDO_OP): Test assembler
3505         support for .register pseudo-op.
3506         * src/sparc/v8.S: Use it.
3507         * fficonfig.h.in: Rebuilt.
3508         * configure: Rebuilt.
3509
3510 2003-04-18  Jakub Jelinek  <jakub@redhat.com>
3511
3512         * include/ffi.h.in (POWERPC64): Define if 64-bit.
3513         (enum ffi_abi): Add FFI_LINUX64 on POWERPC.
3514         Make it the default on POWERPC64.
3515         (FFI_TRAMPOLINE_SIZE): Define to 24 on POWERPC64.
3516         * configure.in: Change powerpc-*-linux* into powerpc*-*-linux*.
3517         * configure: Rebuilt.
3518         * src/powerpc/ffi.c (hidden): Define.
3519         (ffi_prep_args_SYSV): Renamed from
3520         ffi_prep_args.  Cast pointers to unsigned long to shut up warnings.
3521         (NUM_GPR_ARG_REGISTERS64, NUM_FPR_ARG_REGISTERS64,
3522         ASM_NEEDS_REGISTERS64): New.
3523         (ffi_prep_args64): New function.
3524         (ffi_prep_cif_machdep): Handle FFI_LINUX64 ABI.
3525         (ffi_call): Likewise.
3526         (ffi_prep_closure): Likewise.
3527         (flush_icache): Surround by #ifndef POWERPC64.
3528         (ffi_dblfl): New union type.
3529         (ffi_closure_helper_SYSV): Use it to avoid aliasing problems.
3530         (ffi_closure_helper_LINUX64): New function.
3531         * src/powerpc/ppc_closure.S: Surround whole file by #ifndef
3532         __powerpc64__.
3533         * src/powerpc/sysv.S: Likewise.
3534         (ffi_call_SYSV): Rename ffi_prep_args to ffi_prep_args_SYSV.
3535         * src/powerpc/linux64.S: New file.
3536         * src/powerpc/linux64_closure.S: New file.
3537         * Makefile.am (EXTRA_DIST): Add src/powerpc/linux64.S and
3538         src/powerpc/linux64_closure.S.
3539         (TARGET_SRC_POWERPC): Likewise.
3540
3541         * src/ffitest.c (closure_test_fn, closure_test_fn1, closure_test_fn2,
3542         closure_test_fn3): Fix result printing on big-endian 64-bit
3543         machines.
3544         (main): Print tst2_arg instead of uninitialized tst2_result.
3545
3546         * src/ffitest.c (main): Hide what closure pointer really points to
3547         from the compiler.
3548
3549 2003-04-16  Richard Earnshaw  <rearnsha@arm.com>
3550
3551         * configure.in (arm-*-netbsdelf*): Add configuration.
3552         (configure): Regenerated.
3553
3554 2003-04-04  Loren J. Rittle  <ljrittle@acm.org>
3555
3556         * include/Makefile.in: Regenerate.
3557
3558 2003-03-21  Zdenek Dvorak  <rakdver@atrey.karlin.mff.cuni.cz>
3559
3560         * libffi/include/ffi.h.in: Define X86 instead of X86_64 in 32
3561         bit mode.
3562         * libffi/src/x86/ffi.c (ffi_closure_SYSV, ffi_closure_raw_SYSV):
3563         Receive closure pointer through parameter, read args using
3564         __builtin_dwarf_cfa.
3565         (FFI_INIT_TRAMPOLINE): Send closure reference through eax.
3566
3567 2003-03-12  Andreas Schwab  <schwab@suse.de>
3568
3569         * configure.in: Avoid trailing /. in toolexeclibdir.
3570         * configure: Rebuilt.
3571
3572 2003-03-03  Andreas Tobler <a.tobler@schweiz.ch>
3573
3574         * src/powerpc/darwin_closure.S: Recode to fit dynamic libraries.
3575
3576 2003-02-06  Andreas Tobler <a.tobler@schweiz.ch>
3577
3578         * libffi/src/powerpc/darwin_closure.S:
3579         Fix alignement bug, allocate 8 bytes for the result.
3580         * libffi/src/powerpc/aix_closure.S:
3581         Likewise.
3582         * libffi/src/powerpc/ffi_darwin.c:
3583         Update stackframe description for aix/darwin_closure.S.
3584
3585 2003-02-06  Jakub Jelinek  <jakub@redhat.com>
3586
3587         * src/s390/ffi.c (ffi_closure_helper_SYSV): Add hidden visibility
3588         attribute.
3589
3590 2003-01-31  Christian Cornelssen  <ccorn@cs.tu-berlin.de>,
3591             Andreas Schwab  <schwab@suse.de>
3592
3593         * configure.in: Adjust command to source config-ml.in to account
3594         for changes to the libffi_basedir definition.
3595         (libffi_basedir): Remove ${srcdir} from value and include trailing
3596         slash if nonempty.
3597
3598         * configure: Regenerate.
3599
3600 2003-01-29  Franz Sirl  <Franz.Sirl-kernel@lauterbach.com>
3601
3602         * src/powerpc/ppc_closure.S: Recode to fit shared libs.
3603
3604 2003-01-28  Andrew Haley  <aph@redhat.com>
3605
3606         * include/ffi.h.in: Enable FFI_CLOSURES for x86_64.
3607         * src/x86/ffi64.c (ffi_prep_closure): New.
3608         (ffi_closure_UNIX64_inner): New.
3609         * src/x86/unix64.S (ffi_closure_UNIX64): New.
3610
3611 2003-01-27  Alexandre Oliva  <aoliva@redhat.com>
3612
3613         * configure.in (toolexecdir, toolexeclibdir): Set and AC_SUBST.
3614         Remove USE_LIBDIR conditional.
3615         * Makefile.am (toolexecdir, toolexeclibdir): Don't override.
3616         * Makefile.in, configure: Rebuilt.
3617
3618 2003-01027  David Edelsohn  <edelsohn@gnu.org>
3619
3620         * Makefile.am (TARGET_SRC_POWERPC_AIX): Fix typo.
3621         * Makefile.in: Regenerate.
3622
3623 2003-01-22  Andrew Haley  <aph@redhat.com>
3624
3625         * src/powerpc/darwin.S (_ffi_call_AIX): Add Augmentation size to
3626         unwind info.
3627
3628 2003-01-21  Andreas Tobler  <a.tobler@schweiz.ch>
3629
3630         * src/powerpc/darwin.S: Add unwind info.
3631         * src/powerpc/darwin_closure.S: Likewise.
3632
3633 2003-01-14  Andrew Haley  <aph@redhat.com>
3634
3635         * src/x86/ffi64.c (ffi_prep_args): Check for void retval.
3636         (ffi_prep_cif_machdep): Likewise.
3637         * src/x86/unix64.S: Add unwind info.
3638
3639 2003-01-14  Andreas Jaeger  <aj@suse.de>
3640
3641         * src/ffitest.c (main): Only use ffi_closures if those are
3642         supported.
3643
3644 2003-01-13 Andreas Tobler <a.tobler@schweiz.ch>
3645
3646         * libffi/src/ffitest.c
3647          add closure testcases
3648
3649 2003-01-13 Kevin B. Hendricks <khendricks@ivey.uwo.ca>
3650
3651         * libffi/src/powerpc/ffi.c
3652          fix alignment bug for float (4 byte aligned iso 8 byte)
3653
3654 2003-01-09  Geoffrey Keating  <geoffk@apple.com>
3655
3656         * src/powerpc/ffi_darwin.c: Remove RCS version string.
3657         * src/powerpc/darwin.S: Remove RCS version string.
3658
3659 2003-01-03  Jeff Sturm  <jsturm@one-point.com>
3660
3661         * include/ffi.h.in: Add closure defines for SPARC, SPARC64.
3662         * src/ffitest.c (main): Use static storage for closure.
3663         * src/sparc/ffi.c (ffi_prep_closure, ffi_closure_sparc_inner): New.
3664         * src/sparc/v8.S (ffi_closure_v8): New.
3665         * src/sparc/v9.S (ffi_closure_v9): New.
3666
3667 2002-11-10  Ranjit Mathew <rmathew@hotmail.com>
3668
3669         * include/ffi.h.in: Added FFI_STDCALL ffi_type
3670           enumeration for X86_WIN32.
3671         * src/x86/win32.S: Added ffi_call_STDCALL function
3672           definition.
3673         * src/x86/ffi.c (ffi_call/ffi_raw_call): Added
3674           switch cases for recognising FFI_STDCALL and
3675           calling ffi_call_STDCALL if target is X86_WIN32.
3676         * src/ffitest.c (my_stdcall_strlen/stdcall_many):
3677           stdcall versions of the "my_strlen" and "many"
3678           test functions (for X86_WIN32).
3679           Added test cases to test stdcall invocation using
3680           these functions.
3681
3682 2002-12-02  Kaz Kojima  <kkojima@gcc.gnu.org>
3683
3684         * src/sh/sysv.S: Add DWARF2 unwind info.
3685
3686 2002-11-27  Ulrich Weigand  <uweigand@de.ibm.com>
3687
3688         * src/s390/sysv.S (.eh_frame section): Make section read-only.
3689
3690 2002-11-26  Jim Wilson  <wilson@redhat.com>
3691
3692         * src/types.c (FFI_TYPE_POINTER): Has size 8 on IA64.
3693
3694 2002-11-23  H.J. Lu <hjl@gnu.org>
3695
3696         * acinclude.m4: Add dummy AM_PROG_LIBTOOL.
3697         Include ../config/accross.m4.
3698         * aclocal.m4; Rebuild.
3699         * configure: Likewise.
3700
3701 2002-11-15  Ulrich Weigand  <uweigand@de.ibm.com>
3702
3703         * src/s390/sysv.S (.eh_frame section): Adapt to pcrel FDE encoding.
3704
3705 2002-11-11  DJ Delorie  <dj@redhat.com>
3706
3707         * configure.in: Look for common files in the right place.
3708
3709 2002-10-08  Ulrich Weigand  <uweigand@de.ibm.com>
3710
3711         * src/java_raw_api.c (ffi_java_raw_to_ptrarray): Interpret
3712         raw data as _Jv_word values, not ffi_raw.
3713         (ffi_java_ptrarray_to_raw): Likewise.
3714         (ffi_java_rvalue_to_raw): New function.
3715         (ffi_java_raw_call): Call it.
3716         (ffi_java_raw_to_rvalue): New function.
3717         (ffi_java_translate_args): Call it.
3718         * src/ffitest.c (closure_test_fn): Interpret return value
3719         as ffi_arg, not int.
3720         * src/s390/ffi.c (ffi_prep_cif_machdep): Add missing
3721         FFI_TYPE_POINTER case.
3722         (ffi_closure_helper_SYSV): Likewise.  Also, assume return
3723         values extended to word size.
3724
3725 2002-10-02  Andreas Jaeger  <aj@suse.de>
3726
3727         * src/x86/ffi64.c (ffi_prep_cif_machdep): Remove debug output.
3728
3729 2002-10-01  Bo Thorsen  <bo@smetana.suse.de>
3730
3731         * include/ffi.h.in: Fix i386 win32 compilation.
3732
3733 2002-09-30  Ulrich Weigand  <uweigand@de.ibm.com>
3734
3735         * configure.in: Add s390x-*-linux-* target.
3736         * configure: Regenerate.
3737         * include/ffi.h.in: Define S390X for s390x targets.
3738         (FFI_CLOSURES): Define for s390/s390x.
3739         (FFI_TRAMPOLINE_SIZE): Likewise.
3740         (FFI_NATIVE_RAW_API): Likewise.
3741         * src/prep_cif.c (ffi_prep_cif): Do not compute stack space for s390.
3742         * src/types.c (FFI_TYPE_POINTER): Use 8-byte pointers on s390x.
3743         * src/s390/ffi.c: Major rework of existing code.  Add support for
3744         s390x targets.  Add closure support.
3745         * src/s390/sysv.S: Likewise.
3746
3747 2002-09-29  Richard Earnshaw  <rearnsha@arm.com>
3748
3749         * src/arm/sysv.S: Fix typo.
3750
3751 2002-09-28  Richard Earnshaw  <rearnsha@arm.com>
3752
3753         * src/arm/sysv.S: If we don't have machine/asm.h and the pre-processor
3754         has defined __USER_LABEL_PREFIX__, then use it in CNAME.
3755         (ffi_call_SYSV): Handle soft-float.
3756
3757 2002-09-27  Bo Thorsen  <bo@suse.de>
3758
3759         * include/ffi.h.in: Fix multilib x86-64 support.
3760
3761 2002-09-22  Kaveh R. Ghazi  <ghazi@caip.rutgers.edu>
3762
3763         * Makefile.am (all-multi): Fix multilib parallel build.
3764
3765 2002-07-19  Kaz Kojima  <kkojima@gcc.gnu.org>
3766
3767         * configure.in (sh[34]*-*-linux*): Add brackets.
3768         * configure: Regenerate.
3769
3770 2002-07-18  Kaz Kojima  <kkojima@gcc.gnu.org>
3771
3772         * Makefile.am: Add SH support.
3773         * Makefile.in: Regenerate.
3774         * configure.in (sh-*-linux*, sh[34]*-*-linux*): Add target.
3775         * configure: Regenerate.
3776         * include/ffi.h.in: Add SH support.
3777         * src/sh/ffi.c: New file.
3778         * src/sh/sysv.S: New file.
3779         * src/types.c: Add SH support.
3780
3781 2002-07-16  Bo Thorsen  <bo@suse.de>
3782
3783         * src/x86/ffi64.c: New file that adds x86-64 support.
3784         * src/x86/unix64.S: New file that handles argument setup for
3785         x86-64.
3786         * src/x86/sysv.S: Don't use this on x86-64.
3787         * src/x86/ffi.c: Don't use this on x86-64.
3788         Remove unused vars.
3789         * src/prep_cif.c (ffi_prep_cif): Don't do stack size calculation
3790         for x86-64.
3791         * src/ffitest.c (struct6): New test that tests a special case in
3792         the x86-64 ABI.
3793         (struct7): Likewise.
3794         (struct8): Likewise.
3795         (struct9): Likewise.
3796         (closure_test_fn): Silence warning about this when it's not used.
3797         (main): Add the new tests.
3798         (main): Fix a couple of wrong casts and silence some compiler warnings.
3799         * include/ffi.h.in: Add x86-64 ABI definition.
3800         * fficonfig.h.in: Regenerate.
3801         * Makefile.am: Add x86-64 support.
3802         * configure.in: Likewise.
3803         * Makefile.in: Regenerate.
3804         * configure: Likewise.
3805
3806 2002-06-24  Bo Thorsen  <bo@suse.de>
3807
3808         * src/types.c: Merge settings for similar architectures.
3809         Add x86-64 sizes and alignments.
3810
3811 2002-06-23  Bo Thorsen  <bo@suse.de>
3812
3813         * src/arm/ffi.c (ffi_prep_args): Remove unused vars.
3814         * src/sparc/ffi.c (ffi_prep_args_v8): Likewise.
3815         * src/mips/ffi.c (ffi_prep_args): Likewise.
3816         * src/m68k/ffi.c (ffi_prep_args): Likewise.
3817
3818 2002-07-18  H.J. Lu  (hjl@gnu.org)
3819
3820         * Makefile.am (TARGET_SRC_MIPS_LINUX): New.
3821         (libffi_la_SOURCES): Support MIPS_LINUX.
3822         (libffi_convenience_la_SOURCES): Likewise.
3823         * Makefile.in: Regenerated.
3824
3825         * configure.in (mips64*-*): Skip.
3826         (mips*-*-linux*): New.
3827         * configure: Regenerated.
3828
3829         * src/mips/ffi.c: Include <sgidefs.h>.
3830
3831 2002-06-06  Ulrich Weigand  <uweigand@de.ibm.com>
3832
3833         * src/s390/sysv.S: Save/restore %r6.  Add DWARF-2 unwind info.
3834
3835 2002-05-27  Roger Sayle  <roger@eyesopen.com>
3836
3837         * src/x86/ffi.c (ffi_prep_args): Remove reference to avn.
3838
3839 2002-05-27  Bo Thorsen  <bo@suse.de>
3840
3841         * src/x86/ffi.c (ffi_prep_args): Remove unused variable and
3842         fix formatting.
3843
3844 2002-05-13  Andreas Tobler  <a.tobler@schweiz.ch>
3845
3846         * src/powerpc/ffi_darwin.c (ffi_prep_closure): Declare fd at
3847         beginning of function (for older apple cc).
3848
3849 2002-05-08  Alexandre Oliva  <aoliva@redhat.com>
3850
3851         * configure.in (ORIGINAL_LD_FOR_MULTILIBS): Preserve LD at
3852         script entry, and set LD to it when configuring multilibs.
3853         * configure: Rebuilt.
3854
3855 2002-05-05  Jason Thorpe  <thorpej@wasabisystems.com>
3856
3857         * configure.in (sparc64-*-netbsd*): Add target.
3858         (sparc-*-netbsdelf*): Likewise.
3859         * configure: Regenerate.
3860
3861 2002-04-28  David S. Miller  <davem@redhat.com>
3862
3863         * configure.in, configure: Fix SPARC test in previous change.
3864
3865 2002-04-29  Gerhard Tonn  <GerhardTonn@swol.de>
3866
3867         * Makefile.am: Add Linux for S/390 support.
3868         * Makefile.in: Regenerate.
3869         * configure.in: Add Linux for S/390 support.
3870         * configure: Regenerate.
3871         * include/ffi.h.in: Add Linux for S/390 support.
3872         * src/s390/ffi.c: New file from libffi CVS tree.
3873         * src/s390/sysv.S: New file from libffi CVS tree.
3874
3875 2002-04-28  Jakub Jelinek  <jakub@redhat.com>
3876
3877         * configure.in (HAVE_AS_SPARC_UA_PCREL): Check for working
3878         %r_disp32().
3879         * src/sparc/v8.S: Use it.
3880         * src/sparc/v9.S: Likewise.
3881         * fficonfig.h.in: Rebuilt.
3882         * configure: Rebuilt.
3883
3884 2002-04-08  Hans Boehm  <Hans_Boehm@hp.com>
3885
3886         * src/java_raw_api.c (ffi_java_raw_size): Handle FFI_TYPE_DOUBLE
3887         correctly.
3888         * src/ia64/unix.S: Add unwind information. Fix comments.
3889         Save sp in a way that's compatible with unwind info.
3890         (ffi_call_unix): Correctly restore sp in all cases.
3891         * src/ia64/ffi.c: Add, fix comments.
3892
3893 2002-04-08  Jakub Jelinek  <jakub@redhat.com>
3894
3895         * src/sparc/v8.S: Make .eh_frame dependent on target word size.
3896
3897 2002-04-06  Jason Thorpe  <thorpej@wasabisystems.com>
3898
3899         * configure.in (alpha*-*-netbsd*): Add target.
3900         * configure: Regenerate.
3901
3902 2002-04-04  Jeff Sturm  <jsturm@one-point.com>
3903
3904         * src/sparc/v8.S: Add unwind info.
3905         * src/sparc/v9.S: Likewise.
3906
3907 2002-03-30  Krister Walfridsson  <cato@df.lth.se>
3908
3909         * configure.in: Enable i*86-*-netbsdelf*.
3910         * configure: Rebuilt.
3911
3912 2002-03-29  David Billinghurst <David.Billinghurst@riotinto.com>
3913
3914         PR other/2620
3915         * src/mips/n32.s: Delete
3916         * src/mips/o32.s: Delete
3917
3918 2002-03-21  Loren J. Rittle  <ljrittle@acm.org>
3919
3920         * configure.in: Enable alpha*-*-freebsd*.
3921         * configure: Rebuilt.
3922
3923 2002-03-17  Bryce McKinlay  <bryce@waitaki.otago.ac.nz>
3924
3925         * Makefile.am: libfficonvenience -> libffi_convenience.
3926         * Makefile.in: Rebuilt.
3927
3928         * Makefile.am: Define ffitest_OBJECTS.
3929         * Makefile.in: Rebuilt.
3930
3931 2002-03-07  Andreas Tobler  <toa@pop.agri.ch>
3932             David Edelsohn  <edelsohn@gnu.org>
3933
3934         * Makefile.am (EXTRA_DIST): Add Darwin and AIX closure files.
3935         (TARGET_SRC_POWERPC_AIX): Add aix_closure.S.
3936         (TARGET_SRC_POWERPC_DARWIN): Add darwin_closure.S.
3937         * Makefile.in: Regenerate.
3938         * include/ffi.h.in: Add AIX and Darwin closure definitions.
3939         * src/powerpc/ffi_darwin.c (ffi_prep_closure): New function.
3940         (flush_icache, flush_range): New functions.
3941         (ffi_closure_helper_DARWIN): New function.
3942         * src/powerpc/aix_closure.S: New file.
3943         * src/powerpc/darwin_closure.S: New file.
3944
3945 2002-02-24  Jeff Sturm  <jsturm@one-point.com>
3946
3947         * include/ffi.h.in: Add typedef for ffi_arg.
3948         * src/ffitest.c (main): Declare rint with ffi_arg.
3949
3950 2002-02-21  Andreas Tobler  <toa@pop.agri.ch>
3951
3952         * src/powerpc/ffi_darwin.c (ffi_prep_args): Skip appropriate
3953         number of GPRs for floating-point arguments.
3954
3955 2002-01-31  Anthony Green  <green@redhat.com>
3956
3957         * configure: Rebuilt.
3958         * configure.in: Replace CHECK_SIZEOF and endian tests with
3959         cross-compiler friendly macros.
3960         * aclocal.m4 (AC_COMPILE_CHECK_SIZEOF, AC_C_BIGENDIAN_CROSS): New
3961         macros.
3962
3963 2002-01-18  David Edelsohn  <edelsohn@gnu.org>
3964
3965         * src/powerpc/darwin.S (_ffi_call_AIX): New.
3966         * src/powerpc/aix.S (ffi_call_DARWIN): New.
3967
3968 2002-01-17  David Edelsohn  <edelsohn@gnu.org>
3969
3970         * Makefile.am (EXTRA_DIST): Add Darwin and AIX files.
3971         (TARGET_SRC_POWERPC_AIX): New.
3972         (POWERPC_AIX): New stanza.
3973         * Makefile.in: Regenerate.
3974         * configure.in: Add AIX case.
3975         * configure: Regenerate.
3976         * include/ffi.h.in (ffi_abi): Add FFI_AIX.
3977         * src/powerpc/ffi_darwin.c (ffi_status): Use "long" to scale frame
3978         size.  Fix "long double" support.
3979         (ffi_call): Add FFI_AIX case.
3980         * src/powerpc/aix.S: New.
3981
3982 2001-10-09  John Hornkvist  <john@toastedmarshmallow.com>
3983
3984         Implement Darwin PowerPC ABI.
3985         * configure.in: Handle powerpc-*-darwin*.
3986         * Makefile.am: Set source files for POWERPC_DARWIN.
3987         * configure: Rebuilt.
3988         * Makefile.in: Rebuilt.
3989         * include/ffi.h.in: Define FFI_DARWIN and FFI_DEFAULT_ABI for
3990         POWERPC_DARWIN.
3991         * src/powerpc/darwin.S: New file.
3992         * src/powerpc/ffi_darwin.c: New file.
3993
3994 2001-10-07  Joseph S. Myers  <jsm28@cam.ac.uk>
3995
3996         * src/x86/ffi.c: Fix spelling error of "separate" as "seperate".
3997
3998 2001-07-16  Rainer Orth  <ro@TechFak.Uni-Bielefeld.DE>
3999
4000         * src/x86/sysv.S: Avoid gas-only .balign directive.
4001         Use C style comments.
4002
4003 2001-07-16  Rainer Orth  <ro@TechFak.Uni-Bielefeld.DE>
4004
4005         * src/alpha/ffi.c (ffi_prep_closure): Avoid gas-only mnemonic.
4006         Fixes PR bootstrap/3563.
4007
4008 2001-06-26  Rainer Orth  <ro@TechFak.Uni-Bielefeld.DE>
4009
4010         * src/alpha/osf.S (ffi_closure_osf): Use .rdata for ECOFF.
4011
4012 2001-06-25  Rainer Orth  <ro@TechFak.Uni-Bielefeld.DE>
4013
4014         * configure.in: Recognize sparc*-sun-* host.
4015         * configure: Regenerate.
4016
4017 2001-06-06  Andrew Haley  <aph@redhat.com>
4018
4019         * src/alpha/osf.S (__FRAME_BEGIN__): Conditionalize for ELF.
4020
4021 2001-06-03  Andrew Haley  <aph@redhat.com>
4022
4023         * src/alpha/osf.S: Add unwind info.
4024         * src/powerpc/sysv.S: Add unwind info.
4025         * src/powerpc/ppc_closure.S: Likewise.
4026
4027 2000-05-31  Jeff Sturm  <jsturm@one-point.com>
4028
4029         * configure.in: Fix AC_ARG_ENABLE usage.
4030         * configure: Rebuilt.
4031
4032 2001-05-06  Bryce McKinlay  <bryce@waitaki.otago.ac.nz>
4033
4034         * configure.in: Remove warning about beta code.
4035         * configure: Rebuilt.
4036
4037 2001-04-25  Hans Boehm <Hans_Boehm@hp.com>
4038
4039         * src/ia64/unix.S: Restore stack pointer when returning from
4040         ffi_closure_UNIX.
4041         * src/ia64/ffi.c: Fix typo in comment.
4042
4043 2001-04-18  Jim Wilson  <wilson@redhat.com>
4044
4045         * src/ia64/unix.S: Delete unnecessary increment and decrement of loc2
4046         to eliminate RAW DV.
4047
4048 2001-04-12  Bryce&n