Commit Graph

3930 Commits

Author SHA1 Message Date
Pierre Muller
8e98e35ac2 macosclassic OS does not have unixtype unit 2023-09-25 01:02:55 +02:00
Pierre Muller
b9af293d35 syscall unit is only used when -dFPC_USE_LIBC is not used 2023-09-25 01:02:54 +02:00
Pierre Muller
5001c72510 Add unixtype nit dependency for ctypes unit for Unix OSes 2023-09-25 01:02:54 +02:00
Pierre Muller
07d4779ee5 Add pthread.inc dependency for cthreads unit 2023-09-25 01:02:52 +02:00
Pierre Muller
1ea8e8bda2 Add rtlconst.inc dependency for rtlconsts unit 2023-09-25 01:02:49 +02:00
Pierre Muller
a160b2470b Handle sysctl unit for DOTTED 2023-09-25 01:02:49 +02:00
Pierre Muller
bdfd7a66eb * Adapt initc unit to DOTTED.
* Remove OS specific initc rules.
  * Set default directory for initc main source to
    UNIXINC variable value if is is set.
  * Replace initc references by INITCUNIT variable.
  * Add dpmiexcp dependency for initc on go32v2 system
    by setting INITC_DEPS_OS.
  * Add nwsys.inc dependency for initc on netware system.
2023-09-25 01:02:48 +02:00
Pierre Muller
5f14f4447b Update console unit for DOTTED 2023-09-20 18:05:16 +02:00
Pierre Muller
9a9bbe5740 Handle DOTTED transition for termio unit 2023-09-20 18:05:16 +02:00
Pierre Muller
3c0e3b1a3f Add -Fi option for dynlibs.inc directory to DYNLIBS_OPT in dynlibs unit rule 2023-09-20 13:16:27 +02:00
Pierre Muller
82dec844c3 * Update math unit rules for dotted version
+ Add PROCINC/mathu.inc dependency in generic rule for math unit
  * Remove OS specific rules for math unit
  * Use MATHUNIT variable everywhere
2023-09-20 08:26:06 +02:00
Pierre Muller
9fe073493a * Use linux directory explicitly for fpcylix source location
* Remove android rule for fpcylix unit
  * Replace fpcylix by FPCYLIXUNIT variable
