Commit Graph

495 Commits

Author SHA1 Message Date
Tomas Hajny
2cb7b4cf0f * fixed a silly bug from r20694
git-svn-id: trunk@20852 -
2012-04-11 21:12:03 +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
florian
d1e16c3cd4 + define CPUX86 on i386 and CPUX64 on x86-64, resolves #21670
git-svn-id: trunk@20726 -
2012-04-06 21:05:09 +00:00
Tomas Hajny
b12c38984b * fpc binary supported options made localizable and not shown separately from those handled by ppc* any longer
git-svn-id: trunk@20694 -
2012-04-02 22:11:21 +00:00
Jonas Maebe
6ba8dc7146 + support for the ARM hard float EABI on Linux (patch by Peter Green):
o new eabihf (hard float) abi
   o vfpv3_d16 variant of VFP (default variant used by EABI assemblers: VFPv3
     with only 16 double registers instead of 32) and pass it to GNU as
   o make the odd numbered single precision floating point VFP registers
     available for explicit allocation for use by the calling convention
  * fixed copy/paste error in stdname of S30 register
  -> use -dFPC_ARMHF to create an ARM eabi hard float compiler
  (mantis #21554)

git-svn-id: trunk@20660 -
2012-03-29 20:50:09 +00:00
svenbarth
bf5695c455 Allow unsetting the option for C-operators (-Sc-).
git-svn-id: trunk@20639 -
2012-03-27 11:40:10 +00:00
Jonas Maebe
4fd9d98dbb * correctly set default version for iPhoneOSVersionMin rather than for
MacOSXVersionMin when targeting iOS/iphonesim

git-svn-id: trunk@20536 -
2012-03-18 11:05:36 +00:00
Jonas Maebe
eb2cccffda + -WM<X> and -WP<x> command line parameters to specify the minimally required
Mac OS X/iOS version for the compiler code
   o such a parameter is not passed, extract the information from the
     environment variables MACOSX_DEPLOYMENT_TARGET/IPHONEOS_DEPLOYMENT_TARGET,
     like gcc
   o if neither the parameter nor the environment variable is used, use preset
     default values
   o pass on this version setting on to the Darwin linker
   o use this setting to determine which version of the startup code (crt1.o
     etc) to use, if any (based on information gathered from the GCC sources)
   o define a symbol called MAC_OS_X_VERSION_MIN_REQUIRED/
     IPHONE_OS_VERSION_MIN_REQUIRED based on this parameter
   o for usage information, see
     http://wiki.freepascal.org/FPC_New_Features_Trunk#Support_for_specifying_and_querying_the_deployment_version

git-svn-id: trunk@20503 -
2012-03-10 19:31:57 +00:00
sergei
92f927976e * Rewrote fpc_dynarray_copy to trim out-of-range arguments instead of raising range error. Makes behavior Delphi-compatible and resolves #21396.
* Changed copying the entire array to use range 0..high(sizeint) instead of -1..-2.

git-svn-id: trunk@20468 -
2012-03-04 04:41:52 +00:00
pierre
4a351f42fe Commit some MIPS changes
git-svn-id: trunk@20219 -
2012-02-02 23:43:52 +00:00
sergei
cbad0abab5 + Platform-specific exception support for x86_64-win64. Enable by cycling with OPT=-dTEST_WIN64_SEH.
git-svn-id: trunk@20098 -
2012-01-16 23:13:31 +00:00
florian
e0d7af703a * proper feature handling for gba
* slinebreak shall be a real constant

git-svn-id: trunk@19973 -
2012-01-05 17:27:02 +00:00
sergei
49700e675c * Changed code generation for variant assignments to typecast arguments to TVarData instead of using pointers. Fixes one (probably the ugliest one) case of non-disposed temp variables:
When arguments are temps, they are supposed to be released by tcgcallnode.release_para_temps. However, taking address with taddrnode effectively changes original location of temp to some LOC_REGISTER, tcgcallnode.release_para_temps no longer sees the original location and therefore does not free such temps.

git-svn-id: trunk@19959 -
2012-01-03 19:31:58 +00:00
florian
2dc2d65b1a + on windows, search %ALLUSERSPROFILE% and %USERPROFILE% for fpc.cfg
git-svn-id: trunk@19927 -
2011-12-30 16:20:27 +00:00
florian
c12a4989d0 + use cpurox define in the compiler for CPUs having internal ror/rol support
+ optimize (i shl x) or (i shr (bitsizeof(i)-x)) and friends into rol/ror(x,i)

git-svn-id: trunk@19635 -
2011-11-13 18:40:34 +00:00
florian
73a084d662 * fixes bootstrapping with 2.6.0
git-svn-id: trunk@19491 -
2011-10-15 12:42:33 +00:00
paul
21ac5dfb3b compiler: output ansistring constants in explicit codepage if codepage is explicitly defined using either $codepage directive or compiler switch or for SystemCodepage modeswitch
git-svn-id: trunk@19462 -
2011-10-11 08:58:56 +00:00
marco
cf7b43948a * cmdstr is ansistring now. Running ppc386 "" could cause access of string[1] while length(string)=0
git-svn-id: trunk@19394 -
2011-10-06 18:16:12 +00:00
florian
a6d01c09aa * make compiler compilable with 2.4.4 rtl
git-svn-id: trunk@19269 -
2011-09-28 18:54:32 +00:00
florian
d7f7a9bb76 * patch by Alexander Shishkin to clean up $ifopt usage by $push/$pop, resolves #20346
git-svn-id: trunk@19256 -
2011-09-27 20:22:40 +00:00
pierre
313daaa44a Use Windows TLS Callback by default
git-svn-id: trunk@19151 -
2011-09-19 18:39:31 +00:00
paul
4d3da666db compiler: replace string codepage comparison to numeric. store codepage as number in current settings
git-svn-id: trunk@19144 -
2011-09-19 00:48:43 +00:00
paul
1db610ecbd merge r17434 from cpstrnew branch by michael:
* Patch from Inoussa to fix constant strings with codepage

git-svn-id: trunk@19109 -
2011-09-17 13:19:59 +00:00
paul
091627883f merge r14347 from cpstrnew branch by florian:
* fixed bootstrapping with 2.4.0
* patches by Graeme Geldenhuys, resolve #15251, #15252, #15253

git-svn-id: trunk@19102 -
2011-09-17 12:00:06 +00:00
pierre
a5d2840980 + Fix commit 19061, by restoring cs_link_smart code and disabling
cs_create_smart if using dwarf information and external assembler
   debug information as this is not compatible.
 * Added a different message for cs_create_smart.

git-svn-id: trunk@19065 -
2011-09-14 13:38:15 +00:00
pierre
5d39f2208a * Consider cs_create_smart instead of cs_link_smart for disabling
smartlink creation if using external assembler and Dwarf debugging
 * Call CheckOptionsCompatibility again after setting currentt assembler

git-svn-id: trunk@19061 -
2011-09-14 12:13:05 +00:00
sergei
689d4b3ecc + Mantis #19651: Generate table of typed string constants which are initialized with resourcestrings, so they are updated when SetResourceStrings or SetUnitResourceStrings is called.
git-svn-id: trunk@18968 -
2011-09-04 16:01:26 +00:00
florian
a08dfdf803 o slightly modified patch by John Clymer:
* converts the embedded information into controller specific records (arm and avr)
  * new cpu-specific units for several Stellaris (Fury and Tempest class) targets, 
  + STM32F103RB
  - old Stellaris unit has been removed

git-svn-id: trunk@18848 -
2011-08-25 21:46:26 +00:00
florian
5c9e0a7a1b + V is avr help screen option
git-svn-id: trunk@18013 -
2011-07-17 20:44:10 +00:00
pierre
4ad2707674 Windows TLS callback code testable by using -dTEST_TLS_DIRECTORY
git-svn-id: trunk@17906 -
2011-07-01 14:42:39 +00:00
florian
60e16260e1 o adjust define handling to resolve #19519
* ensure that all defines are written when running the compiler with -va
  * even if a define is defined/undefined, write a message if it is written again

git-svn-id: trunk@17714 -
2011-06-10 19:03:27 +00:00
florian
0b9099f13f * fixes mistake in r17664
git-svn-id: trunk@17667 -
2011-06-05 17:51:09 +00:00
florian
ebc7a10954 * synchronized -Wxxxxx handling in options.pas and help screen, resolves #19400
* limited -Wxxxxx options to the targets they apply to

git-svn-id: trunk@17664 -
2011-06-05 15:39:44 +00:00
florian
d0c6e23116 + -Sy on the command line is now equal to $T+, resolves #16160
git-svn-id: trunk@17477 -
2011-05-16 15:36:16 +00:00
florian
13285ab264 o several strings changed into ansistrings, resolves #19318, no compilation speed degrations measurable
* TCmdStr changed into an ansistring
 * command line parameter handling uses now ansistrings
 * message handling parameters are now ansistrings

git-svn-id: trunk@17469 -
2011-05-15 14:53:31 +00:00
Jonas Maebe
0da9d36116 * fixed internal assembler for x86-64 so that it correctly handles
relocations for addr_pic_no_got references (do not go via the GOT)
  * fixed code generator so that it generates addr_pic_no_got references
    also for platforms that use the internal assembler (this will break linking
    of some tests that check static data > 2GB on Linux/x86-64, but they were
    already broken before as well because we don't use the "huge" x86-64
    execution model)
  * fixed x86-64 Linux syscall code to not expect GOT-based relocations for
    the system unit's errno variable (it's an implementation-only variable)

