The sources of the Free Pascal compiler, RTL, packages and utilities. See https://www.freepascal.org/ for more info.
Go to file
Jonas Maebe 9fed3ee04c * merged the jvmbackend branch
General:
    o support for Java/JVM and Android/JVM targets, with support for most
      common language features (classes, records, all array types,
      enumerations, signed and unsigned integers, currency, threadvar,
      typed constants, generics, exceptions, ansistring, ...) and limited
      support for others (such as pointers and formal var/out parameters).
      See http://wiki.freepascal.org/FPC_JVM/Language for more details
    o fpcjres utility to pack "resource files" (= any file specified via
      {$r xxx}, without any processing) into jar files
    o {$modeswitch unicodestrings} modeswitch that changes "string" into
      "unicodestring", "char" unto "widechar" and "pchar" into "pwidechar".
      Note that the latter two are achieved by automatically adding a unit
      (uuchar) to the uses clause that overrides these types, so it does not
      (yet) work for the system unit. If this modeswitch is enabled, {$H+/-}
      switches between string=unicodestring and string=shortstring, but the
      state of the {$H}-switch has no effect on the definition of char/pchar.
    o {$namespace x.y.z} directive to set the package namespace of a unit
      on the JVM target (does not do anything on other targets). Dotted unit
      names do not yet influence the namespace of generated JVM classes
    o javapp utility to create Pascal headers from Java class files

   Compiler:
    o new high level code generator in the compiler that uses high level type
      information, including a wrapper that passes everything through to the
      existing low level code generators for existing native targets
      (hlcgobj.pas, hlcg2ll.pas, <arch>/hlcgcpu.pas). Several routines have
      also migrated from ncgutil.pas to hlcgobj.pas
    o quite a bit of code in ncg*.pas has been converted to use the new
      high level code generator so that it works for both existing targets
      and the new JVM target (mostly replacing tcgsize parameters with tdef
      parameters, or adding some tdef size parameters) -- this one should
      always be used in common code, tgobj.gettemp() should only be used in
      architecture-specific code from now on
    o new tgobj.gethltemp() routine that also specifies the tdef of the
      requested temp for high level code generator use
    o tcgpara now also contains the def of the parameter for use by the
      high level code generator
    o support for nested routines without making use of a framepointer, by
      grouping variables accessed from nested routines into a record and
      passing a pointer to this record to the nested routines (ncgnstld.pas,
      ncgnstmm.pas)
    o support for internally generating and parsing Pascal code in the
      compiler for routine declarations and implementations (symcreat.pas)
    o parsing a recorddef and an objectdef method declaration has been
      factored out so this code can be reused by symcreat.pas
    o support for duplicating and slightly modifying procdefs
      (symdef.tprocdef.getcopy, symcreat.finish_copied_procdef)
    o cchartype has been renamed into cansichartype
    o new TSymStr type that is used as string type for symbols and mangled
      names. The default is still pshortstring on all platforms, but for the
      JVM targets it's ansistring because it sometimes needs symbols > 255
      characters
    o it is no longer allowed to use sysutils.executeprocess() from the
      compiler, except via the the wrapper cfilutil.RequotedExecuteProcess()
      so that the compiler can correctly deal with the
      sysutils.executeprocess() limitation of only supporting double quotes
    o new getpointerdef(def), getsingletonarraydef(def) and
      getarraydef(def,count) helpers in symdef to create/get reusable pointer/
      arraydefs for another def (mostly used for the JVM target currently)
    o several parameter parsing helpers have been moved from pdecsub.pas to
      pparautl.pas
    o the type checking and firstpass for setlength() and copy() has been
      moved from pinline.pas to ninl.pas so it can be overridden by target-
      specific versions
    o commented the ttempinfoflag values in nbas, and the ttemptype flags
      in globtype
    o new "reference" ttempcreatenode type, which can be used to create a
      reference to (~ hold the address of) another node, even on targets that
      do not support taking the address of an arbitrary memory location and
      store it into a virtual register (such as the JVM target).
    o secondpass no longer takes a var-parameter, since it doesn't change
      the received node
    o many routines from pmodules.pas and some from nutils.pas have been
      moved to ngenutil.pas as virtual class methods so they can be
      overridden with target-specific versions
    o the code of a single JVM routine is limited to 64KB bytecode, which can
      be fairly easily reached when having large array constants because they
      have to be initialized element by element in the unit initialisation
      code -> -CTcompactarrayinit switch to use alternate (slightly slower)
      initialisation of arrays on the JVM targets that uses much less code
      space
    o it is now possible to override the individual typecheck helpers of
      ttypeconvnode
    o most of the code from ptconst.pas has moved to ngtcon.pas, and has been
      turned into a class that splits most of the parsing and data/code
      generation for typed constants into separate routines. Separate
      implementations are now available that either generate initialised data
      (native targets) or assignment nodes for explicit initialisation at
      run time (JVM)

   RTL:
    o many extra ifdefs to common RTL include files to enable overriding
      helpers with JVM-specific helpers
    o some internal move-alternatives for the RTL that also can be overridden
      by the JVM target to enable sharing more code between managed and
      native targets

   Tests:
     o a number of JVM-specific tests have been added to tests/test/jvm.
       They can be executed via the provided testall.sh/.bat scripts.
       Because standard I/O is not yet available in the Java/Android RTL,
       most regular tests can't be compiled yet.

   Note: currently, compiling a JVM compiler requires adding ALLOW_WARNINGS=1
     to the make command line

git-svn-id: trunk@21069 -
2012-04-26 22:36:18 +00:00
compiler * synchronised with trunk up to r21067 2012-04-26 21:24:20 +00:00
ide + Regenerate all Makefiles's after adding x86_64 netbsd target 2012-04-24 23:15:18 +00:00
installer + Regenerate all Makefiles's after adding x86_64 netbsd target 2012-04-24 23:15:18 +00:00
packages * synchronised with trunk up to r21067 2012-04-26 21:24:20 +00:00
rtl * synchronised with trunk up to r21067 2012-04-26 21:24:20 +00:00
tests * synchronised with trunk up to r21067 2012-04-26 21:24:20 +00:00
utils * synchronised with trunk up to r21067 2012-04-26 21:24:20 +00:00
.gitattributes * synchronised with trunk up to r21067 2012-04-26 21:24:20 +00:00
.gitignore fpvectorial is now moved to lazarus/components/fpvectorial 2011-10-30 16:42:46 +00:00
Makefile * synchronised with trunk up to r21067 2012-04-26 21:24:20 +00:00
Makefile.fpc * merged trunk up to r20882 2012-04-15 15:54:10 +00:00