florian
880201e56c
+ pointerconstn is also a constant node
...
git-svn-id: trunk@26305 -
2013-12-28 20:20:00 +00:00
florian
4258fe6765
* adapt exponent used in test to supported float type
...
git-svn-id: trunk@26304 -
2013-12-28 20:19:58 +00:00
florian
de3a116a28
* handle records with size 0 as function results correctly
...
git-svn-id: trunk@26303 -
2013-12-28 20:19:56 +00:00
florian
561ec1f782
* unified internal errors
...
git-svn-id: trunk@26302 -
2013-12-28 20:19:54 +00:00
florian
2081b9cad7
* do not convert a boolean to a 32 bit int first when converting to a 64 bit int, this causes data loss when casting e.g. a qwordbool to a qword
...
git-svn-id: trunk@26301 -
2013-12-28 20:19:51 +00:00
florian
b47f1c4176
* disable constant propagation for tests which will cause a regression because const. prop. causes a compile time error while the tests expect a runtime error
...
git-svn-id: trunk@26300 -
2013-12-28 20:19:49 +00:00
florian
be807d6cef
+ tests for dead store removal
...
git-svn-id: trunk@26299 -
2013-12-28 20:19:46 +00:00
florian
27ac68cdc7
* be more careful when removing dead stores
...
* take care also of staticvarsyms when removing dead stores
git-svn-id: trunk@26298 -
2013-12-28 20:19:42 +00:00
florian
e9777503d1
* check addr_taken when propagating constants
...
* do constant propagation on static var syms as well
git-svn-id: trunk@26297 -
2013-12-28 20:19:40 +00:00
florian
b1ee6f282c
* set successor node for load nodes as well, they can be generated when inlining
...
git-svn-id: trunk@26296 -
2013-12-28 20:19:38 +00:00
florian
89663e499b
* fold shifting of constants equally to cpus
...
* test adapted, e.g. 1 shl 63 needs now an explicit cast to qword for the one: qword(1) shl 63
git-svn-id: trunk@26295 -
2013-12-28 20:19:35 +00:00
sergei
d70a880f33
* SPARC: properly justify parameters on stack with size less than 4, fixes failure on tests/cg/tcalext5.pp
...
git-svn-id: trunk@26294 -
2013-12-28 09:23:10 +00:00
sergei
176d8434e4
* SPARC: completely rewrote PIC-related code, got it twice shorter in source lines and much less instructions in generated code.
...
+ Enable registers %i0..%i5 and %o7 for use by reg.allocator.
Some notable properties of this implementation are:
o pi_needs_got flag can be safely set during pass 2, so not setting it occasionally in pass 1 does not result in internal error.
o Reg.allocator configuration is independent from PIC. If procedure requires GOT, register %l7 is allocated at the prologue, making it unavailable to RA.
o GOT is stored in fixed %l7 register, but it is trivial to switch over to virtual register.
git-svn-id: trunk@26293 -
2013-12-27 19:53:38 +00:00
sergei
1a3b46967e
+ Two more checks for access to global data and setting the pi_needs_got flag, intended for targets that require decision about PIC code generation strictly before pass 2.
...
git-svn-id: trunk@26292 -
2013-12-27 13:41:36 +00:00
reiniero
076ff1f47a
* fcl-db: dbase: follow upstream commit r319:
...
When filtering, the RecNo was wrong
Corrects RecNo when filtering
git-svn-id: trunk@26291 -
2013-12-27 13:12:07 +00:00
sergei
eaba90dda7
* SPARC: since peephole optimizer recognizes only one conditional branching instruction, generate all branches using A_Bxx opcode, and change it to A_FBxx if necessary when writing assembler. This enables optimization of floating-point branches.
...
* Assembler reader: rewrote branch condition matching part, don't try to match integer suffixes to floating-point branches and vice versa.
git-svn-id: trunk@26290 -
2013-12-27 06:45:49 +00:00
marco
59aa032986
* Mantis #25276 , improvements for CHMCMD anchor handling, specially combined
...
with errorhandling.
git-svn-id: trunk@26289 -
2013-12-26 18:36:55 +00:00
marco
b2a4b4cfda
* mantis #25278 ascii table and #25239 (redundant help buttons) parts.
...
git-svn-id: trunk@26288 -
2013-12-26 17:14:50 +00:00
sergei
62a5ba14a3
+ SPARC: support finalization routine supplied by dynamic linker.
...
+ Added "stack not executable" marker.
git-svn-id: trunk@26287 -
2013-12-26 09:09:23 +00:00
sergei
890d757573
+ SPARC: override g_external_wrapper method and emit PIC-safe jump without distance limit. Mantis #25455 .
...
git-svn-id: trunk@26286 -
2013-12-26 07:37:22 +00:00
marco
104cbc0160
* redundant buttons removed, mantis #25239
...
git-svn-id: trunk@26285 -
2013-12-25 21:10:11 +00:00
marco
504ede1834
* add copyright from original header kindly submitted
...
by translator Valdinilson Lourenco da Cunha. Mantis #23323
The copyright part of the header seemed to be mostly a general Cairo
header.
git-svn-id: trunk@26284 -
2013-12-25 16:47:19 +00:00
nickysn
fdd36b4603
* on i8086 with regvars on, do not notify the register allocator of moves to BX.
...
This fixes compilation of unit math (and the whole RTL) with regvars enabled.
git-svn-id: trunk@26282 -
2013-12-25 12:19:21 +00:00
sergei
e6a9bfdc1d
* SPARC, g_concatcopy and g_concatcopy_unaligned: removed strange (probably long outdated) comments and unnecessary operations.
...
* g_concatcopy: avoid taking address of references if possible.
git-svn-id: trunk@26281 -
2013-12-25 10:45:25 +00:00
sergei
c3c682fe3f
* Changed test so it provides different exit codes depending on the failed assertion.
...
git-svn-id: trunk@26280 -
2013-12-25 10:33:16 +00:00
sergei
03fb83cc01
* SPARC: fixed PIC interface wrappers for non-virtual methods. The fix uses branching with 8 MB distance limit, but in particular case of interface wrappers this limit applies to code size of a single unit, not to entire program, and is therefore hard enough to reach.
...
git-svn-id: trunk@26279 -
2013-12-25 08:13:10 +00:00
nickysn
420f30bacd
* fixed the handling of OS_PAIR/OS_SPAIR-sized parameters in ncgutil.gen_load_cgpara_loc. This fixes 32-bit regvar'd parameters on i8086.
...
git-svn-id: trunk@26278 -
2013-12-24 23:07:44 +00:00
yury
eea69a2947
* ppudump: Fixed json and xml output of inline types in array declaration.
...
git-svn-id: trunk@26277 -
2013-12-24 12:32:55 +00:00
nickysn
af49e50a3c
* do not cause an internal error when location_reg2string is called on a
...
location where the registers have been translated (i.e. not imaginary), but
GetNextReg is necessary to get some of the registers (only on 16/8-bit CPUs).
The missing registers are indicated as '??'. This avoids a crash when
compiling a system unit on i8086 with regvars enabled and withous -sr, while
still giving the full list of registers when compiling with -sr.
git-svn-id: trunk@26276 -
2013-12-24 00:01:28 +00:00
nickysn
338d72f564
* extracted the code from psub.translate_registers for generating the name of
...
the registers from a tlocation to a new function called location_reg2string
+ added support for 16-bit and 8-bit ALUs in location_reg2string
git-svn-id: trunk@26275 -
2013-12-23 22:58:32 +00:00
yury
996ee048be
* ppudump: Properly handle type definitions inside a class definition for json and xml output.
...
git-svn-id: trunk@26273 -
2013-12-23 14:45:03 +00:00
nickysn
99770d367f
* 16-bit and 8-bit ALU fixes in tcgtempdeletenode.pass_generate_code
...
git-svn-id: trunk@26272 -
2013-12-23 14:09:28 +00:00
nickysn
39c54bf077
* handle ait_varloc in the nasm writer. This allows compiling the system unit
...
for i8086 with regvars and -sr for debugging purposes.
git-svn-id: trunk@26271 -
2013-12-23 13:27:22 +00:00
yury
bc14407ffe
* ppudump: Deref index -1 is valid for absolute symbols. Handle this.
...
git-svn-id: trunk@26270 -
2013-12-23 12:26:28 +00:00
yury
90b8e051cb
* Fixed crash during dll loading on android-i386 (Stupid error because I am not comfortable with at&t i386 assembler syntax). Issue #25435 .
...
git-svn-id: trunk@26269 -
2013-12-23 12:02:50 +00:00
nickysn
4eb9043ac7
* x87 optimized version of math.log2() for i8086, i386 and x86_64
...
git-svn-id: trunk@26266 -
2013-12-22 23:21:41 +00:00
nickysn
90b69184f1
* use a {$if defined()} sequence, instead of nested ifdefs for selecting the
...
float type in unit math
git-svn-id: trunk@26265 -
2013-12-22 19:18:15 +00:00
sergei
65d24e000f
* SPARC: generate PIC prologue as recommended by ABI, it does not require FPC_GETGOT helper.
...
git-svn-id: trunk@26264 -
2013-12-22 14:20:18 +00:00
sergei
6469d41e2a
* SPARC: removed 32 bit shift code, and adjusted 64-bit shifts to take advantage of 3-address instructions (a port of r26142 for MIPS)
...
git-svn-id: trunk@26263 -
2013-12-22 14:09:24 +00:00
sergei
58cc531dd9
* SPARC: convert from int64/qword to float using genmath helpers. Removes dependency on softfloat code.
...
git-svn-id: trunk@26262 -
2013-12-22 14:02:34 +00:00
sergei
5ccdfcf106
* SPARC: optimized a_op_const_reg and a_op_const_reg_reg, take advantage of optimize_op_const functionality.
...
git-svn-id: trunk@26261 -
2013-12-22 13:54:49 +00:00
sergei
16156cbcd7
- SPARC RTL: removed assembler PIC/threadvar hacks.
...
git-svn-id: trunk@26260 -
2013-12-22 13:42:53 +00:00
sergei
9a486d73ba
+ SPARC: support FNEGd/FNEGq internal instructions, and use them to implement floating-point negation more efficiently.
...
git-svn-id: trunk@26259 -
2013-12-21 16:27:24 +00:00
sergei
8ecad469a6
* Reverted r26256 since it produced wrong results if argument of inc/dec is actually unaligned. Added description of the issue and slightly increased node complexity at which address is cached, so operations on record/class fields do not take address.
...
git-svn-id: trunk@26258 -
2013-12-21 10:33:38 +00:00
sergei
c3fe0c7379
* On SPARC, using shifts for zero-extending to OS_16 is more efficient than ANDing with 65535 (two instructions and no temp registers vs. three instructions and a temp register).
...
git-svn-id: trunk@26257 -
2013-12-20 19:00:44 +00:00
sergei
b376f56bf3
* Use typed pointer to store address of x when processing inc(x)/dec(x) with range checking enabled. This preserves alignment of x and prevents generating unaligned code on alignment-sensitive targets.
...
git-svn-id: trunk@26256 -
2013-12-20 17:13:41 +00:00
sergei
5cd0684d45
* tcg.a_load_ref_reg_unaligned: if loading signed 16-bit value, treat upper half as signed 8-bit to ensure that result is properly extended. This routine is used only by SPARC target (other CPUs use specific implementations), and it generates pretty inefficient code, therefore it's probably worth to drop it altogether and implement SPARC-specific version. Mantis #25440 .
...
git-svn-id: trunk@26255 -
2013-12-20 17:07:00 +00:00
reiniero
48e4fc4bb2
* fcl-db: dbf,bufdataset (and descendents): allow filter using double delimiters inside string. Fixes issue #25432
...
allow escaping delimiters by doubling them e.g.
Filter:='(NAME=''O''''Malley''''s "Magic" Hammer'')';
which gives
(NAME='O''Malley''s "Magic" Hammer')
which will match record
O'Malley's "Magic" Hammer
git-svn-id: trunk@26253 -
2013-12-19 16:42:57 +00:00
reiniero
4229c6b40f
* fcl-db: additional stringfilter tests
...
git-svn-id: trunk@26252 -
2013-12-19 16:40:08 +00:00
sergei
f2096de53a
* tcg386.g_proc_exit: instead of recalculating stack size, use current_procinfo.final_localsize which was calculated in g_proc_entry.
...
* tcgx86.g_proc_entry: don't over-allocate stack in SEH finalizer procedures.
git-svn-id: trunk@26251 -
2013-12-19 10:32:32 +00:00