2023-09-20 07:29:58 +02:00
Pierre Muller
31d831d775 Fix CP_UNITS_SRC variable for dotted case 2023-09-19 21:29:36 +00:00
Pierre Muller
5676cf4c1a Fix CP_UNITS variable setting 2023-09-14 11:21:00 +00:00
Pierre Muller
82d40c23e7 Fix EXEINFOUNIT and CP_UNITS variable values or dotted case 2023-09-14 08:55:01 +00:00
Pierre Muller
1d56f9f324 Fix CP_UNITS_SRC variable value 2023-09-13 21:19:42 +00:00
Pierre Muller
ec310eb2f3 Add all codepage unit source files to cpall dependency 2023-09-13 20:06:34 +00:00
Pierre Muller
e77402ecb4 Add missing include files for strings unit dependency list 2023-09-12 21:39:27 +00:00
Pierre Muller
ebc34f3dbb Remove wrong ERRORSUNIT=System.Errors line 2023-09-12 21:39:27 +00:00
Pierre Muller
e2d466f990 Remove duplicated, useless line 2023-09-12 21:39:27 +00:00
Rika Ichinose
324b77f317 Let fpc_dynarray_concat(_multi) reuse the only nonempty input or append to the destination if possible.
Improve fpc_dynarray_delete.
2023-09-12 20:58:50 +00:00
Pierre Muller
16d7424a75 Set UUCHARUNIT variable 2023-09-12 07:24:28 +00:00
Pierre Muller
62fe06ce9e Do not use ISO7185UNIT variable for main source file in ISO7185_DEPS 2023-09-11 22:17:44 +00:00
Pierre Muller
5bbd1c2172 Always set MACPASUNIT variable 2023-09-11 21:50:20 +00:00
Pierre Muller
7b2507456c Set FPINTRESUNIT and OBJPASUNIT variables 2023-09-11 21:31:12 +00:00
florian
ba78551c4f * patch by Rika: improve fpc_*_concat_multi, resolves #40251 2023-09-10 19:27:55 +02:00
florian
7e69f399b3 * patch and test by Rika: fixes self inserts in Insert(x, dynarray) and improves Insert(x, dynarray), resolves #40417 2023-08-29 22:23:22 +02:00
Rika Ichinose
2536041230 Faster genset.inc:fpc_varset_set_range. 2023-08-28 20:16:54 +00:00
Rika Ichinose
1a6e6a1b0b Improve generic large set operations: +, -, *, ><, =, <=, mostly by working in PtrUints. 2023-08-16 17:15:33 +00:00
Pierre Muller
8af6ad9148 Dotted rules for arm-embedded 2023-08-10 00:23:51 +02:00
Pierre Muller
55aff2366b Add WinApi messages unit rules 2023-08-09 00:33:16 +02:00
Pierre Muller
233e3b9963 Use lowercase names for all embedded CPU specific units, as in namespaced/embedded/CPU 2023-08-09 00:33:15 +02:00
Pierre Muller
80aa3cf89c Add -Sg option for the three soft fpu units 2023-08-09 00:33:15 +02:00
Pierre Muller
d0103704a6 Fix sysutils dotted rule for OSes having local included files 2023-08-08 01:06:16 +02:00
Pierre Muller
6b185c041d Always set RTLCONSTSUNIT to rtlconsts, if FPC_DOTTEDUNITS is not defined, as OS specific changes are parsed after 2023-08-07 14:59:14 +00:00
Pierre Muller
2e4f7bcc22 Add objpas unit dependency for unicodedata because of $objfpc mode 2023-08-07 14:59:13 +00:00
Pierre Muller
bc40d13c4a Unique rule for fpwidestring unit 2023-08-06 20:58:44 +00:00
Pierre Muller
13b3f11896 Add NSWINDOWSDIR variable 2023-08-05 11:57:37 +02:00
Pierre Muller
2b82581f92 Put unique rule for unicodedata into inc/Makefile.rtl 2023-08-04 22:28:28 +00:00
Pierre Muller
53de381d87 Set DYNLIBSINCDIR to WINDIR for win32 and win64 2023-08-04 21:31:05 +00:00
Pierre Muller
df9efe4cb5 Fix syntax error 2023-08-04 17:28:54 +02:00
Pierre Muller
8b0e2cf0cd fpwidestring depends on objpas unit because of $mode objfpc 2023-08-04 17:15:46 +02:00
Pierre Muller
ba3965e987 Add a few missing dependencies on system unit, or on objpas unit because of $mode use 2023-08-04 16:31:59 +02:00
Pierre Muller
493b58d72b Handle .pas/.pp source extension differences also for dotted units 2023-08-04 14:46:45 +02:00
Pierre Muller
0c75716f11 Use uppercase UNIT names in new EMX/OS2 rules 2023-08-04 12:29:53 +02:00
Pierre Muller
ce5653897b * Move EMX/OS2 rules to inc/Makefile.rtl
+ Implement dotted versions for te mex/os2 units
  * Use lower names for OS2Api.name as in namespaced/os2 directory
2023-08-04 11:48:14 +02:00
Pierre Muller
b713b84352 Set HEAPTRCUNIT variable 2023-08-04 11:00:14 +02:00
Pierre Muller
7c7783a24a * Replace -I by -Fi iun objpas rule
* Correct fgl unit _DEPS variables
  * Set up rules for RTLCONSTSUNIT to handle both rtlconst and rtlconsts
2023-08-04 11:00:14 +02:00
Pierre Muller
21b02cb56b Add default NSOSDIR and msmouse unit rules 2023-08-02 22:35:13 +02:00
Pierre Muller
0c7c75435d Fix dotted mmx unit rule and OBJCBASE_OPT 2023-08-02 15:21:16 +02:00
Pierre Muller
d12bc9e9b9 Add FPC_DOTTEDUNITS code 2023-08-02 15:20:27 +02:00
Pierre Muller
93c116ff19 Small fixes need to get i386-linux dotted ready.
* Add explicit -dFPC_DOOTEDUNITS for fpcylix unit
  * Add dependecy on sysutils for cpu unit
  * Add missing CPU_DEPS for System.CPU.ppu rule
