Commit Graph

234 Commits

Author SHA1 Message Date
marco
fb97d7c467 --- Merging r45802 into '.':
U    rtl/powerpc/powerpc.inc
--- Recording mergeinfo for merge of r45802 into '.':
 U   .

# revisions: 45802
r45802 | karoly | 2020-07-17 23:28:49 +0200 (Fri, 17 Jul 2020) | 1 line
Changed paths:
   M /trunk/rtl/powerpc/powerpc.inc

powerpc: also drop DCBZ usage on AmigaOS4, as it runs on hardware with other than the assumed cacheline size

git-svn-id: branches/fixes_3_2@48123 -
2021-01-09 22:22:30 +00:00
pierre
7778c7d8ae Disable dcbz code for AIX also
git-svn-id: trunk@38975 -
2018-05-11 15:49:35 +00:00
pierre
a69942852f Fix to avoid access of memory outside of array size if overlap is true
git-svn-id: trunk@38674 -
2018-04-03 21:02:49 +00:00
florian
ff86c80176 * cpu specific header file for the system unit: cpuh.inc, moved several declarations into it
git-svn-id: trunk@37542 -
2017-11-01 16:33:30 +00:00
Károly Balogh
0b561b6c8f powerpc: enable SUPPORT_GET_FRAME
git-svn-id: trunk@36698 -
2017-07-08 23:51:55 +00:00
Jonas Maebe
1b42affa8f * optimized PowerPC version of changes in r35454
git-svn-id: trunk@35458 -
2017-02-19 20:27:39 +00:00
florian
7213a13081 * split fpc_mul_<64 bit> into separate procedures with and without overflow checking
git-svn-id: trunk@35454 -
2017-02-19 19:15:14 +00:00
Károly Balogh
df0ac8cb02 powerpc: MorphOS recently started supporting the G5s, and it runs the G5s in non-G4-compatible mode much like Linux, therefore the DCBZ code seems to fail on them. So disable DCBZ usage for MorphOS as well.
git-svn-id: trunk@31132 -
2015-06-20 22:51:53 +00:00
sergei
a8bc2085e8 - Delete strpas.inc files, no longer used, their contents has been merged into corresponding $(CPU).inc.
git-svn-id: trunk@27833 -
2014-05-31 00:49:40 +00:00
sergei
e5f6f9c3a1 - powerpc and powerpc64: cleaned out code corresponding to FPC_STRTOSHORTSTRINGPROC not defined (obsolete and removed from other targets long ago). Also merged strpas.inc files into powerpc*.inc, because by now they are included only once and therefore don't need to be separate files.
git-svn-id: trunk@27832 -
2014-05-31 00:45:21 +00:00
sergei
217bac7a0b - Removed fpc_pi_real compilerproc, it is no longer used. At least two releases (2.6.2 and 2.6.4) emit Pi directly as a constant.
git-svn-id: trunk@27500 -
2014-04-07 09:16:24 +00:00
sergei
bce33ee063 * software_rounding_mode -> softfloat_rounding_mode.
git-svn-id: trunk@27219 -
2014-03-21 07:45:13 +00:00
sergei
94a045aa3d * Moved declarations of TFPURoundingMode,TFPUExceptionMask and TFPUPrecisionMode to System unit. Declarations in Math unit changed to aliases.
* Changed type of softfloat_exception_mask and softfloat_exception_flags to TFPUExceptionMask, softfloat_rounding_mode to TFPURoundingMode.
- Cleaned out numerous conversions happening when getting/setting exception mask and rounding mode.

git-svn-id: trunk@27215 -
2014-03-20 22:44:46 +00:00
sergei
0255eb880e - Removed mathuh.inc files which are identical for all targets (except m68k, see below), their contents moved into math.pp.
+ m68k/mathu.inc: added stub implementations for missing functions.

git-svn-id: trunk@27180 -
2014-03-18 20:01:15 +00:00
pierre
8469741700 + Added additional addr pointer parameter to
get_caller_frame, get_caller_addr and dump_stack
  with default NIL value to systemh.inc.
  + Added new get_addr function.
  system.inc: Use get_addr and get_frame to call
  HandleErrorAddrFrame instead of HandleErrorFrame
  in several error functions.
  Modify dump_stack to use frame and addr parameters.
  Provide a dummy get_addr function returning nil.
  i386/i386.inc, x86_64./x86_64.inc: Provide real
  implementation of get_addr function.

