Commit Graph

3728 Commits

Author SHA1 Message Date
florian
331ace25c6 * handle undefineddef in classify_argument, resolves #27658
git-svn-id: trunk@30239 -
2015-03-15 16:19:58 +00:00
Jonas Maebe
8334597476 * a homogeneous float aggregate can maximally contain 4 elements
(mantis #27665)

git-svn-id: trunk@30229 -
2015-03-14 21:46:45 +00:00
Jonas Maebe
faf3efe139 + Linux/ppc64le test object files
git-svn-id: trunk@30228 -
2015-03-14 18:37:01 +00:00
Jonas Maebe
3ab62dcfed * switched Linux/PowerPC64 to Pascal startup code so that we can used ifdefs
to detect whether we're compiling for ELFv1/SYSV or ELFv2

git-svn-id: trunk@30210 -
2015-03-14 18:36:08 +00:00
Jonas Maebe
5b3c511467 * don't crash when "return exitvalue" is used in a procedure
git-svn-id: trunk@30177 -
2015-03-13 08:35:26 +00:00
Jonas Maebe
2dcd42d4f1 * fixed detection of an objcprotocols descending from a forward-defined
objcprotocol

git-svn-id: trunk@30169 -
2015-03-12 19:37:43 +00:00
Jonas Maebe
fc21845686 * fixed the allocation of R12 on ppc32/ppc64 when used to hold the value of
the stack pointer during the prolog. This was done previously in
    tcg.g_proc_entry(), but that routine is called after register allocation
    and hence has no influence. Also cleaned up the deallocation of that
    register by moving the previously ifdef'd code to thlcgppcgen
    (mantis #27634)

git-svn-id: trunk@30164 -
2015-03-11 17:49:44 +00:00
Jeppe Johansen
d12b913e70 Add initial support in ARM-embedded for Allwinner A20.
git-svn-id: trunk@30144 -
2015-03-08 12:22:57 +00:00
florian
53d6f6bc55 * handle dyn. arrays and interfaces correctly in TypInfo.SetOrdProp
git-svn-id: trunk@30141 -
2015-03-08 09:40:36 +00:00
Legolas
ffd03563d0 * Updated Wii rtl (unicode support broken .dol executables) and libogcfpc to ver.1.8.12. Fixed a dependency to Mad library too
git-svn-id: trunk@30125 -
2015-03-07 21:34:51 +00:00
Legolas
177b007eba * Fixed gba rtl: it generated corrupted executables
* Changed nds tool: grit has been replaced by grit_fpc (https://github.com/flodd/grit_fpc) to simplify the nds programming workflow

git-svn-id: trunk@30074 -
2015-03-02 17:33:44 +00:00
Jonas Maebe
ff020a3be4 + "Utf8CodePointLen(pansichar,MaxLookAhead,IncludeCombiningDiacriticalMarks):
sizeint"  function that returns:
   <0: invalid sequence detected after processing "-result" bytes
   0:  incomplete (may still be valid if MaxLookAhead is increased)
   >0: sequence of result bytes forms a codepoint (+ combining diacritical
       marks if that parameter was true)

git-svn-id: trunk@30047 -
2015-03-01 17:12:17 +00:00
Tomas Hajny
b2475353f4 * test programs previously having extension .pas renamed to .pp so that they are found during testsuite runs
git-svn-id: trunk@30024 -
2015-02-27 13:03:13 +00:00
Legolas
6f93505e08 * Fixed NDS building cycle (resolves bug #0026847)
* Updated libndsfpc to ver 1.5.10
 * Improved libndsfpc examples

git-svn-id: trunk@30008 -
2015-02-25 20:52:50 +00:00
Jonas Maebe
b5b7e0f338 * ensure that 64->32 bit truncations cannot be optimized away by the
register allocator on AArch64 + test (did not get caught by existing
    tests)

git-svn-id: trunk@29965 -
2015-02-23 22:55:54 +00:00
Jonas Maebe
1de8e53edd + AArch64 jump table support
git-svn-id: trunk@29964 -
2015-02-23 22:55:42 +00:00
Jonas Maebe
41fba0c4f7 * switched to using the stack pointer as base register for the temp allocator
instead of the frame pointer register:
      1) we exactly know the offsets of the temps from the stack pointer
         after pass 1 (based on the require parameter stack size for called
         routines), while we don't know it for the frame pointer (it depends
         on the number of saved registers)
      2) temp offsets from the stack pointer are positive while those from
         the frame pointer are negative, and we can directly encode much
         bigger positive offsets in the instructions
   o move the stack pointer register to a virtual register in
     loadparentfpn, because many instructions cannot directly operate
     on/with the stack pointer
   o add the necessary register interference edges for the stack pointer
     register

git-svn-id: trunk@29938 -
2015-02-23 22:54:03 +00:00
Jonas Maebe
f9647b661f + Darwin/AArch64 test object files
git-svn-id: trunk@29918 -
2015-02-23 22:52:52 +00:00
Jonas Maebe
5bdd14e252 + AArch64 cputarg
git-svn-id: trunk@29914 -
2015-02-23 22:52:39 +00:00
Jonas Maebe
558b8967b6 + Aarch64 assembler reader
git-svn-id: trunk@29913 -
2015-02-23 22:52:36 +00:00
Jonas Maebe
1c8059e30c + dummy AArch64 hlcgcpu
git-svn-id: trunk@29906 -
2015-02-23 22:52:14 +00:00
Jonas Maebe
cfd7bfc8a5 + dummy AArch64 cpupi unit
git-svn-id: trunk@29905 -
2015-02-23 22:52:11 +00:00
Jonas Maebe
44f5f435ba + Darwin/AArch64 support for handling hardware exceptions
git-svn-id: trunk@29900 -
2015-02-23 22:51:54 +00:00
Jonas Maebe
53548663e3 + AArch64 assembler writer
git-svn-id: trunk@29890 -
2015-02-23 22:51:22 +00:00
Jonas Maebe
65141ab135 + aarch64 makefile.cpu
git-svn-id: trunk@29887 -
2015-02-23 22:51:12 +00:00
Jonas Maebe
e32965879d * dummy strings.inc for aarch64
git-svn-id: trunk@29886 -
2015-02-23 22:51:09 +00:00
Jonas Maebe
dad442c7e3 + aarch64 fpu init, atomic routines and memory barriers
git-svn-id: trunk@29885 -
2015-02-23 22:51:06 +00:00
Jonas Maebe
6813831e03 + AArch64 setjump code based on NetBSD version
git-svn-id: trunk@29884 -
2015-02-23 22:51:03 +00:00
Jonas Maebe
6b371315f3 + dummy AArch64 stringss.inc file
git-svn-id: trunk@29883 -
2015-02-23 22:51:00 +00:00
Jonas Maebe
e82201d6ac + dummy set.inc for AArch64
git-svn-id: trunk@29882 -
2015-02-23 22:50:57 +00:00
Jonas Maebe
4c7f75c93b + round/trunc/int for AArch64
git-svn-id: trunk@29881 -
2015-02-23 22:50:54 +00:00
Jonas Maebe
66d4e9a3a5 + dummy int64p.inc
git-svn-id: trunk@29880 -
2015-02-23 22:50:51 +00:00
Jonas Maebe
84f04ad2ce + aarch64 fpu rounding mode/exception support
git-svn-id: trunk@29879 -
2015-02-23 22:50:48 +00:00
Jonas Maebe
6995474ea0 + aarch64 cpunode
git-svn-id: trunk@29875 -
2015-02-23 22:50:35 +00:00
Jonas Maebe
0af4f3e3fb + aarch64 math nodes implementation
git-svn-id: trunk@29868 -
2015-02-23 22:50:13 +00:00
Jonas Maebe
4aeb22f7f4 + initial implementation of aarch64 type conversion nodes
git-svn-id: trunk@29867 -
2015-02-23 22:50:10 +00:00
Jonas Maebe
71ae8015da + initial implementation of aarch64 add nodes
git-svn-id: trunk@29866 -
2015-02-23 22:50:07 +00:00
Jonas Maebe
8a444ed96a + initial implementation of aarch64 inline nodes
git-svn-id: trunk@29865 -
2015-02-23 22:50:04 +00:00
Jonas Maebe
7fa414f7f1 + initial implementation of aarch64 register allocator
git-svn-id: trunk@29864 -
2015-02-23 22:50:01 +00:00
Jonas Maebe
ab186f7892 + initial implementation of aarch64 code generator
git-svn-id: trunk@29853 -
2015-02-23 22:49:28 +00:00
Jonas Maebe
a56d94230f + iosxwstr unit that uses CoreFoundation where possible for the widestring
manager routines (in particular for locale-based routines, such as upper/
    lowercase), and which falls back to cwstring for functionality not
    supported by CoreFoundation (such as converting an UTF-8 string with
    illegal sequences to a different encoding)
   o this unit is particularly useful on iOS 7 (and 8?), as Apple no
     longer includes command line locale information on that platform and
     hence locale-dependent libc routines only work with the "C" locale
     there)