2023-08-02 14:21:42 +02:00
Pierre Muller
0d8d363de4 Add WINDIRSDIR variable 2023-08-02 12:58:02 +02:00
Pierre Muller
ac91cbb2e5 Add explicit dependency of Windows unit to objpas 2023-08-02 11:25:58 +02:00
Pierre Muller
d3d39001bc i8086 CPU also needs sysutils unit as dependecy for cpu unit 2023-08-01 10:04:24 +02:00
Pierre Muller
67cfa79659 * Add dependency of lineinfo unit on exeinfo.
* System.ExeInfo depends on EXEINFO_DEPS, not on LINEINFO_DEPS
  * lnfodwrf unit does not depend on lineinfo unit
  * lnfogdb depends on ctypes, baseunix and unix units, but not on lineinfo
2023-07-31 14:56:53 +02:00
Michaël Van Canneyt
681a00a76f * Fixes based on feedback of team, fixes issue #40368 2023-07-30 11:19:47 +02:00
Michaël Van Canneyt
7e7eb033fc * Renamed so as not to be automatically detected, in line with Makefile.pkg in packages dir 2023-07-30 08:27:38 +02:00
Michaël Van Canneyt
27ce569b0b * Fix EOL escapes, regenerate makefiles 2023-07-28 12:49:13 +02:00
Michael VAN CANNEYT
ccfa38c68e * Dotted RTL compiles 2023-07-27 19:04:03 +02:00
Michael VAN CANNEYT
ed50a1941b * Unicode resource strings 2023-07-25 16:06:53 +02:00
Michael VAN CANNEYT
efc0272b99 * Zero out stringmanager record 2023-07-24 15:38:09 +02:00
Michael VAN CANNEYT
8ef4625e4d * UnicodeString<>WideString on windows 2023-07-24 15:38:09 +02:00
Michael VAN CANNEYT
b5dd1f9beb * Fix windows compilation 2023-07-24 15:38:09 +02:00
Michaël Van Canneyt
defc7e99d1 * Fix compilation for avr-embedded (no unicode strings) 2023-07-24 14:54:30 +02:00
Michaël Van Canneyt
fb5b891c45 * Fix issue #40360 2023-07-23 23:32:37 +02:00
Michaël Van Canneyt
ceddc2aec3 * TArray is now in system unit 2023-07-22 15:30:30 +02:00
Michaël Van Canneyt
757d2b4f91 * Move TMarshal to system unit 2023-07-22 15:24:27 +02:00
Rika Ichinose
7f4420495b TMarshal & TMarshaller, strange things from Delphi. 2023-07-22 15:24:27 +02:00
Michaël Van Canneyt
4c529287c6 * string -> shortstring 2023-07-22 08:26:22 +00:00
Michaël Van Canneyt
9cfe6e97a0 * add uachar loading for unicode rtl 2023-07-22 08:26:22 +00:00
Michaël Van Canneyt
56006aa002 * Allow widechar sets, reduce to ansichar set 2023-07-22 08:26:22 +00:00
Michaël Van Canneyt
8af6fdefa8 * Better length check 2023-07-17 10:04:46 +02:00
Michaël Van Canneyt
0be4498284 * Add length check 2023-07-17 10:02:15 +02:00
Michaël Van Canneyt
33dba31536 * Add overload to fix issue 40931 in lazarus 2023-07-16 19:06:22 +02:00
Michael VAN CANNEYT
6084bb6d09 * Some forgotten string -> shortstring instances 2023-07-14 20:13:43 +02:00
Michael VAN CANNEYT
4bddf12657 * Fix typo 2023-07-14 17:26:11 +02:00
Michael VAN CANNEYT
3aefada11a * check zero length instead of comparing to empty string 2023-07-14 17:26:11 +02:00
Michael VAN CANNEYT
f04577d292 * check zero length instead of comparing to empty string 2023-07-14 17:26:11 +02:00
Michael VAN CANNEYT
b69c78ccce * String -> ShortString/RTLString 2023-07-14 17:26:11 +02:00
Michael VAN CANNEYT
3085eac501 * String -> ShortString 2023-07-14 17:26:11 +02:00
Michael VAN CANNEYT
e98ef65b6f * Restore char/pchar 2023-07-14 17:26:11 +02:00
Michael VAN CANNEYT
bcaf82f5e7 * String -> ShortString 2023-07-14 17:26:11 +02:00
Michael VAN CANNEYT
31ef662201 * check zero length instead of comparing to empty string 2023-07-14 17:26:11 +02:00
Michael VAN CANNEYT
f75f208992 * Add IndexChar for widechar 2023-07-14 17:26:11 +02:00
Michael VAN CANNEYT
1671010086 * string -> shortstring, check zero length instead of comparing to empty string 2023-07-14 17:26:11 +02:00
Michael VAN CANNEYT
bec6b8c249 * string -> shortstring, check zero length instead of comparing to empty string 2023-07-14 17:26:11 +02:00
Michael VAN CANNEYT
62d650d926 * string -> shortstring 2023-07-14 17:26:11 +02:00
Michael VAN CANNEYT
01b70479a0 * string -> shortstring, check zero length instead of comparing to empty string 2023-07-14 17:26:11 +02:00
Michael VAN CANNEYT
4d42d013b8 * check zero length instead of comparing to empty string 2023-07-14 17:26:11 +02:00
Michael VAN CANNEYT
057cfc100c * check zero length instead of comparing to empty string 2023-07-14 17:26:11 +02:00
Michael VAN CANNEYT
581dfc6d28 * string -> ansistring 2023-07-14 17:26:11 +02:00
Michael VAN CANNEYT
775408b21b * string -> shortstring 2023-07-14 17:26:11 +02:00
Michael VAN CANNEYT
c29d36e369 * string -> shortstring 2023-07-14 17:26:11 +02:00
Michael VAN CANNEYT
dafe77b954 * string -> shortstring, check zero length instead of comparing to empty string 2023-07-14 17:26:11 +02:00
Michaël Van Canneyt
f36ec0ed7f * Fix non-unix compilation 2023-07-14 17:26:10 +02:00
Michael VAN CANNEYT
2339db3b00 * Fix compilation 2023-07-14 17:26:10 +02:00
Michael VAN CANNEYT
d2d3fe6bc3 * Char -> AnsiChar 2023-07-14 17:26:10 +02:00
Michaël Van Canneyt
bd03612527 * Typo fixed 2023-07-13 17:24:51 +02:00
Michaël Van Canneyt
6e5c4667cd * Do not compile pointer overloads of atomic operations for MS-DOS/i8086 2023-07-13 16:18:04 +02:00
Michaël Van Canneyt
517d1b017c * Interface thunk class must query owner object interface list 2023-07-11 17:47:03 +02:00
Michaël Van Canneyt
70282826ad * Parent class for hidden TVirtualInterface thunking class 2023-07-11 08:36:57 +00:00
Pierre Muller
032158d943 Fix system compilation for CPU16 2023-07-10 07:04:11 +02:00
Pierre Muller
ba2b29bd2c Fix cpu16 error in AtomicCmpExchange 2023-07-10 06:54:18 +02:00
Michaël Van Canneyt
96921aaba3 * Fix NilValue 2023-07-09 16:48:07 +02:00
Michaël Van Canneyt
2a87366086 * Delphi compatibility aliases for Interlocked* functions 2023-07-09 15:44:55 +02:00
Michaël Van Canneyt
b121045d4a * TPtrWrapper for Delphi compatibility 2023-07-09 15:05:53 +02:00
Jinyang He
6ef31c643a Set STACK_MARGIN_MAX to four times of pagesize on LoongArch64
It fixed a test named tstack. Actually, Linux user get the stacktop is
incorrect in current. The value of stack pointer when enter the procedure
is thought as it is in the highest stack page. But if the parameters is
enough large, lager than 16k, most of arch will also fail this test.
Since the LoongArch default pagesize is 16k, it fail often because
stack-layout-randomization causes the stackpointer underflow to next page.
I had tried fixed it in rtl/linux/[arch]/si_*. But because the codes is
unworthy and hardly the parameters is enough large, just expand
STACK_MARGIN_MAX for simplicity.
2023-06-21 07:27:36 +00:00
Michaël Van Canneyt
b8738944ed * Add TNoRefCountObject (delphi compatibility) 2023-06-05 11:43:07 +02:00
marcoonthegit
452ec93f06 * implement waitformultiple for win32 only.
* Change interface to allow for COM waiting + a basic windows implementation. (only for desktop apps? Use msgwait* for the rest?)
2023-05-20 14:37:26 +02:00
Michaël Van Canneyt
86ffe69380 * Better signature for Initialize/Finalize dummies 2023-03-19 15:22:54 +01:00
Rika Ichinose
98fa292b20 SSE2 Index* and Compare* for i386, chosen at runtime. 2023-03-17 20:42:50 +00:00
florian
f0ac02cb2e * patch by Rika: Remove wrong paranoia (and add correct one (and shorten in general (and fix a bug in))) fpc_dynarray_setlength, resolves #40193 2023-03-12 22:15:55 +01:00
florian
73b528d170 * patch by Rika: Remove dead code in DynArrayIndex, resolves #40194 2023-03-11 11:55:41 +01:00
florian
6a902660a5 * patch by Rika: Make more use of fpc_*_array (mainly fpc_addref_array) in rtl/inc/dynarr.inc, resolves #40174 2023-02-28 21:54:05 +01:00
florian
159fa78514 * patch by Rika: fix for 15f29b8fa0 2023-02-26 10:52:35 +01:00
Rika Ichinose
f0811e448d Improve generic CompareWord. 2023-02-25 22:52:38 +00:00
florian
15f29b8fa0 * patch by Rika: Perform 32-bit random if the bound fits into 32 bits at runtime, resolves #40171 2023-02-25 19:57:50 +01:00
Rika Ichinose
ee5b9e53a9 Improve generic CompareDWord. 2023-02-19 18:07:46 +00:00
Jinyang He
664c613d96 add loongarch64 rtl support 2023-02-05 19:18:48 +00:00
Jonas Maebe
ffa14ee448 Utf8CodePointLen: remove pointer arithmetic to fix JVM compatibility 2023-02-05 10:58:59 +01:00
Rika Ichinose
b38d13577f Make Utf8CodepointLen adhere to the Unicode standard somewhat more and know all of the Unicode 15.0 combining characters. 2023-01-30 13:51:31 +00:00
florian
84e7a17b67 * patch by Rika: optimize Pos(), resolves #40088 2023-01-23 22:51:40 +01:00
florian
a06c034189 * cleanup of outdated defines 2023-01-20 23:31:04 +01:00
florian
218da184e6 * patch by Rika: Improve generic CompareByte, resolves #40120 2023-01-19 22:44:25 +01:00
Rika Ichinose
30e3d93d57 Make generic Index* faster and denser. 2023-01-09 21:26:00 +00:00
florian
7bd5613954 * fix error on win64 and concerns about pulling math into the windows unit by a local arctan2 copy 2022-12-30 22:28:49 +01:00
marcoonthegit
5fb88cef00 * Tpoint.Angle initial version using arctan2 2022-12-30 19:34:03 +01:00
Michaël Van Canneyt
2c3b78682a * Add IsConstValue 2022-11-29 09:05:42 +01:00
Michaël Van Canneyt
348fbfde9d * Add stub for IsManagedType 2022-11-28 10:39:17 +01:00
florian
c1ec558d0a * first (modified, added a comment) patch by Rika to improve generic Index*, part of #39996 2022-11-17 23:11:23 +01:00
Pierre Muller
5e0eb521c4 Fix use of unaligned for big endian code 2022-11-15 21:48:40 +00:00
ccrause
031c16dd3c Fix potential overflow when incrementing 8 bit high value of res. 2022-11-05 11:19:58 +02:00
Pierre Muller
9b6926c5f5 Introduce CTYPES_INLINE, enabled by default but which can be disabled using -dDISABLE_INLINE for ctypes unit 2022-11-04 22:21:29 +00:00
Pierre Muller
afc9acda37 Change wrong "$macros off" into "$macro off" 2022-10-22 15:54:49 -05:00
ccrause
991460c4ee Rewrite fpc_shortstr_concat_multi for AVR to not use a temporary shortstring to reduce RAM usage. 2022-10-19 20:18:56 +00:00
Jonas Maebe
0758aa1143 FPU exception mask: generlised system unit interface 2022-10-17 19:43:01 +00:00
florian
9f293df425 * export DynArrayAssign, resolves #39897 2022-10-06 22:56:38 +02:00
Pierre Muller
5913434ba9 Add DISABLE_SYSTEMINLINE check to be able to avoid setting SYSTEMINLINE macro 2022-09-20 22:39:28 +01:00
Sven/Sarah Barth
8595c927a8 * fix #39876: correctly Read(Str) enum types which have a size smaller than 4 Byte
+ added tests
2022-08-26 17:16:29 +02:00
florian
799c22d553 Revert " * patch by Rika: SwapEndian([u]int16) has unnecessary “and $FFFF”, resolves #39814"
This reverts commit f92102a5f2.