git-svn-id: trunk@16717 -
2011-01-06 09:28:25 +00:00
florian
142e42bd81 o NativeNT target patch by Sven Barth, resolves with r16553 and r16554 #18195
* enables some disabled features for NativeNT in the compiler (all except stackcheck).

git-svn-id: trunk@16555 -
2010-12-11 20:41:37 +00:00
florian
1c5a3b6bf0 o patch by Graeme Geldenhuys
+ adds the missing DWARF3 values
  + introduces the DWARF4 values
  + basic class and debug info structures for DWARF4 support
  + added DWARF4 compiler parameter (-gw4) support
  + updated parameter description

git-svn-id: trunk@16288 -
2010-11-01 20:41:56 +00:00
florian
2ad698fd1c - remove unneeded spaces
git-svn-id: trunk@16262 -
2010-10-30 14:04:42 +00:00
joost
07bf44517c * Merged XPCom branch into trunk, added support for constref and changed
the IInterface implementation to be XPCom-compatible
--- Merging r15997 through r16179 into '.':
U    rtl/inc/variants.pp
U    rtl/inc/objpash.inc
U    rtl/inc/objpas.inc
U    rtl/objpas/classes/persist.inc
U    rtl/objpas/classes/compon.inc
U    rtl/objpas/classes/classesh.inc
A    tests/test/tconstref1.pp
A    tests/test/tconstref2.pp
A    tests/test/tconstref3.pp
U    tests/test/tinterface4.pp
A    tests/test/tconstref4.pp
U    tests/webtbs/tw10897.pp
U    tests/webtbs/tw4086.pp
U    tests/webtbs/tw15363.pp
U    tests/webtbs/tw2177.pp
U    tests/webtbs/tw16592.pp
U    tests/tbs/tb0546.pp
U    compiler/sparc/cpupara.pas
U    compiler/i386/cpupara.pas
U    compiler/pdecsub.pas
U    compiler/symdef.pas
U    compiler/powerpc/cpupara.pas
U    compiler/avr/cpupara.pas
U    compiler/browcol.pas
U    compiler/defcmp.pas
U    compiler/powerpc64/cpupara.pas
U    compiler/ncgrtti.pas
U    compiler/x86_64/cpupara.pas
U    compiler/opttail.pas
U    compiler/htypechk.pas
U    compiler/tokens.pas
U    compiler/objcutil.pas
U    compiler/ncal.pas
U    compiler/symtable.pas
U    compiler/symsym.pas
U    compiler/m68k/cpupara.pas
U    compiler/regvars.pas
U    compiler/arm/cpupara.pas
U    compiler/symconst.pas
U    compiler/mips/cpupara.pas
U    compiler/paramgr.pas
U    compiler/psub.pas
U    compiler/pdecvar.pas
U    compiler/dbgstabs.pas
U    compiler/options.pas
U    packages/fcl-fpcunit/src/testutils.pp

