Commit Graph

41388 Commits

Author SHA1 Message Date
paul
115ddf4364 compiler: modernize exception class parse:
- use specially implemented type search routine in case of declaration with colon (on E: Exception do)
  - parse nested types in case of declaration without colon (on Exception do)
  + test

fixes issue #0022225

git-svn-id: trunk@25412 -
2013-09-04 14:09:09 +00:00
lacak
f24d30105e fcl-db: base: improve Blob handling. When writting empty blob set null on. raise data event FieldChange after data are written, not before.
git-svn-id: trunk@25411 -
2013-09-04 13:13:50 +00:00
svenbarth
d03507671d Fix for Mantis #24953.
pgenutil.pas, parse_generic_parameters:
  * set the typesym of the newly created def so that inline specializations in pexpr.pas, sub_expr can check it correctly

git-svn-id: trunk@25410 -
2013-09-04 12:56:08 +00:00
lacak
f11b8b5da4 fcl-db: base: fix streaming of NULL values in XMLDatapacketReader (like in Delphi null values are skiped and are not saved into <ROW ... />)
git-svn-id: trunk@25409 -
2013-09-04 07:43:32 +00:00
florian
333e84202f * fixed a_load_reg_reg for thumb
git-svn-id: trunk@25408 -
2013-09-03 21:11:02 +00:00
florian
7ef37b5d2a * PLD is not supported by thumb
git-svn-id: trunk@25407 -
2013-09-03 21:09:41 +00:00
florian
cb1f38b0af * strd/ldrd are not supported by thumb
git-svn-id: trunk@25406 -
2013-09-03 21:09:13 +00:00
florian
0e7a7c68b0 * the -CI switch is now handled correctly
git-svn-id: trunk@25405 -
2013-09-03 19:24:01 +00:00
michael
bda396906d * Forgot to commit
git-svn-id: trunk@25404 -
2013-09-03 12:51:39 +00:00
michael
3c7881ef04 * Fixed AV when setting capacity to something smaller than count but larger than 0 (bug ID 24943)
git-svn-id: trunk@25403 -
2013-09-03 07:10:53 +00:00
Jeppe Johansen
9acfd929f5 Added ARMv6M to cpu types where the default instruction set is Thumb
git-svn-id: trunk@25402 -
2013-09-03 06:57:24 +00:00
Jonas Maebe
1a78ec1f11 * workaround for bug in Apple's assembler regarding movq/vmovq and integer
registers

git-svn-id: trunk@25396 -
2013-09-02 14:39:26 +00:00
florian
0b30b0913d * fix building of go32v2 rtl with make 3.82
git-svn-id: trunk@25394 -
2013-09-01 20:29:02 +00:00
svenbarth
7babce23da Fix compilation of arm-wince on Linux(?).
rtl/arm/arm.inc & setjump.inc:
  * don't use BX if the current CPU (default for arm-wince is ARMv3)  does not support it

git-svn-id: trunk@25393 -
2013-09-01 14:05:48 +00:00
svenbarth
b288179d56 Fix for Mantis #24929.
rtl/sysutils/datih.inc:
  + add StrToDate overload which allows passing of specific TFormatSettings parameter
rtl/sysutils/dati.inc:
  * implement new StrToDate overload by calling IntStrToDate similar to StrToTime