The and $ffff is needed to avoid range check warnings when the function is inlined with a constant parameter
2022-07-15 18:56:11 +02:00
florian
f92102a5f2 * patch by Rika: SwapEndian([u]int16) has unnecessary “and $FFFF”, resolves #39814 2022-06-27 22:45:01 +02:00
Nikolay Nikolov
bc6ab39ea2 * WebAssembly exceptions fix: fixed raise without parameters in except..end
blocks in WebAssembly native and branchful exceptions mode. Fixes #39752
2022-06-21 05:43:35 +03:00
marcoonthegit
5418ccf31e * fix bootstrapping *BSD with 3.2.2, which isn't flagged as supporting weakexternal on those targets 2022-06-18 14:52:24 +02:00
marcoonthegit
46de243fe6 * fix bootstrap with 3.2.2, whi 2022-06-18 14:50:13 +02:00
Sven/Sarah Barth
ae346a87a1 * ensure that the heaptrc unit can be used on Linux and BSD without linking against the C library 2022-06-15 22:55:13 +02:00
florian
1d8b21bcfc * align memory blocks in cmem at least to stack alignment boundaries, resolves #39730 2022-06-04 22:27:51 +02:00
Jonas Maebe
25e832940c llvmdbg: support for generating debug information for local/para varsyms
Note that not all symbols are covered yet, because absolutevarsyms are not
yet supported and those are e.g. used for function result aliases.
Additionally, not all types are fully supported yet.
2022-06-04 22:26:40 +02:00
Nikolay Nikolov
c9ed14f87b + enable the 64-bit SAR instruction on the WebAssembly target 2022-05-27 22:56:05 +03:00
Nikolay Nikolov
b6aaa06f83 + enable the ROL/ROR instructions for WebAssembly 2022-05-27 22:46:32 +03:00
florian
08228d7fb3 * revert a650d346f1 for now as it apparently does
not work with all language encoding
2022-02-26 21:57:42 +01:00
florian
04145589a9 * improved fpc_frac_real 2022-02-18 22:47:55 +01:00
florian
67fedc6b5b * handle frac(+/-Inf or Nan) correctly in the software implementation, resolves #39584 2022-02-17 22:00:27 +01:00
florian
308bc29465 * setting of MIPS64(EL) in system.inc fixed 2022-02-08 23:08:13 +01:00
Pierre Muller
fbed068048 Set float type information in system interface part for mips64 and mips64el CPUs 2022-02-04 20:00:40 +00:00
Sergey Larin
ee2d313aa0 Added TranslatePlaceholderCP in fpc_Read_Text_AnsiStr procedure.
This is a small optimization.
2022-01-26 20:28:17 +00:00
Sergey Larin
a8b0e0ed65 Added TranslatePlaceholderCP before Wide2AnsiMoveProc call.
In the fpc_setstring_ansistr_pwidechar procedure, before calling Wide2AnsiMoveProc, the translation cp = 0 to the DefaultSystemCodePage has been added.
Note: In all other places such translation is present.
2022-01-26 20:28:17 +00:00
florian
366aedc6d8 * more false positives of unintialized varibles worked around 2022-01-22 17:36:19 +01:00
florian
115f83794b * avoid warning/error on uninitialized variable 2022-01-22 14:13:59 +01:00
florian
a7a689ca16 * fpc_AnsiStr_To_ShortStr: set length before moving, should result in better memory access pattern 2022-01-20 22:14:33 +01:00
florian
02abad58d8 * some fixes for 8 Bit CPUs 2022-01-19 22:03:09 +01:00
florian
07cd469ade Merge branch 'main' into val_range_check
# Conflicts:
#	rtl/inc/sstrings.inc
2022-01-19 21:30:58 +01:00
florian
718709c87d * all val helpers now use the ValValueArray 2022-01-17 22:46:19 +01:00
florian
2f8750924f * patch by Bart B: fixes fpc_val_word_shortstr() and refactors fpc_val_longword_shortstr() so that it uses the same algorithm and naming conventions as the other unsigned val-helpers. 2022-01-16 23:08:37 +01:00
florian
5f089afdfb * unified ValueArray 2022-01-15 22:36:57 +01:00
florian
55f0103248 o patch by Bart B:
* fixes fpc_Val_UInt_Shortstr, part of #15633
    * fpc_val_qword_shortstr uses the ValueArray constant
