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