git-svn-id: trunk@29828 -
2015-02-23 22:48:11 +00:00
Károly Balogh
db50666b3b n68kinl: added inline nodes for 68k. implemented first_sqr_real and second_sqr_real for 68881 FPU
git-svn-id: trunk@29799 -
2015-02-22 23:11:16 +00:00
florian
c46cbd3b1a + test for an already fixed report (#14347), added to avoid that it pops up again
git-svn-id: trunk@29793 -
2015-02-22 20:33:01 +00:00
florian
cab98a58d0 + parameters of nested procedure variable parameters are taken into account during name mangling, resolves #27515
* de-duplicated parameter name mangling code

git-svn-id: trunk@29791 -
2015-02-22 09:16:20 +00:00
svenbarth
5a344ee263 Rework the way how "specialize" is handled. Instead of initializing the specialization of a full type declaration (including unit name and parent types) it is now considered part of the specialized type itself. This means that for example the following code:
type
  TTestLongInt = specialize SomeOtherUnit.TTest<LongInt>;

will now have to read as

type
  TTestLongInt = SomeOtherUnit.specialize TTest<LongInt>;

While this is not backwards compatible this situation should arise seldomly enough and the benefits especially in context with generic functions/procedures/methods outway the drawbacks.

pbase.pas:
  * try_consume_unitsym: add a allow_specialize parameter that allows to parse "specialize" in front of a non-unit symbol; whether it was a specialization or not is reported using a new is_specialize parameter
  + add a new overload try_consume_unitsym_no_specialize that calls try_consume_unit sym with allow_specialize=false and a dummy is_specialize parameter
  * switch calls to try_consume_unitsym to try_consume_unitsym_no_specialize
pstatmnt.pas, try_statement:
  * switch call to try_consume_unitsym to try_consume_unitsym_no_specialize
  * adjust call to parse_nested_types
ptype.pas:
  + extend id_type with the possibility to disallow unit symbols (needed if a specialize was already parsed) and to report whether a specialize was parsed
  + extend parse_nested_types with the possibility to tell it whether specializations are allowed
  * have parse_nested_types specialize generic defs if one is encountered and local type defs are allowed
  * id_type: only allow "unitsym.specialize sym" or "specialize sym", but not "specialize unitsym.sym"
  * single_type: correctly handle specializations with "specialize" keyword
  * read_named_type.expr_type: there is no longer a need to check for "specialize" keyword
pexpr.pas:
  + new function handle_specialize_inline_specialization which tries to specialize a type symbol
  * handle_factor_typenode: handle specializations after a point that follows a record or object (why isn't this part of postfixoperators anyway? O.o)
  * postfixoperators: handle "specialize" after records and objectdefs
  * factor_read_id: handle "specialize" in front of an identifier (and after unit symbols)

+ added tests
* adjusted test webtbs/tw16090.pp

git-svn-id: trunk@29768 -
2015-02-20 16:23:40 +00:00
nickysn
a939ea06b6 + initial implementation of GDB/MI (without LibGDB!) support for the text mode
IDE. Tested under Linux (Fedora 21 - x86_64, GDB 7.8.2). It is still disabled
  by default on all platforms. To enable it, build a snapshot with:
  FPMAKEOPT="--ignoreinvalidoption --GDBMI=1"
  Known issue: the GDB window in the IDE causes crashes, so don't open it :)
  (for debugging purposes, set the environment variable FPIDE_GDBLOG=1 when
  running the IDE and it will log everything in gdblog.txt)

git-svn-id: trunk@29716 -
2015-02-16 01:07:37 +00:00
florian
3ed1a75fcd * write ok on exit for easier testing
git-svn-id: trunk@29693 -
2015-02-14 17:39:32 +00:00
svenbarth
a7085ea34e Added test for Mantis #25044 which has been fixed in revision 29537.
git-svn-id: trunk@29687 -
2015-02-13 17:02:07 +00:00
Jonas Maebe
071282b286 * add methods of objcprotocols to the list of visible "helper" methods when
loading them from ppu (like was already done when they were initially
    compiler), so they can be called via the "id" type even if no classes are
    in scope that implement them

git-svn-id: trunk@29686 -
2015-02-13 15:43:34 +00:00
svenbarth
04534d5dcf Fix for Mantis #27424.
pgenutil.pas:
  * parse_generic_parameters: a ';' terminates a parameter group, so correctly adjust firstidx in that case

+ added test

git-svn-id: trunk@29685 -
2015-02-13 13:50:47 +00:00