- i386-specific fpc_shortstr_append_shortstr removed too, because a) it was anyway disabled with STR_CONCAT_PROCS, b) the generic implementation is smaller and probably faster due to optimized Move().
git-svn-id: trunk@19867 -
* fpc_help_constructor: call platform-optimized version of FillChar directly instead of going through generic overloaded version.
* don't compile software multiplication routines if not necessary (the interface part already has similar $ifdef around)
* fpc_shortstr_append_shortstr: use sizeint instead of integer (the latter is 16-bit, produces less efficient code on most platforms)
git-svn-id: trunk@19727 -
to generic.inc
* converted fpc_shortstr_concat(_multi) to use those routines so can also be
activated for the JVM port
git-svn-id: branches/jvmbackend@18907 -
in the system unit for easier debugging)
* disabled a bunch more feature flags by default for the JVM target
* incorporate modified version of inc/systemh.inc (split into two parts:
jsystemh_types.inc and jsystemh.inc, because some of the types are
required for the declaration of the shortstring/ansistring/set/...
classes, which in turn are required for the routine declarations) and
inc/system.inc (as jsystem.inc)
o moved some routines around from old to new locations based on where
they appear in the common files
o added a number of defines that allow skipping more common implementations
in case a platform-specific one is already available
* all base classes (AnsistringClass etc) are now descendants of
JLObject rather than TObject, because their declaration is now parsed
before TObject is known (and there's no need for them to inherit from
TObject)
* incorporate modified version of inc/system.inc
* use the common version of generic.inc, currh.inc, gencurr.inc and
genmath.inc (with small modification to those files)
+ addition of quite a bit of system unit functionality (halt, runerror,
random, round, str() for integer types, abs, odd, endian swapping helpers,
bit scanning, trigonometric functions, ln, exp, ...)
o round()/trunc() for comp-types has been renamed trunc_comp() on the
JVM target because their JVM signature conflicts with trunc(currency)
o the unsigned versions of swapendian() and other endian helpers are not
available on the JVM target because of JVM signature conflicts
git-svn-id: branches/jvmbackend@18746 -
already smaller than the length of the first string (probably cannot
happen currently, but may be in the future as a result of optimizations)
git-svn-id: trunk@17886 -
(and the same for ror), because their operation is very dependent on the
operand size, and it's fairly easy to misjudge the bitwidth of the outcome
of an expression in Pascal if you are not intimately familiar with the
language (or if you don't know the exact types of all involved values in
an expression)
git-svn-id: trunk@12621 -
multi-platform version of patch in r12461, which caused the i386 version
of fpc_pchar_length to return 0 in all cases, which used tabs, and did
not include a test case)
git-svn-id: trunk@12464 -
* based swap(smallint) and swap(word) on swapendian(smallint/word),
since the same bug was already fixed in swap(smallint) in r6752
(so these routines now share the same code)
* fixed potential range error in swapendian(word)
+ added basic test for the above four routines
git-svn-id: trunk@10840 -
because on win64 the location of a function result can depend on its
size (so some chararrays had to be returned in registers and others
by reference, which means it's impossible to have a generic function
declaration which works in all cases) (mantis #8533)
* pad constant string assignments to chararrays with #0 up to the
length of the chararray for 2.0.x compatibility (fixes
tests/test/tarray3)
git-svn-id: trunk@6915 -
array[0..1023] into array[0..0], because they're used as
dummy return types for the Xstring_to_chararray helpers,
and if a smaller array is actually passed as result then
having a larger array declared will cause -gt to
overwrite other data
git-svn-id: trunk@6855 -
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 -
and 4080. The compatibility differences are:
a) writing a chararray which is zero-based but not zero-
terminated does not cause a buffer overflow
b) non-zero-based chararrays can also be read
The difference was that previously, all chararrays were treated
as pchars. In TP/Delphi (and now also in FPC), this is only done
for zero-based chararrays. For non-zero-based ones, the entire
contents of the array should always be used (including #0's).
The default parameters in the system unit for the chararray
helpers are to avoid having to use a define for bootstrapping.
git-svn-id: trunk@2152 -
and also have full double support (exp() only has support for values in
the single range in genmath, for example). Used in FPC_USE_LIBC is
defined
* several fixes to allow compilation with -dHASINLINE, but internalerrors
because of missing support for inlining assembler code