2022-01-15 22:18:38 +01:00
florian
9a90db79c3 * patch by Bart B to fix fpc_val_smallint_shortstr similiar to #39406, resolves #39528 2022-01-13 22:51:10 +01:00
florian
8e4e229a5f + DestSize parameter for fpc_Val_UInt functions 2022-01-11 22:10:26 +01:00
florian
fc3b635013 * patch by Bart B to fix the value of Code for unsigned types if the input is negative, resolves #39523 2022-01-11 21:29:56 +01:00
florian
f39a6a7755 * fpc_Val_SInt_ShortStr: bug fixes and improvements by Bart B 2022-01-08 14:45:12 +01:00
florian
38c06e64c7 * optimze case
* few formatting changes
2022-01-07 23:43:59 +01:00
florian
05072d0d82 * updated version by Bart B 2022-01-07 23:21:12 +01:00
florian
4c296af05e * reordered condition so they can be evaluated quicker 2022-01-07 19:36:34 +01:00
florian
d29a482cd1 * fixes for fpc_Val_SInt_ShortStr by Bart B
+ new test for fpc_Val_SInt_ShortStr
  + benchmark
2022-01-07 19:19:55 +01:00
florian
2a93e65511 * seperator => separator 2022-01-02 13:12:33 +01:00
Karoly Balogh
c298c0e0da rtl/osheap: fixed a dumb reversed condition in osheap/SysAllocMem() 2021-12-26 15:56:34 +01:00
florian
781b2d0a80 * patch by Rika: second part of #39496, resolves #30496
+ extended test
2021-12-25 20:01:32 +01:00
florian
c0979bbc0c * TObject.InitInstance got very big so inlining has no advantage anymore, resolves #39494 2021-12-25 19:09:22 +01:00
marcoonthegit
4568c77f57 * implemented stringofchar unicodestring, bug #39483 2021-12-14 15:07:43 +01:00
Jonas Maebe
4426d0da7a Fixed variant discriminator types 2021-10-31 21:13:35 +01:00
florian
ee10850a57 * patch by Sergey Larin: Reducing and aligning the size of TAnsiRec, TUnicodeRec for CPU64, resolves #38018:
For CPU64, the size of record TAnsiRec and TUnicodeRec is 16 bytes instead of 24.
    Which is very good also because of the alignment. when allocating memory, the address
    of the first character of the string will be aligned on the 16-byte boundary.
    At the same time, the useless Dummy field, which is needed in CPU64 for exactly alignment, has been removed.
    For CPU32 (and CPU16), the record size has not changed, so procedures such as
    fpc_AnsiStr_Decr_Ref, implemented in assembler (see i386, arm), remained working correctly.
  * tests adapted
