fpc/compiler
Jonas Maebe b26703feaa Darwin version comparisons: factored out into object
Use numeric instead of string comparisons
2022-09-16 11:21:05 +02:00
..
aarch64 * apply OptPass1Data to neg as well 2022-09-06 21:42:29 +02:00
arm * arm/a64: New sbfx/ubfx -> mov optimisation 2022-07-30 18:36:16 +00:00
armgen * more use of USxtOp2Op 2022-09-04 20:37:43 +02:00
avr Increase reference count of jump label, fixes #39784 2022-06-18 12:28:36 +00:00
generic
html
i386 * x86: Fixed minor logic bug in aoc_ForceNewIteration check where UpdateUsedRegs was called at the wrong time. 2022-07-27 16:26:07 +01:00
i8086 * extend tabstractprocdef.getcopyas by a parameter to control whether the copy should be registered or not 2022-05-26 21:42:59 +02:00
jvm * spelling fixes 2022-08-04 23:01:35 +02:00
llvm Darwin version comparisons: factored out into object 2022-09-16 11:21:05 +02:00
m68k m68k: fixed the capabilities flags inverted logic issues committed in 7d23c2e9 2022-08-30 10:42:26 +02:00
mips * handle also simulated flags in tmipselnotnode.second_boolean, resolves #39877 2022-08-24 21:16:23 +02:00
msg do not publish enums with jumps 2022-08-16 20:47:44 +02:00
powerpc Fix compilation of 32-bit powerpc compiler 2022-06-03 11:45:36 -07:00
powerpc64 Add several increfs to avoid troubles on AIX target OS 2022-06-03 11:28:15 -07:00
ppcgen Add several increfs to avoid troubles on AIX target OS 2022-06-03 11:28:15 -07:00
riscv * RiscV: generate mret only for FreeRTOS and Embedded 2022-07-20 22:16:19 +02:00
riscv32 * Riscv32 and Riscv64 on linux: enable safecall support 2022-07-22 22:56:21 +02:00
riscv64 * Riscv32 and Riscv64 on linux: enable safecall support 2022-07-22 22:56:21 +02:00
sparc
sparc64
sparcgen Fix compilation of sparc compiler with -dDEBUG_ALL_OPT 2022-05-31 11:47:24 +00:00
systems Darwin version comparisons: factored out into object 2022-09-16 11:21:05 +02:00
utils LLVM backend: address sanitizer support 2022-07-06 22:26:13 +02:00
wasm32 * WebAssembly high level code generator: use the global.get and global.set 2022-07-26 02:13:09 +03:00
x86 * x86: Added SARX to BMI2 code generator 2022-09-10 19:10:55 +00:00
x86_64 * spelling fixes 2022-08-04 23:01:35 +02:00
xtensa
z80 * reset written source lines once a section is encountered 2022-05-26 21:43:35 +02:00
aasmbase.pas
aasmcfi.pas
aasmcnst.pas ttai_typedconstbuilder: do not remove tcalo_vectorized_dead_strip_item 2022-07-06 22:25:05 +02:00
aasmdata.pas
aasmdef.pas
aasmsym.pas
aasmtai.pas Mark .noinit section with nobits flag. 2022-08-14 19:31:21 +00:00
aggas.pas + declare user-defined wasm globals in the llvm-mc assembly output 2022-07-25 05:35:00 +03:00
aopt.pas
aoptbase.pas
aoptda.pas
aoptobj.pas
aoptutils.pas
assemble.pas + add method ResetSourceLines to TExternalAssembler to reset already written lines 2022-05-26 21:43:35 +02:00
blockutl.pas * extend tabstractprocdef.getcopyas by a parameter to control whether the copy should be registered or not 2022-05-26 21:42:59 +02:00
browcol.pas
catch.pas
ccharset.pas
cclasses.pas
cepiktimer.pas
cfidwarf.pas * Always generate CFI-information. During linking it can be omitted when 2022-07-10 12:24:18 +02:00
cfileutl.pas
cg64f32.pas
cgbase.pas + introduced trefaddr.addr_got_tls, to be used for generating WebAssembly threadvar access, when WASM multithreading is turned on 2022-07-14 00:28:03 +03:00
cgexcept.pas
cghlcpu.pas
cgobj.pas
cgutils.pas * Converted assertion into an internal error 2022-08-20 16:09:54 +00:00
cmsgs.pas
comphook.pas
compiler.pas
compinnr.pas
comprsrc.pas
comptty.pas
constexp.pas
COPYING.txt
cprofile.pas
crefs.pas
cresstr.pas cresstr: fix length specified for resource strings to typed const builder 2022-07-06 22:25:05 +02:00
cscript.pas
cstreams.pas
cutils.pas Darwin version comparisons: factored out into object 2022-09-16 11:21:05 +02:00
dbgbase.pas
dbgcodeview.pas
dbgdwarf.pas * handle absolute on strings correctly for dwarf debug info, resolves #39816 2022-07-05 23:04:57 +02:00
dbgdwarfconst.pas
dbgstabs.pas * spelling fixes 2022-08-04 23:01:35 +02:00
dbgstabx.pas
defcmp.pas vector support: use vector result types 2022-09-16 11:21:04 +02:00
defutil.pas vector support: use vector result types 2022-09-16 11:21:04 +02:00
dirparse.pas
dwarfbase.pas
elfbase.pas
entfile.pas
export.pas
expunix.pas
finput.pas
fmodule.pas
fpcdefs.inc * Riscv32 and Riscv64 on linux: enable safecall support 2022-07-22 22:56:21 +02:00
fpchash.pas
fpcp.pas
fpkg.pas
fppu.pas + added check whether PPU and program are compiled in the same WebAssembly 2022-06-21 23:12:28 +03:00
gendef.pas
globals.pas Darwin version comparisons: factored out into object 2022-09-16 11:21:05 +02:00
globstat.pas
globtype.pas llvm: support for getting the llvm rtl (rt) architecture name 2022-07-24 14:36:13 +02:00
hlcg2ll.pas
hlcgobj.pas High level codegen: set MM register type for vectors 2022-09-16 11:21:05 +02:00
htypechk.pas * fix #39740: consider a conversion of a procedure or procedure variable to a function reference as a bit more expensive than otherwise 2022-05-31 22:50:14 +02:00
impdef.pas
import.pas
ldscript.pas
link.pas llvm: generalised sanitizer linking support 2022-07-24 14:36:23 +02:00
macho.pas
machoutils.pas
Makefile + added Risc-V register information file generation to the compiler Makefile 2022-05-31 22:38:30 +02:00
Makefile.fpc + added Risc-V register information file generation to the compiler Makefile 2022-05-31 22:38:30 +02:00
MPWMake
msgidx.inc do not publish enums with jumps 2022-08-16 20:47:44 +02:00
msgtxt.inc do not publish enums with jumps 2022-08-16 20:47:44 +02:00
nadd.pas vector support: use vector result types 2022-09-16 11:21:04 +02:00
nbas.pas
ncal.pas * a function also captures other nested functions when these are called 2022-05-26 21:43:36 +02:00
ncgadd.pas
ncgbas.pas
ncgcal.pas
ncgcnv.pas
ncgcon.pas
ncgflw.pas
ncghlmat.pas
ncginl.pas
ncgld.pas * hopefully final fix after 9848349610 2022-09-14 22:34:50 +02:00
ncgmat.pas
ncgmem.pas
ncgnstfl.pas
ncgnstld.pas
ncgnstmm.pas
ncgobjc.pas
ncgopt.pas
ncgrtti.pas * correctly truncate rtti symbol names of enumeration types, resolves #39829 2022-07-11 22:07:57 +02:00
ncgset.pas
ncgutil.pas hlcgobj: new getlocal and recordnewsymloc methods 2022-06-04 22:26:40 +02:00
ncgvmt.pas
ncnv.pas vector support: use vector result types 2022-09-16 11:21:04 +02:00
ncon.pas tstringconstnode.changestringtype: fix buffer overrun 2022-07-06 22:25:05 +02:00
nflw.pas
ngenutil.pas * fix #39857: don't trash symbols marked as vo_is_internal 2022-08-26 17:42:22 +02:00
ngtcon.pas * correctly convert a single WideChar to a PChar constant with the correct code page 2022-08-28 21:53:44 +02:00
ninl.pas * Fix to bug that would reset nf_write flag on tempref nodes in assignments 2022-08-31 18:25:11 +00:00
nld.pas * implement assignment of anonymous functions to procedure or method variables if they either capture nothing or (in case of method variables) at most the Self variable 2022-05-26 21:43:01 +02:00
nmat.pas
nmem.pas Support arrays and classes in compile-time OffsetOf. 2022-07-16 22:12:07 +02:00
nobj.pas
nobjc.pas
node.pas
nopt.pas
nset.pas
nutils.pas * cleanup 2022-09-11 22:43:07 +02:00
objcasm.pas
objcdef.pas objcdef: remove duplicate variant start check 2022-06-06 23:12:53 +02:00
objcgutl.pas
objcutil.pas
ogbase.pas
ogcoff.pas
ogelf.pas
oglx.pas
ogmacho.pas
ogmap.pas
ognlm.pas
ogomf.pas * patch by Rika: Replace some instances of manual work with endianness with cryptic oneliners, resolves #39719 2022-06-08 22:59:39 +02:00
ogrel.pas + support writing of 32-bit and 64-bit relocations in the REL object writer 2022-07-12 19:16:23 +03:00
ogwasm.pas * use WasmCustomSectionName to obtain the debug section names in MaybeWriteDebugSection and MaybeAddDebugSectionToSymbolTable 2022-08-03 23:11:44 +03:00
omfbase.pas * patch by Rika: Replace some instances of manual work with endianness with cryptic oneliners, resolves #39719 2022-06-08 22:59:39 +02:00
optbase.pas
optconstprop.pas * Fixed infinite loop when CONSTPROP is enabled 2022-07-10 21:15:26 +00:00
optcse.pas
optdead.pas
optdeadstore.pas
optdfa.pas * do not throw messages on potentially uninitialized internal symbols, resolves #39744 2022-06-15 23:30:33 +02:00
options.pas Darwin version comparisons: factored out into object 2022-09-16 11:21:05 +02:00
optloadmodifystore.pas
optloop.pas
opttail.pas
optutils.pas
optvirt.pas
owar.pas
owbase.pas
owomflib.pas * patch by Rika: Replace some instances of manual work with endianness with cryptic oneliners, resolves #39719 2022-06-08 22:59:39 +02:00
parabase.pas TCGParaLocation: remove alignment gap 2022-06-04 22:26:40 +02:00
paramgr.pas
parser.pas * implement assignment of procedure and method variables and routines (global, instance and nested) to function references 2022-05-26 21:44:24 +02:00
pass_1.pas
pass_2.pas
pbase.pas * implement assignment of procedure and method variables and routines (global, instance and nested) to function references 2022-05-26 21:44:24 +02:00
pcp.pas
pdecl.pas Fix cycling with -CR option 2022-05-26 22:43:41 +02:00
pdecobj.pas * spelling fixes 2022-08-04 23:01:35 +02:00
pdecsub.pas * spelling fixes 2022-08-04 23:01:35 +02:00
pdecvar.pas * fix #39903: correctly parse anonymous function references in records (and classes/objects) 2022-09-15 22:57:05 +02:00
pexports.pas
pexpr.pas * try to specialize a specialize node if it's followed by a < in a non-code section so that we might get better error messages 2022-08-12 17:19:32 +02:00
pgentype.pas
pgenutil.pas * fix #39869: correctly check whether the recorded token stream still needs to be parsed (the replay depth of the scanner needs to be *larger* than what it was before starting the playback) 2022-08-18 23:09:01 +02:00
pinline.pas
pkgutil.pas
pmodules.pas LLVM backend: address sanitizer support 2022-07-06 22:26:13 +02:00
pp.lpi
pp.pas
pparautl.pas * do not insert the $result symbol again when the VMT for the capturer is built 2022-05-26 21:44:22 +02:00
ppc68k.lpi
ppc8086.lpi
ppcaarch64.lpi
ppcarm.lpi
ppcavr.lpi
ppcjvm.lpi
ppcmips64el.lpi
ppcmips.lpi
ppcmipsel.lpi
ppcppc64.lpi
ppcppc64le.lpi
ppcppc.lpi
ppcriscv32.lpi
ppcriscv64.lpi
ppcsparc64.lpi
ppcsparc.lpi
ppcwasm32.lpi * .lpi version update 2022-07-31 21:09:09 +03:00
ppcx64.lpi
ppcx64llvm.lpi
ppcxtensa.lpi
ppcz80.lpi
ppheap.pas
ppu.pas
procdefutil.pas * fix #39858: correctly keep track of symbols that need to be captured into the capturer 2022-08-12 17:44:39 +02:00
procinfo.pas + add method to find a procinfo for a nested function by the corresponding procdef 2022-05-26 21:44:24 +02:00
psabiehpi.pas
pstatmnt.pas * Risc-V: allow also register aliases in register modification lists after asm blocks, last part to resolve #39738 2022-06-03 22:54:18 +02:00
psub.pas parentfpstruct: explicitly trash before initialising 2022-07-26 22:36:13 +02:00
psystem.pas llvm: use formaldef rather than undefineddef for llvm_metadata 2022-06-12 21:20:37 +02:00
ptconst.pas
ptype.pas * compilation with -O3 fixed 2022-05-26 22:34:34 +02:00
raatt.pas
rabase.pas
rasm.pas
rautils.pas rautils: don't interpret ".L3" as potentially meaning "unitx.identifier" 2022-05-29 13:33:27 +02:00
README.txt
rescmn.pas
rgbase.pas
rgobj.pas
scandir.pas * remove accidently commited writeln 2022-06-19 16:18:10 +02:00
scanner.pas * patch by rika: simplify tscannerfile.readstring, resolves #39835 2022-07-12 22:12:23 +02:00
switches.pas * get rid of cs_opt_none 2022-06-18 20:13:03 +02:00
symbase.pas
symconst.pas * do not throw messages on potentially uninitialized internal symbols, resolves #39744 2022-06-15 23:30:33 +02:00
symcreat.pas parentfpstruct: don't add vo_is_firstfield to first field of record 2022-06-06 23:12:53 +02:00
symdef.pas do not publish enums with jumps 2022-08-16 20:47:44 +02:00
symsym.pas dbgllvm: support for record field debug information 2022-06-06 23:12:53 +02:00
symtable.pas * protected symbols are visible for defs declared in a local symtable as well 2022-05-26 21:43:40 +02:00
symtype.pas do not publish enums with jumps 2022-08-16 20:47:44 +02:00
symutil.pas
syscinfo.pas
systems.inc
systems.pas powerpc-morphos: enable 'section' keyword support, and force the startup code to be in the .text section, to fix linking external objects with unnamed sections on this platform 2022-08-27 19:19:42 +02:00
tgobj.pas
tokens.pas
triplet.pas Darwin version comparisons: factored out into object 2022-09-16 11:21:05 +02:00
verbose.pas * change ChangeMessageVerbosity from String to AnsiString as long parameters might be passed to it 2022-06-14 14:33:21 +02:00
version.pas
wasmbase.pas + introduced TWasmCustomDebugSectionType 2022-08-03 23:04:53 +03:00
widestr.pas
wpo.pas
wpobase.pas
wpoinfo.pas

