Commit Graph

37151 Commits

Author SHA1 Message Date
Jonas Maebe
5433db6a49 * also specify the section alignment with the section statements themselves
on AIX. Adding ".align" statements only align relative to the section
    start, but does not influence the alignment of the section itself

git-svn-id: trunk@20835 -
2012-04-11 18:06:05 +00:00
Jonas Maebe
cc4169ef68 * don't raise an internalerror when the the binding type of a weak external
symbol is changed to something else (binding a weak symbol to a real
    implementation in the current file is valid)

git-svn-id: trunk@20834 -
2012-04-11 18:06:00 +00:00
Jonas Maebe
d545a72f1a + lnfogdb unit that can use gdb to symbolicate backtraces on unix targets
(used for stabx/aix)

git-svn-id: trunk@20833 -
2012-04-11 18:05:56 +00:00
Jonas Maebe
7aa3b99fb5 + -CN/{$CHECKLOWADDRLOADS+/-} switch to enable explicit checks for accesses
to low addresses in case the target cpu/OS does not support this (enabled
    for reads on AIX/PPC because on AIX the first 16KB are readable)

git-svn-id: trunk@20832 -
2012-04-11 18:05:50 +00:00
Jonas Maebe
d7a12a01e8 * fixed c_truncf declaration (double -> single)
git-svn-id: trunk@20831 -
2012-04-11 18:05:45 +00:00
Jonas Maebe
64be3440d7 * fixed skiptarget directive
git-svn-id: trunk@20830 -
2012-04-11 18:05:40 +00:00
Jonas Maebe
69e01418bb * set the type of record/object/class method symbols to AT_FUNCTION
* in case of a jump/call to an AT_FUNCTION symbols on
    systems_dotted_function_names platforms, prepend a dot to the symbol
    name in assembler code

git-svn-id: trunk@20829 -
2012-04-11 18:05:35 +00:00
Jonas Maebe
a9220ffd2a + systems_dotted_function_names set that holds targets using dotted function
names as function descriptors

git-svn-id: trunk@20828 -
2012-04-11 18:05:31 +00:00
Jonas Maebe
8a35bb090a + ansistring version of strpnew()
git-svn-id: trunk@20827 -
2012-04-11 18:05:27 +00:00
Jonas Maebe
60869a0da0 * set TOC pointer when returning to HandleErrorAddrFrame from signal handler
git-svn-id: trunk@20826 -
2012-04-11 18:05:20 +00:00
Jonas Maebe
1f9d8420b6 * set correct fileinfo for the asmnodes (so that the start fileinfo of
assembler functions doesn't get changed into the end fileinfo)

git-svn-id: trunk@20825 -
2012-04-11 18:05:16 +00:00
Jonas Maebe
3ad16429bf * enabled database units for aix
git-svn-id: trunk@20824 -
2012-04-11 18:05:11 +00:00
Jonas Maebe
131ed0c5a4 * use SharedSuffix for dynlib extension
git-svn-id: trunk@20823 -
2012-04-11 18:05:06 +00:00
Jonas Maebe
d68d9ba1a0 * don't pass -blibpath parameter for %needlibrary tests on AIX: the linker
doesn't recognise it (even though it's documented) and it's not needed

git-svn-id: trunk@20822 -
2012-04-11 18:05:02 +00:00
Jonas Maebe
51616b7bd6 * enabled a bunch of tests also for aix
git-svn-id: trunk@20821 -
2012-04-11 18:04:57 +00:00
Jonas Maebe
9a1cd0ec4c * fixed checking the address of installed signal handlers on aix and
linux/ppc64 (have to look past the function descriptors)

git-svn-id: trunk@20820 -
2012-04-11 18:04:50 +00:00
Jonas Maebe
6f02f47e59 - disabled for AIX, doesn't support weak external symbols
git-svn-id: trunk@20819 -
2012-04-11 18:04:45 +00:00
Jonas Maebe
51e50f72be + support for creating dynamic libraries on AIX
git-svn-id: trunk@20818 -
2012-04-11 18:04:40 +00:00
Jonas Maebe
ddde9760c2 * ignore tf_no_backquote_support in source_info.flags in case we will link
on the target system (-St command line option during cross-compiling)