git-svn-id: trunk@21697 -
2012-06-24 21:22:09 +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
8d8fc0fdee + RTL for AIX
git-svn-id: trunk@20786 -
2012-04-11 17:59:49 +00:00
sergei
4ebc34c5e7 * Promoted result type of FPC_PCHAR_LENGTH and FPC_PWIDECHAR_LENGTH to SizeInt.
+ Check for nil pointer in FPC_PWIDECHAR_LENGTH

git-svn-id: trunk@17733 -
2011-06-13 04:59:17 +00:00
Jonas Maebe
5cbe12c622 * don't overwrite the target value of interlockedcompareexchange*() if the
value is different from the comparand (patch by "FVI", mantis #18082)
  * sign extend the loaded value of interlockedcompareexchange() on PowerPC64,
    because the function arguments are longints

git-svn-id: trunk@16475 -
2010-11-29 12:53:10 +00:00
Jonas Maebe
c14574bb56 * don't change the fpu control word in the initialisation code of dynamic
libraries (mantis #16263, #16801)

git-svn-id: trunk@16347 -
2010-11-14 16:00:25 +00:00
florian
24fea58b92 + initial implementation of iso style gotos in iso mode
* made setjmp/longjmp accessible to the compiler by compiler proc, they are used by the iso goto code

git-svn-id: trunk@15711 -
2010-08-05 19:20:46 +00:00
Jonas Maebe
a527b6b2b4 * optimized ppc memory barrier implementations
git-svn-id: trunk@14803 -
2010-01-25 14:49:33 +00:00
Jonas Maebe
c2c68ddb8f - removed FPC_NEW_BIGENDIAN_SETS define and if(n)defs
* left old cpu-specific set helper code under ifdef FPC_OLD_BIGENDIAN_SETS
    in case someone wants to write new assembler set helpers (although most
    of them should be optimally generated by the compiler already if
    http://wiki.freepascal.org/FPC_HowToDo#Bit.28field.29_getting.2Fsetting_primitives
    are optimally implemented)

git-svn-id: trunk@13582 -
2009-08-23 08:16:40 +00:00
Jonas Maebe
a24db8854c * fixed return value of InterlockedCompareExchange(64) for ppc/ppc64,
bug exposed by tw13281

git-svn-id: trunk@13133 -
2009-05-11 07:26:48 +00:00
Jonas Maebe
30a51c2dee + support for the different rounding modes in the generic rounding
routines (mantis #11392)

git-svn-id: trunk@11290 -
2008-06-27 17:20:56 +00:00
Jonas Maebe
65aa64d4ed * fixed ClearExceptions (clear pending exceptions instead of all config
bits)

git-svn-id: trunk@11244 -
2008-06-18 18:51:09 +00:00
micha
83b7f81f81 + add no-fpu support to compiler/rtl for powerpc-linux (-Cfnone)
git-svn-id: trunk@10422 -
2008-03-02 12:59:02 +00:00
Jonas Maebe
8349cde7db * changed byte/word/longbool to be Delphi-compatible (+ similar changes
for qwordbool) + test:
    o assigning true to such a variable now sets them to $ff/$ffff/$ffffffff
    o these types are now all signed
    o converting an integer type to a byte/word/long/qwordbool using an
      explicit type cast keeps the integer's original value stored in the
      bool, instead of forcing it to ord(true)/ord(false)
    (mantis #10233 and #10613, implemented for all architectures, testsuite
     tested for ppc32, sparc and x86)
  * fixed some places where the rtl depended on longbool(true) having the
    value 1
  * extended several boolean tests (and adapted some to no longer assume
    that byte/word/long/qwordbool(true)=1)
  + support for converting to qwordbool in second_int_to_bool for x86, ppc
    and sparc

git-svn-id: trunk@9898 -
2008-01-24 21:30:55 +00:00
peter
2a479654f1 * remove asm for simple math functions so the generic inlined function is
taken. This generates smaller optimized code

git-svn-id: trunk@9796 -
2008-01-19 20:23:27 +00:00
florian
7da7364ee7 * refactored SysResetFPU into SysInitFPU and SysResetFPU
git-svn-id: trunk@8966 -
2007-10-28 12:06:49 +00:00
Jonas Maebe
e64b973cf9 * fixed ppc and ppc64 compilation after r8898
git-svn-id: trunk@8906 -
2007-10-21 22:15:19 +00:00
Jonas Maebe
107682e148 * fixed comparedword
* fixed properties

git-svn-id: trunk@8811 -
2007-10-15 10:54:49 +00:00
Jonas Maebe
335bc9fd46 + PIC support for darwin/ppc32 (-Cg works now, no regressions in test
suite compiled with -Cg compared to without -Cg)
  + support for using a virtual register as PIC/got base register
  * moved got loading code from ncgutil to cgobj/cgcpu (can't test whether
    it didn't break anything under linux/i386, because "make cycle OPT=-Cg"
    was already broken due to the *prt*.as -> si_*.pp changes)

git-svn-id: trunk@8651 -
2007-09-26 16:41:32 +00:00
micha
d95b9082bb * add memory barrier prototypes + implementation for i386 and sparc + use lwsync for powerpc64
git-svn-id: trunk@8240 -
2007-08-07 20:37:08 +00:00
micha
7475f656f8 + add memory barrier routines for powerpc/64
git-svn-id: trunk@8179 -
2007-07-28 12:47:48 +00:00
Jonas Maebe
5cf2511283 - removed/disabled all normalset code (except for bootstrapping), since
it's no longer needed

git-svn-id: trunk@7403 -
2007-05-20 11:19:36 +00:00
Jonas Maebe
a0b57eddb5 * new internal set format for big endian systems. Advantages:
* varsets ({$packset x}) are now supported on big endian targets
    * gdb now displays sets properly on big endian systems
    * cleanup of generic set code (in, include/exclude, helpers), all
      based on "bitpacked array[] of 0..1" now
  * there are no helpers available yet to convert sets from the old to
    the new format, because the set format will change again slightly
    in the near future (so that e.g. a set of 24..31 will be stored in
    1 byte), and creating two classes of set conversion helpers would
    confuse things (i.e., it's not recommended to use trunk currently for
    programs  which load sets stored to disk by big endian programs compiled
    by previous FPC versions)
  * cross-endian compiling has been tested and still works, but one case
    is not supported: compiling a compiler for a different endianess
    using a starting compiler from before the current revision (so first
    cycle natively, and then use the newly created compiler to create a
    cross-compiler)

git-svn-id: trunk@7395 -
2007-05-19 17:15:15 +00:00
florian
fc027d16c5 * syntax error in last commit fixed
git-svn-id: trunk@5966 -
2007-01-14 10:45:21 +00:00
florian
b3a1868ff0 * correct masking of exceptions in genmath code
git-svn-id: trunk@5965 -
2007-01-14 10:44:10 +00:00
peter
2f0ce31751 * string concat changed from function to procedure to
allow runtime optimization if the destination is the
    same as a source parameter
  * tassignmentnode now sets aktassignmentnode global that can be used
    to use the left node as a destination parameter and
    skip the assignment
  * disabled all cpu specific shortstr concat/append

git-svn-id: trunk@4770 -
2006-10-02 20:00:06 +00:00
tom_at_work
aa8d214759 * 2.0.4 fix: fixed move()/fillchar() for linux, avoiding use of dcbz which causes crashes on G5
git-svn-id: trunk@4137 -
2006-07-09 18:25:41 +00:00
Jonas Maebe
bf1e95e024 + InterlockedCompareExchange (+ changed line endings from dos to unix)
git-svn-id: trunk@3945 -
2006-06-25 18:16:32 +00:00
peter
4c065bce45 * move InterLocked functions to system unit
git-svn-id: trunk@3933 -
2006-06-25 09:26:23 +00:00
Jonas Maebe
35fe1b27cd * GetExceptionMask returned inverted result for exInvalidOp
git-svn-id: trunk@3148 -
2006-04-05 07:46:18 +00:00
Jonas Maebe
0517ce08e2 * fixed ppc fpu exception mask stuff in math unit
+ added test for this functionality

git-svn-id: trunk@3136 -
2006-04-03 11:29:37 +00:00
Jonas Maebe
76857dbca9 * set result of SetPrecisionMode()
git-svn-id: trunk@2055 -
2005-12-26 15:52:57 +00:00
Jonas Maebe
5b9f58ef73 * reverted r2037 because of braindead "out" semantics for refcounted
types

git-svn-id: trunk@2045 -
2005-12-24 01:06:05 +00:00
Jonas Maebe
84aab46550 * changed formal "var" paramters of move, movechar0 and fill* into
"out" parameters to avoid wrong "uninitialized" warnings

git-svn-id: trunk@2037 -
2005-12-23 20:59:08 +00:00
tom_at_work
174297c4cf * ppc32: added FPU configuration code in math unit (fixes tw3161)
git-svn-id: trunk@1787 -
2005-11-20 01:21:55 +00:00
tom_at_work
9e7d550455 * fixed last commit (1337) which broke some files in the repository
git-svn-id: trunk@1338 -
2005-10-08 17:23:44 +00:00