git-svn-id: trunk@25392 -
2013-09-01 12:46:54 +00:00
Tomas Hajny
38ae8c7250 * changed from import by name (not working correctly) to import by index (as used everywhere else in OS/2 RTL)
git-svn-id: trunk@25391 -
2013-09-01 10:10:59 +00:00
sergei
e41149a7ec * x86_64: reworked register saving/restoring to use PUSH/POP instructions for procedures with RSP-based frame and SEH finalization procedures. XMM registers are also saved/restored without involving tempgen in mentioned cases. This prevents SEH finalization procedures from saving registers in stack frame of their parent procedures, fixing incorrect unwind bytecode (Mantis #24791). It also reduces executable size (for compiler itself, by about 100Kb).
git-svn-id: trunk@25389 -
2013-08-30 07:54:02 +00:00
Jonas Maebe
fcaad5baf2 * perform -CTlowercaseprocstart conversion it tprocsym.create rather than
when building the mangled name, because the latter can also be performed
    when compiler another unit (and therefore if that other unit's setting
    is different from that of the original unit, a wrong mangled name was
    generated) + test for this case

git-svn-id: trunk@25388 -
2013-08-29 22:43:06 +00:00
Jonas Maebe
a14ceba791 + -CTinitlocals switch for the JVM that initialises all local variables
that may trigger JVM bytecode verification errors if they are used
    before they are initialised (this includes passing them as a "var"
    parameter) + test
  * sorted -CT parameters alphabetically and alligned them

git-svn-id: trunk@25387 -
2013-08-29 22:21:23 +00:00
Jonas Maebe
10bb07a665 * brackets around and/or combination
git-svn-id: trunk@25386 -
2013-08-29 22:21:19 +00:00
Jonas Maebe
6013606a97 + -CTlowercaseprocstart switch to lowercase the first character of routines
so that code written according to Delphi coding standards can be compiled
    into JVM bytecode with routine names conforming to JVM coding standards

git-svn-id: trunk@25385 -
2013-08-29 22:21:15 +00:00
sergei
690995fa12 * RTL: fixed some warnings when compiling for x86_64:
* x86_64/x86_64.inc: IsMultithread is a LongBool, not Boolean -> fixed assembler instruction suffixes
  * inc/generic.inc: cast Sizeof() to unsigned, so that combining it with unsigned operands does not cause promotion to larger signed type.
  + win64/seh64.inc: explicit typecast and missing function result assignment.
  + inc/genmath.inc: explicit typecasts.

git-svn-id: trunk@25384 -
2013-08-29 07:52:38 +00:00
Károly Balogh
86cb4d0c12 use a TSuperRegister instead of an aint
git-svn-id: trunk@25383 -
2013-08-28 12:58:29 +00:00
Károly Balogh
c677f1fd69 trying harder to follow the code style (no functional changes)
git-svn-id: trunk@25382 -
2013-08-28 11:25:15 +00:00
sergei
5dda96bdfe - Tcgx86_64.init_register_allocators: removed 'preserved_by_proc' parameter, because it isn't used by RA in any way.
* tcgx86_64.g_intf_wrapper: jump directly to reference without loading its content into RAX, this saves an instruction.

git-svn-id: trunk@25381 -
2013-08-28 09:10:57 +00:00
Károly Balogh
25619d4991 removed the const-in-the-left internalerror
git-svn-id: trunk@25380 -
2013-08-27 16:18:53 +00:00
Károly Balogh
cb4d01627f save an extra reg if it's required to keep 64bit stack alignment on ARM
git-svn-id: trunk@25379 -
2013-08-27 12:49:50 +00:00
michael
901f5742b8 * Remove redundant if
git-svn-id: trunk@25378 -
2013-08-27 10:02:03 +00:00
lacak
c42890ed75 fcl-db: tests: test that RowsAffected is specific per query not per connection (if more queries are executed over same connection)
git-svn-id: trunk@25377 -
2013-08-27 09:54:01 +00:00
lacak
4817a0e670 fcl-db: tests: it seems, that Sybase ASE does not have NTEXT data type; so comment it for now; update for rev.25372
git-svn-id: trunk@25376 -
2013-08-27 05:57:17 +00:00
florian
f58d1461c3 * fixed help page for -C3 as mentioned by Dmitry Boyarintsev on the mailing list
git-svn-id: trunk@25375 -
2013-08-26 20:48:49 +00:00
masta
ff95d42216 Fix ShiftShift2Shift 1 ARM-peephole optimizer
The previous code deleted the newly inserted instruction instead of the
existing one, which obviously broke code.

Assembly:
  mov r0, r0, lsr #23
  mov r0, r0, lsr #23

transformed into:
  mov r0, r0, lsr #23

expected was:
  mov r0, #0

The problem only shows up in the very unlikely case of two LSR/ASR or
two LSL following on each other and having a total shift of more than 31
bits.

This fixes test/opt/tarmshift.pp

I've also removed the {%norun} directive from tarmshift.pp as this test
does only make sense when it also runs.

git-svn-id: trunk@25374 -
2013-08-26 17:41:54 +00:00
lacak
0fafe77d27 fcl-db: base: add support for ftGuid field type in XMLDatapacketReader (type='string', subtype='Guid' like in Delphi)
git-svn-id: trunk@25373 -
2013-08-26 12:46:25 +00:00
lacak
279587a278 fcl-db: tests: add more field types to FieldDataSet
git-svn-id: trunk@25372 -
2013-08-26 12:42:53 +00:00
sergei
db045c4871 * Define FPC_ABSMASK_SINGLE and FPC_ABSMASK_DOUBLE without using assembler.
git-svn-id: trunk@25371 -
2013-08-26 07:32:41 +00:00
florian
d4968e054b + arm: tsettings.instructionset
* the selected instruction set is now independent from the cpu type: e.g. armv7-a can perfectly execute thumb(2) code

git-svn-id: trunk@25370 -
2013-08-25 21:56:12 +00:00
florian
6e7edf1933 * make x86memorymodel i8086 only
git-svn-id: trunk@25369 -
2013-08-25 21:56:08 +00:00
nickysn
bf3e48d8e0 * compilation of ppudump fixed
git-svn-id: trunk@25368 -
2013-08-25 17:11:57 +00:00
nickysn
63a42b9da6 * incremented the ppu version as well after r25365
git-svn-id: trunk@25367 -
2013-08-25 16:52:37 +00:00
nickysn
571e9c2e3e + added the new i8086 memory model flags to ppudump as well
git-svn-id: trunk@25366 -
2013-08-25 16:48:13 +00:00
nickysn
243e3bbb77 + added i8086 memory model flags to the ppu flags and added a check that prevents the using of units compiled for different memory models
git-svn-id: trunk@25365 -
2013-08-25 16:45:04 +00:00
nickysn
b327eac688 - disable cs_opt_regvar from -O2 on i8086, since it's not working properly yet
git-svn-id: trunk@25364 -
2013-08-24 23:06:10 +00:00
joost
fa0c4da914 * Also read stderr while executing the compiler. This way
linker (ld) errors are also shown

git-svn-id: trunk@25363 -
2013-08-24 12:40:50 +00:00
reiniero
9c526ff99a Fcl-db: cosmetic.
git-svn-id: trunk@25359 -
2013-08-24 09:07:40 +00:00
nickysn
f9d0caa7c7 * pass the option -w-orphan-labels to nasm to avoid the spurious warnings about labels without a trailing colon and without an instruction on the same line
git-svn-id: trunk@25358 -
2013-08-23 23:40:24 +00:00
nickysn
e342c11085 + introduced a private type TCodePtrList, which is the specialization
TFPGList<CodePointer> on archs/memory models where CodePointer is different
  than Pointer. On archs/memory models where CodePointer = Pointer, TCodePtrList
  is simply an alias of TList and the fgl unit isn't pulled in.
* the type of FindGlobalComponentList changed to TCodePtrList and the typecasts
  from TFindGlobalComponent (procvar type) to Pointer changed to CodePointer.
  This fixes compilation of unit classes in the i8086 medium memory model.

git-svn-id: trunk@25357 -
2013-08-23 19:25:51 +00:00
florian
7cef301e84 * disable optimization LdrbAnd2Ldrb for arm thumb as it is currently done
git-svn-id: trunk@25356 -
2013-08-23 18:41:26 +00:00
florian
f34bee1df7 * arm thumb does not support ror reg1,reg2,#imm
git-svn-id: trunk@25355 -
2013-08-23 18:41:24 +00:00
florian
950194678a * handle jump tables correctly when inserting constant pools on arm thumb
git-svn-id: trunk@25354 -
2013-08-23 18:41:21 +00:00
nickysn
4f0c160110 * Makefile regenerated with latest fpcmake from trunk, which has i8086-msdos support
git-svn-id: trunk@25353 -
2013-08-23 16:51:31 +00:00