git-svn-id: trunk@16180 -
2010-10-17 20:58:22 +00:00
florian
5dae691c96 * implementation of bit scan intrinsics by Richard Vida, resolves #17592
git-svn-id: trunk@16174 -
2010-10-16 15:03:30 +00:00
joost
65ab1e820b * Safecall on linux/i386 now behaves like cdecl plus hidden exception support.
* Adapted tests because safecall on linux/i386 now does not include high() 
   support anymore

git-svn-id: trunk@15913 -
2010-08-27 19:07:22 +00:00
florian
0085c22c59 - NaN floating point constants do not anymore cause an error when $Q or $R is active (resolves #16315 and #14757)
+ $ieeeerrors (command line switch -C3) to enable errors on NaN floating point constants
+ tests

git-svn-id: trunk@15765 -
2010-08-10 19:05:13 +00:00
Jonas Maebe
025ec34e4d + "CExtended" type that is the same as "extended", but conforming to the
properties/behaviour of the equivalent of Extended in C (i.e., to
    "long double" on i386 and x86_64 platforms that support a 10 byte
    long double, and to "double" elsewhere)

git-svn-id: trunk@14912 -
2010-02-14 13:45:58 +00:00
florian
34f976afea * enabled internal sar support for sparc and mips as well
git-svn-id: trunk@14867 -
2010-02-04 22:04:19 +00:00
florian
dfc2652062 + support of compiler intrinsic sar* using a patch by Benjamin Rosseaux, resolves #15606
git-svn-id: trunk@14834 -
2010-01-31 16:47:01 +00:00
paul
8166148a37 compiler: 'static' keyword:
- deprecate -St compiler switch
  - remove $STATIC directive
  - unconditionally enable 'static' keyword usage
  - adopt tests, samplecfg, fpc.cft, error messages

git-svn-id: trunk@14569 -
2010-01-07 19:02:09 +00:00
florian
c1f3d8dcaa * unified names of system_*/systems_* sets
git-svn-id: trunk@14566 -
2010-01-07 18:16:20 +00:00
florian
34227e811d + patch by Sven Barth to add native NT rtl support to the compiler, resolves #14886
git-svn-id: trunk@14565 -
2010-01-07 17:42:11 +00:00
Jonas Maebe
cce3ae1a7a * disable -Xg when used in combination with generating Stabs debug info on
Mac OS X, since it's not supported on that platform

git-svn-id: trunk@14452 -
2009-12-18 16:53:06 +00:00