This directory contains the sources of the Free Pascal Compiler

If you want to compile/modify the compiler, please read first the
programmers manual.

To recompile the compiler, you can use the batch files :
 + mppc386.bat    if you want to build a cross compiler from i386 to m68k
 + mppcsparc      if you want to build a cross compiler from i386 to SPARC
 
 or
Use the make utility as following
  
      make OS_TARGET="compiler OS target" \
      CPU_TARGET="compiler CPU target" \
      FPCCPUOPT="Optimization level" \
      PP="compiler used to compile FPC" \
      COMPILER_OPTIONS="Options passed to compiler" \
      
      
If an option is omitted, then target CPU/OS will be same as current CPU/OS
 
Possibles targets are : linux go32v2 win32 os2 freebsd beos netbsd amiga haiku
atari sunos qnx netware openbsd wdosx palmos macos macosx emx
   
Possible compiler switches (* marks a currently required switch):
  -----------------------------------------------------------------
  GDB*                support of the GNU Debugger
  I386                generate a compiler for the Intel i386+
  x86_64              generate a compiler for the AMD x86-64 architecture
  M68K                generate a compiler for the M68000
  SPARC               generate a compiler for SPARC
  POWERPC             generate a compiler for the PowerPC
  VIS                 generate a compile for the VIS
  DEBUG               version with debug code is generated
  EXTDEBUG            some extra debug code is executed
  SUPPORT_MMX         only i386: releases the compiler switch
                      MMX which allows the compiler to generate
                      MMX instructions
  EXTERN_MSG          Don't compile the msgfiles in the compiler, always
                      use external messagefiles, default for TP
  NOAG386INT          no Intel Assembler output
  NOAG386NSM          no NASM output
  NOAG386BIN          leaves out the binary writer, default for TP
  NORA386DIR          No direct i386 assembler reader
  TEST_GENERIC        Test Generic version of code generator
                      (uses generic RTL calls)
  -----------------------------------------------------------------
  cpuflags            The target processor has status flags (on by default)
  cpufpemu            The target compiler will also support emitting software
                       floating point operations
  cpu64bitaddr        The targets use a 64-bit address space (pointers and
                       the default integer type are 64 bit)
  cpu64bitalu         The target cpu has 64-bit registers available (unless
                       cpu64bitaddr is also defined, pointers and default
                       integer type remain 32 bit, but the cpu can perform
                       64 bit calculations directly without needing helpers)
  -----------------------------------------------------------------

  Required switches for a i386 compiler be compiled by Free Pascal Compiler:
  GDB;I386

to build a compiler to SPARC target using a Win32/i386 you just use :
      make CPU_TARGET=SPARC