2021-10-17 11:13:29 +02:00
Nikolay Nikolov
f20de5d583 * fixed padding in the filerec to match textrec even on platforms where
sizeof(pointer)<>sizeof(codepointer), like in the medium and compact i8086
  memory models
2021-10-13 02:02:50 +03:00
florian
91cf1774dd * replace MT random generator by Xoshiro128**, resolves #38237 2021-10-05 22:20:22 +02:00
Nikolay Nikolov
7afb665c92 + insert exception flag check and branch after each function call, when
compiling in WebAssembly branchful exceptions mode
2021-10-05 02:26:13 +03:00
Nikolay Nikolov
5124ab2521 * cloned the WebAssembly native exceptions code generation and rtl support into
the branchful exceptions (which will be modified later, but we're using this
  as their starting point, because we can get a snapshot built, without compiler
  internal errors)
2021-10-05 00:37:20 +03:00
Nikolay Nikolov
0c3e179652 - get rid of fpc_PushExceptAddr and fpc_PopAddrStack entirely, when compiling in
wasm native exceptions mode - these helper routines aren't necessary in this
  mode
2021-09-28 03:59:38 +03:00
Nikolay Nikolov
91f0f1a86c * don't include except.inc if wasm32 native exception is turned on, instead
replace it with except_native.inc
2021-09-28 03:46:30 +03:00
florian
a5f6505edc * fix range checking for zero based strings, resolves #39323 2021-09-05 21:03:31 +02:00
florian
396a030fc2 + debugging statement 2021-09-04 19:12:04 +02:00
michael
e6a593c5fa * Patch from Zeljko Avramovic to extend ordinal/float helpers
git-svn-id: trunk@49622 -
2021-07-21 11:36:05 +00:00
michael
1e6952264b * BitSizeOf Documentation sub (issue #39110)
git-svn-id: trunk@49571 -
2021-06-30 10:10:38 +00:00
svenbarth
cb953f68c2 * as 3.2.0 is now the oldest compiler we support we can now use {$push} {$pop} to reset the $minenumsize in the RTTI header
git-svn-id: trunk@49403 -
2021-05-27 05:43:01 +00:00
florian
1e1848da92 * fix exception generation in ln(...), resolves #38832
git-svn-id: trunk@49328 -
2021-05-02 19:45:09 +00:00
Tomas Hajny
9f6651fdb7 + added Get/SetTextAutoFlush feature
git-svn-id: trunk@49324 -
2021-05-02 14:59:21 +00:00
florian
5442e9f9d8 * insert explicit type cast for the count parameter of move/fillchar wrapping C functions,
avoids a warning in combination with -O3 and negative count values

git-svn-id: trunk@49205 -
2021-04-14 19:02:54 +00:00
Károly Balogh
7b9ed5fe46 rtl: make STACK_MARGIN a variable instead of a const. this allows adjusting margin size on system unit init, based on the actual stack length of the executable. useful for small systems running with little stack. allow overwriting SysBackTraceStr with a platform-specific implementation
git-svn-id: trunk@49200 -
2021-04-14 02:35:01 +00:00
pierre
86c036d9ed Explicitly disable range and overflow checking to avoid troubles with pointer arithmetics
git-svn-id: trunk@49198 -
2021-04-13 20:57:18 +00:00
Károly Balogh
caa2735203 osheap: new very small heap manager which only acts as a thin layer above an OS provided heap API. mainly aimed for small and embedded systems
git-svn-id: trunk@49145 -
2021-04-09 02:20:22 +00:00
Jonas Maebe
f13b47289e * handle case where the first instruction with line information is looked up
o this should be handled better. The common way is looking up address - 1,
     but that doesn't seem to work here.

git-svn-id: trunk@49142 -
2021-04-08 19:50:40 +00:00
Jonas Maebe
0eb9dd3879 * Darwin support for printing line info for backtraces when using Dwarf,
based on patches by Colin Western, mantis #38483)
   o requires that the program/library is compiled with -Xg (or that
     dsymutil is run on it after compiling), and that the .dSYM bundle
     is in the same directory as the program/library
   o always use the "dl" unit in exeinfo for Darwin, as that's needed for
     dynamic library support, and this does not cause an extra dependency
     since on Darwin we always use libc
   o cleaned up the exeinfo unit for Darwin, and sped it up by using mmap
     instead of small reads
   o fixed unit dependencies for exeinfo, lineinfo and lnfodwarf in Darwin
     RTL Makefile
  * use the process address info from the original exe even when reading
    the debug information from an external file
  - removed outdated ifdef'd darwin code from dl.pp (no longer needed now
    that processaddress gets set correctly in exeinfo for that platform)

git-svn-id: trunk@49140 -
2021-04-08 19:50:34 +00:00