git-svn-id: trunk@20817 -
2012-04-11 18:04:36 +00:00
Jonas Maebe
cf2ffdce1a * use cg.g_external_wrapper() rather than cg.a_jmp_name() to generate stubs
for alternate shared library function names (corrects them on at least
    AIX and Linux/ppc64)

git-svn-id: trunk@20816 -
2012-04-11 18:04:31 +00:00
Jonas Maebe
c26ff16c1e * on AIX, you have to enable fpu exception reporting per process via an
OS call before changes to the fpscr exception mask have any effect
  * use OS calls to change FPU state on AIX, does not always propagate
    otherwise
  * don't use libc's log() on AIX, it wrongly returns a division-by-zero
    exception in some cases

git-svn-id: trunk@20815 -
2012-04-11 18:04:26 +00:00
Jonas Maebe
7e9da1ce1a * floating point exception checking support for aix for libc helpers
(they don't raise exceptions themselves)

git-svn-id: trunk@20814 -
2012-04-11 18:04:21 +00:00
Jonas Maebe
909f99b4c7 * code symbols start with a dot on AIX just like on linux/ppc64
git-svn-id: trunk@20813 -
2012-04-11 18:04:16 +00:00
Jonas Maebe
44bd889b9b * regenerated Makefiles with AIX support
git-svn-id: trunk@20812 -
2012-04-11 18:03:57 +00:00
Jonas Maebe
2e1b527718 + AIX support for FV
git-svn-id: trunk@20811 -
2012-04-11 18:02:48 +00:00
Jonas Maebe
8335223caf + aix support for pthreads package
git-svn-id: trunk@20810 -
2012-04-11 18:02:43 +00:00
Jonas Maebe
9ca2ea7fd0 + AIX support to Makefiles
git-svn-id: trunk@20809 -
2012-04-11 18:02:38 +00:00
Jonas Maebe
9ba5f25588 + dependency changes because of AIX rtl support
git-svn-id: trunk@20808 -
2012-04-11 18:02:33 +00:00
Jonas Maebe
2b0472dce5 + aix/ppc32 support
git-svn-id: trunk@20807 -
2012-04-11 18:02:28 +00:00
Jonas Maebe
9efe09a827 + aix support for testsuite helper programs
git-svn-id: trunk@20806 -
2012-04-11 18:02:23 +00:00
Jonas Maebe
b93cc83703 * on AIX, you also can't have a label without data coming at the end of the
resource string table -> use same workaround as for Darwin

git-svn-id: trunk@20805 -
2012-04-11 18:02:18 +00:00
Jonas Maebe
dc70db9402 * parameter passing support for AIX:
o the last bytes of records passed by value whose size is not a multiple
     of the register size must be passed in the upper (leftmost) bytes of
     a register

git-svn-id: trunk@20804 -
2012-04-11 18:02:13 +00:00
Jonas Maebe
273b90fc37 + AIX assembler writer
o .short/.long/.llong are automatically aligned to 2/4/8 byte multiples
     by the AIX assembler (and for compatibility reasons, also by the
     GNU assembler when targeting AIX) -> change to .vbyte statements
  o .ascii does not allow non-ASCII characters in the AIX assembler
    -> change to .byte sequences like gcc on AIX

git-svn-id: trunk@20803 -
2012-04-11 18:02:08 +00:00
Jonas Maebe
260958eb45 * changed last parameter of g_indirect_sym_load() to a set and also
pass on whether the symbol refers to code or data (important for
    AIX weak symbols; note that AIX does not support undefined weak
    external symbols, and FPC does not yet support weakly defining
    non-external symbols, so this functionality isn't really used yet)

git-svn-id: trunk@20802 -
2012-04-11 18:02:03 +00:00
Jonas Maebe
ac43eb9b70 + generic implementation of ReplaceForbiddenAsmSymbolChars() instead
of the AVR-specific ifdef'ed variant
   o since the only special character we use in mangled names on all platforms
     is $, added a new field to tasminfo called "dollarsign" that holds the
     character $'s should be replaced with (if it doesn't have to be replaced,
     leave it at $)

git-svn-id: trunk@20801 -
2012-04-11 18:01:57 +00:00
Jonas Maebe
23df85e52a * initialize dirhint field of created tasmconds
git-svn-id: trunk@20800 -
2012-04-11 18:01:49 +00:00
Jonas Maebe
aaf6015b51 * converted tai directive string from pshortstring to ansistring (some
AIX directives are quite long)

git-svn-id: trunk@20799 -
2012-04-11 18:01:41 +00:00
Jonas Maebe
7a92d5e912 + TExternalAssembler.AsmWrite(ansistring) (from JVM branch), needed to be
able to write long tasmdirective strings required by AIX target

git-svn-id: trunk@20798 -
2012-04-11 18:01:35 +00:00
Jonas Maebe
71106219f2 * detect RTOC-based accesses on AIX in inline assembly, and change the
symbol names to those of the associated TOC entries

git-svn-id: trunk@20797 -
2012-04-11 18:01:29 +00:00
Jonas Maebe
b738657bf3 * on AIX, functions are called via function descriptors whose name
is '.' followed by the function symbol name (like on linux/ppc64)

git-svn-id: trunk@20796 -
2012-04-11 18:01:21 +00:00
Jonas Maebe
4123df9cb8 * moved g_external_wrapper() code from powerpc64/cgcpu to ppcgen/cgppc,
made it 32/64 bit neutral and adjusted it so it can be used for
   linux/ppc64, aix/ppc and aix/ppc64

git-svn-id: trunk@20795 -
2012-04-11 18:01:14 +00:00
Jonas Maebe
95966da949 + AIX support for a_call_reg()
* renamed some ppc64 stackframe offset constants to the same names as their
    32 bit counterparts so they can be used in shared ppc code

git-svn-id: trunk@20794 -
2012-04-11 18:01:01 +00:00
Jonas Maebe
509df28361 + AIX symbol handling: load symbol address from the TOC
* fixed code dealing with symbol+offsets on 64 bit platforms in
    case of offsets > 32 bit (and to use smallint() typecasts
    instead of lo(), since the return value of lo() depends on
    the type passed in)

git-svn-id: trunk@20793 -
2012-04-11 18:00:48 +00:00
Jonas Maebe
481b3d99a9 * just like Darwin and Classic Mac OS, AIX uses the system crt* files and
hence contains a dummy "main" that refers to the system unit
    FPC_SYSTEMMAIN, which in turn jumps to the main program's PASCALMAIN
  * we call FPC_SYSTEMMAIN instead of jumping to it like on Darwin, so that
    the TOC gets set correctly

git-svn-id: trunk@20792 -
2012-04-11 18:00:43 +00:00
Jonas Maebe
57908f528b * AIX-specific struct alignment rules
o doubles are aligned to 8 bytes outside records, but to 4 bytes
     inside them
   o same as for Darwin/PPC: if the first field of a record has 8 byte
     alignment (including double!), then the struct itself gets 8 byte
     alignment

git-svn-id: trunk@20791 -
2012-04-11 18:00:37 +00:00
Jonas Maebe
462de0f5fd + AIX target definition and info for the compiler and ppudump
git-svn-id: trunk@20790 -
2012-04-11 18:00:29 +00:00
Jonas Maebe
452414e1a7 - removed cg.g_indirect_sym_load() calls from pass_generate_code; this
routine is called from tcgppcgen.fixref()/tcgx86.make_simple_ref()
    when necessary

git-svn-id: trunk@20789 -
2012-04-11 18:00:21 +00:00
Jonas Maebe
7c0469e1fd * link libbsd for AIX, because several UNIX routines are part of its BSD
Compatibility library

git-svn-id: trunk@20788 -
2012-04-11 18:00:08 +00:00
Jonas Maebe
b0e4263fee + aix support in fpcmake and fpmake
git-svn-id: trunk@20787 -
2012-04-11 17:59:59 +00:00
Jonas Maebe
8d8fc0fdee + RTL for AIX
git-svn-id: trunk@20786 -
2012-04-11 17:59:49 +00:00