libfirm
14 years agofix
Matthias Braun [Wed, 10 Feb 2010 10:29:10 +0000 (10:29 +0000)]
fix

[r27106]

14 years agomake statev_sql commandlines similar to mysql commandlines
Matthias Braun [Wed, 10 Feb 2010 10:00:16 +0000 (10:00 +0000)]
make statev_sql commandlines similar to mysql commandlines

[r27103]

14 years agoFix bug when handling pn_Cmp_Lg with vrp info
Jonas Fietz [Wed, 10 Feb 2010 03:33:51 +0000 (03:33 +0000)]
Fix bug when handling pn_Cmp_Lg with vrp info

[r27101]

14 years agoAdd optimizations for Proj after Cond using VRP
Jonas Fietz [Wed, 10 Feb 2010 03:22:52 +0000 (03:22 +0000)]
Add optimizations for Proj after Cond using VRP

This uses the vrp information to evaluate int projs.
This optimizes cases like:
x |= 33;
y = x & 96;
to y = 1;

[r27100]

14 years agoAdd some optimizations for jumpthreading using vrp information
Jonas Fietz [Wed, 10 Feb 2010 02:47:40 +0000 (02:47 +0000)]
Add some optimizations for jumpthreading using vrp information

This uses the vrp information to expand the handling for constants to
handling ranges as well.

[r27098]

14 years agoAdd basic optimizations based on vrp info
Jonas Fietz [Wed, 10 Feb 2010 02:47:39 +0000 (02:47 +0000)]
Add basic optimizations based on vrp info

This adds some basic optimizations, e.g. to calculate the value for some
nodes if it can be determined.

[r27097]

14 years agoAdd analysis for vrp information
Jonas Fietz [Wed, 10 Feb 2010 02:47:38 +0000 (02:47 +0000)]
Add analysis for vrp information

This commit adds the basic analysis needed to derive vrp information. It
should not run infinetely, but there may be border cases.
There might be error conditions for which there are no checks yet.
Also, a lot of the derivations can still be improved.

[r27096]

14 years agoAdd dumper code for VRP information
Jonas Fietz [Wed, 10 Feb 2010 02:47:38 +0000 (02:47 +0000)]
Add dumper code for VRP information

This commit adds the code and prototypes for dumping vrp information

[r27095]

14 years agoAdd structures and initialization for VRP
Jonas Fietz [Wed, 10 Feb 2010 02:47:36 +0000 (02:47 +0000)]
Add structures and initialization for VRP

This commit adds the neccessary attributes to each ir_node. It also adds
the initialization code and some prototypes for the graph_pass and some
support functions.

[r27094]

14 years agoFixed sizeof(long)-dependent case sorting and signedness of if-cascade comparisons
Olaf Liebe [Tue, 9 Feb 2010 14:02:01 +0000 (14:02 +0000)]
Fixed sizeof(long)-dependent case sorting and signedness of if-cascade comparisons

[r27093]

14 years agoAdded missing do_loop_unrolling
Christian Helmer [Tue, 9 Feb 2010 13:11:35 +0000 (13:11 +0000)]
Added missing do_loop_unrolling

[r27092]

14 years agomake firm compile again
Matthias Braun [Mon, 8 Feb 2010 23:30:09 +0000 (23:30 +0000)]
make firm compile again

[r27091]

14 years agoin case of missing tables create them even in update mode
Matthias Braun [Mon, 8 Feb 2010 23:16:36 +0000 (23:16 +0000)]
in case of missing tables create them even in update mode

[r27090]

14 years agocparser now knows 'unroll-loops'.
Christian Helmer [Mon, 8 Feb 2010 16:32:46 +0000 (16:32 +0000)]
cparser now knows 'unroll-loops'.

[r27088]

14 years agocleanup rework and extend statev_sql.py; it should be faster now and has a new mode...
Matthias Braun [Sun, 7 Feb 2010 23:16:32 +0000 (23:16 +0000)]
cleanup rework and extend statev_sql.py; it should be faster now and has a new mode to append results to an existing DB

[r27086]

14 years agoMux -> Abs works for unordered compare ...
Michael Beck [Sun, 7 Feb 2010 18:09:24 +0000 (18:09 +0000)]
Mux -> Abs works for unordered compare ...

[r27083]

14 years agoReverted r27079. Seems to be wrong.
Michael Beck [Sun, 7 Feb 2010 16:55:18 +0000 (16:55 +0000)]
Reverted r27079. Seems to be wrong.

[r27082]

14 years agoBugFix: ins_permuted means inversed flags, not negated ...
Michael Beck [Sat, 6 Feb 2010 00:31:02 +0000 (00:31 +0000)]
BugFix: ins_permuted means inversed flags, not negated ...

[r27079]

14 years agoFixed setcc transform:
Michael Beck [Sat, 6 Feb 2010 00:09:00 +0000 (00:09 +0000)]
Fixed setcc transform:
- test for t ==1 AFTER f == 0: this fixes fehler035.c
- disable sbb creation: reloader might change the cmp instruction yet

[r27078]

14 years agoconstructors/destructors must not have a name
Matthias Braun [Fri, 5 Feb 2010 22:28:10 +0000 (22:28 +0000)]
constructors/destructors must not have a name

[r27077]

14 years agoDo not emit a label if a entity has no name.
Christoph Mallon [Fri, 5 Feb 2010 22:23:49 +0000 (22:23 +0000)]
Do not emit a label if a entity has no name.

[r27076]

14 years agoSupport dtor sections on Mach-O.
Christoph Mallon [Fri, 5 Feb 2010 22:23:21 +0000 (22:23 +0000)]
Support dtor sections on Mach-O.

[r27075]

14 years agohack for mac
Matthias Braun [Fri, 5 Feb 2010 20:34:41 +0000 (20:34 +0000)]
hack for mac

[r27064]

14 years agomac gas doesn't get .octa
Matthias Braun [Fri, 5 Feb 2010 20:17:30 +0000 (20:17 +0000)]
mac gas doesn't get .octa

[r27063]

14 years agofix all pic bases I could find
Matthias Braun [Fri, 5 Feb 2010 20:03:41 +0000 (20:03 +0000)]
fix all pic bases I could find

[r27062]

14 years agofix another PIC problem
Matthias Braun [Fri, 5 Feb 2010 19:27:50 +0000 (19:27 +0000)]
fix another PIC problem

[r27061]

14 years agotry to fix PIC commons
Matthias Braun [Fri, 5 Feb 2010 19:20:56 +0000 (19:20 +0000)]
try to fix PIC commons

[r27060]

14 years agoEmit the symbol of PIC trampolines.
Christoph Mallon [Fri, 5 Feb 2010 19:11:43 +0000 (19:11 +0000)]
Emit the symbol of PIC trampolines.

[r27058]

14 years agobring back PIC support
Matthias Braun [Fri, 5 Feb 2010 18:53:55 +0000 (18:53 +0000)]
bring back PIC support

[r27057]

14 years agoa new garbage collection pass less conservative than gc_irgs (but does not respect...
Matthias Braun [Fri, 5 Feb 2010 18:30:05 +0000 (18:30 +0000)]
a new garbage collection pass less conservative than gc_irgs (but does not respect properties of object-oriented programs)

[r27056]

14 years agorevivie max_irg_visited
Matthias Braun [Fri, 5 Feb 2010 18:01:00 +0000 (18:01 +0000)]
revivie max_irg_visited

[r27055]

14 years agomake irg_walk_2 public
Matthias Braun [Fri, 5 Feb 2010 18:00:46 +0000 (18:00 +0000)]
make irg_walk_2 public

[r27054]

14 years agoNew setcc framework can handle all mux_is_abs(..., Const, Const) using set and up...
Michael Beck [Fri, 5 Feb 2010 09:29:30 +0000 (09:29 +0000)]
New setcc framework can handle all mux_is_abs(..., Const, Const) using set and up to 3 instructions ...

[r27053]

14 years agoexport ia32_immediate_from_long()
Michael Beck [Fri, 5 Feb 2010 09:28:29 +0000 (09:28 +0000)]
export ia32_immediate_from_long()

[r27052]

14 years agoattempt to fix compound_graph stuff
Matthias Braun [Thu, 4 Feb 2010 22:17:19 +0000 (22:17 +0000)]
attempt to fix compound_graph stuff

[r27048]

14 years agooops
Matthias Braun [Thu, 4 Feb 2010 20:34:43 +0000 (20:34 +0000)]
oops

[r27046]

14 years agouse more IR_RESOURCE_TYPE_VISITED, remove pointless inc_master_type_visited calls
Matthias Braun [Thu, 4 Feb 2010 20:32:44 +0000 (20:32 +0000)]
use more IR_RESOURCE_TYPE_VISITED, remove pointless inc_master_type_visited calls

[r27045]

14 years agointroduce IR_RESOURCE_TYPE_VISITED
Matthias Braun [Thu, 4 Feb 2010 20:27:31 +0000 (20:27 +0000)]
introduce IR_RESOURCE_TYPE_VISITED

[r27044]

14 years agofix buf: we can't handle floating point muxes
Matthias Braun [Thu, 4 Feb 2010 15:37:55 +0000 (15:37 +0000)]
fix buf: we can't handle floating point muxes

[r27042]

14 years ago- representing the 3-state visibility (default,local,external) with 2 bits was
Matthias Braun [Thu, 4 Feb 2010 13:27:45 +0000 (13:27 +0000)]
- representing the 3-state visibility (default,local,external) with 2 bits was
  clumsy. Bring back get_entity_visibility and set_entity_visibility

[r27039]

14 years agoC99 feature removed.
Michael Beck [Wed, 3 Feb 2010 22:21:20 +0000 (22:21 +0000)]
C99 feature removed.

[r27037]

14 years agoAdd get_tarval_lowest_bit() and get_tarval_popcnt(), expand some documentation.
Michael Beck [Wed, 3 Feb 2010 22:15:45 +0000 (22:15 +0000)]
Add get_tarval_lowest_bit() and get_tarval_popcnt(), expand some documentation.

[r27036]

14 years agofurther corrections on 'COMMON' semantic
Matthias Braun [Wed, 3 Feb 2010 20:30:12 +0000 (20:30 +0000)]
further corrections on 'COMMON' semantic

[r27034]

14 years agobackend_marked was a buggy/wrong concept, removed it
Matthias Braun [Wed, 3 Feb 2010 20:25:32 +0000 (20:25 +0000)]
backend_marked was a buggy/wrong concept, removed it

[r27032]

14 years agofix some assertions; correctly handle weak symbols
Matthias Braun [Wed, 3 Feb 2010 20:03:00 +0000 (20:03 +0000)]
fix some assertions; correctly handle weak symbols

[r27031]

14 years agoRework linkage types in firm.
Matthias Braun [Wed, 3 Feb 2010 19:31:48 +0000 (19:31 +0000)]
Rework linkage types in firm.
- Merge stickyness, visibility and variability into ir_linkage
- Add proper support for common symbols, weak symbols and C++ COMDAT stuff
- Mark OO-features type_visibility, peculiarity and allocation as deprecated
  OO feature will be separated from firm core into higher levels in the long run
- Rework, simplify and fix bugs in begnuas.c

[r27030]

14 years agoLoop unrolling implemented. Inversion+unrolling fail 3 tests.
Christian Helmer [Tue, 2 Feb 2010 15:57:31 +0000 (15:57 +0000)]
Loop unrolling implemented. Inversion+unrolling fail 3 tests.

[r27029]

14 years agoFixed broken ia32_emitf (va_arg was not always called for %AR)
Olaf Liebe [Mon, 1 Feb 2010 21:38:06 +0000 (21:38 +0000)]
Fixed broken ia32_emitf (va_arg was not always called for %AR)

[r27026]

14 years agomake the character used for specifying elf types configurable in begnuas and use...
Matthias Braun [Mon, 1 Feb 2010 18:49:57 +0000 (18:49 +0000)]
make the character used for specifying elf types configurable in begnuas and use generic function prolog in arm backend

[r27022]

14 years agofix fehler175.c
Matthias Braun [Mon, 1 Feb 2010 18:13:25 +0000 (18:13 +0000)]
fix fehler175.c

[r27021]

14 years agofix wrong mux_is_set test
Matthias Braun [Mon, 1 Feb 2010 17:58:21 +0000 (17:58 +0000)]
fix wrong mux_is_set test

[r27019]

14 years agofix fehler174
Matthias Braun [Mon, 1 Feb 2010 17:45:45 +0000 (17:45 +0000)]
fix fehler174

[r27018]

14 years ago[r27015]
Hannes Rapp [Mon, 1 Feb 2010 15:45:40 +0000 (15:45 +0000)]
[r27015]

14 years ago- std function-prolog emitter eingebaut
Hannes Rapp [Mon, 1 Feb 2010 15:43:53 +0000 (15:43 +0000)]
- std function-prolog emitter eingebaut

[r27014]

14 years agofix float constants with PIC code
Matthias Braun [Fri, 29 Jan 2010 18:24:15 +0000 (18:24 +0000)]
fix float constants with PIC code

[r27012]

14 years agofix allow_ifconv being called with true/false swapped
Matthias Braun [Fri, 29 Jan 2010 18:04:34 +0000 (18:04 +0000)]
fix allow_ifconv being called with true/false swapped

[r27011]

14 years agoReduce code duplication by jumping to the appropriate case.
Christoph Mallon [Thu, 28 Jan 2010 20:55:16 +0000 (20:55 +0000)]
Reduce code duplication by jumping to the appropriate case.

[r27008]

14 years agoIn mode_b lowering move the assertion for mode_b below the check, whether the node...
Christoph Mallon [Thu, 28 Jan 2010 20:32:02 +0000 (20:32 +0000)]
In mode_b lowering move the assertion for mode_b below the check, whether the node was replaced already. Some nodes are their own replacement and therefore do not have mode_b anymore after lowering.

[r27007]

14 years agoConsistently record the replacement nodes and removal candidates when doing mode_b...
Christoph Mallon [Thu, 28 Jan 2010 20:28:43 +0000 (20:28 +0000)]
Consistently record the replacement nodes and removal candidates when doing mode_b lowering. This was not done in some cases, most importantly the former was not done for certain Projs, which are their own replacement (just their mode gets changed). Also add a FIXME that the algorithm is subtly broken and may replace the same node twice due to recursion over Phis.

[r27006]

14 years agoLeave a bit space between cases.
Christoph Mallon [Thu, 28 Jan 2010 19:14:30 +0000 (19:14 +0000)]
Leave a bit space between cases.

[r27005]

14 years agoUse the locally cached value of config.lowered_mode instead of reading it again.
Christoph Mallon [Thu, 28 Jan 2010 19:13:04 +0000 (19:13 +0000)]
Use the locally cached value of config.lowered_mode instead of reading it again.

[r27004]

14 years agoUse the real firm_clear_link() instead of duplicating it.
Christoph Mallon [Thu, 28 Jan 2010 19:09:16 +0000 (19:09 +0000)]
Use the real firm_clear_link() instead of duplicating it.

[r27003]

14 years agoUse a real Dummy node instead of misusing an Unknown node and shortly deactivating...
Christoph Mallon [Thu, 28 Jan 2010 19:05:13 +0000 (19:05 +0000)]
Use a real Dummy node instead of misusing an Unknown node and shortly deactivating CSE.

[r27002]

14 years agoRemove write-only local variable.
Christoph Mallon [Thu, 28 Jan 2010 18:57:29 +0000 (18:57 +0000)]
Remove write-only local variable.

[r27001]

14 years agoMake the documenation of new_*Alloc() consistent: It's the number of objects, not...
Christoph Mallon [Thu, 28 Jan 2010 18:56:00 +0000 (18:56 +0000)]
Make the documenation of new_*Alloc() consistent: It's the number of objects, not bytes.

[r27000]

14 years agoFixed set_irn_in array allocation obstack
Olaf Liebe [Thu, 28 Jan 2010 12:24:10 +0000 (12:24 +0000)]
Fixed set_irn_in array allocation obstack

[r26997]

14 years agolower_highlevel didn't invalidate outedges, code_placement must assure doms
Olaf Liebe [Thu, 28 Jan 2010 10:15:03 +0000 (10:15 +0000)]
lower_highlevel didn't invalidate outedges, code_placement must assure doms

[r26996]

14 years agoemit unknown values as 0
Olaf Liebe [Thu, 28 Jan 2010 10:13:26 +0000 (10:13 +0000)]
emit unknown values as 0

[r26995]

14 years agolibfirm must be linked to libm
Andreas Zwinkau [Wed, 27 Jan 2010 09:58:21 +0000 (09:58 +0000)]
libfirm must be linked to libm

[r26994]

14 years agoadd a default_layout_compound_type; the backend layouts the frametype now if it hasn...
Matthias Braun [Fri, 22 Jan 2010 09:03:34 +0000 (09:03 +0000)]
add a default_layout_compound_type; the backend layouts the frametype now if it hasn't happened yet

[r26991]

14 years agocosmetic change
Michael Beck [Fri, 22 Jan 2010 00:02:57 +0000 (00:02 +0000)]
cosmetic change

[r26990]

14 years agofix doz stuff
Matthias Braun [Wed, 20 Jan 2010 08:34:24 +0000 (08:34 +0000)]
fix doz stuff

[r26988]

14 years ago- allow_ifconv interface was totally braindamaged. Use a simple and intuitive
Matthias Braun [Tue, 19 Jan 2010 22:53:49 +0000 (22:53 +0000)]
- allow_ifconv interface was totally braindamaged. Use a simple and intuitive
  interface now.
- Fix several bugs in the ia32 version of it
- Unfortunately this leads to the obscure Doz construct being always created
  (instead of only when cmovs are allowed) and firm generates broken code
  for that (testcase coming in 5 minutes)

[r26985]

14 years agoremove ins_permuted from CMovcc and Setcc constructors (again)
Matthias Braun [Mon, 18 Jan 2010 15:27:35 +0000 (15:27 +0000)]
remove ins_permuted from CMovcc and Setcc constructors (again)

[r26983]

14 years agoAdd an cse_neutral opcode property. Nodes with this property are
Michael Beck [Mon, 18 Jan 2010 02:28:05 +0000 (02:28 +0000)]
Add an cse_neutral opcode property. Nodes with this property are
CSE neutral to its users, i.e. op(..., x, ...) ~ op(..., y, ...) if x and y are both neutral.
Setting this property to ia32_ProduceVal nodes allow to CSE nodes that differ in ProduceVals only (which themself NEVER are cse'd).
This "fixes" divmod.

[r26981]

14 years agoAdd a rule to transform x .op. (x .op. y) into y .op. (x .op. x) for commutative...
Michael Beck [Mon, 18 Jan 2010 01:05:41 +0000 (01:05 +0000)]
Add a rule to transform x .op. (x .op. y) into y .op. (x .op. x) for commutative nodes. This finally "fixes" codegen/lea.c and might be usefull for and,or,xor as well.

[r26980]

14 years agoFixed move_consts_up() failure in some contexts (This partly fixes codegen/lea.c).
Michael Beck [Mon, 18 Jan 2010 00:32:49 +0000 (00:32 +0000)]
Fixed move_consts_up() failure in some contexts (This partly fixes codegen/lea.c).

[r26979]

14 years agoPartly undo r26950: there seems be be subtile difference between get_flags_node(...
Michael Beck [Sun, 17 Jan 2010 22:48:37 +0000 (22:48 +0000)]
Partly undo r26950: there seems be be subtile difference between get_flags_node() and determine_final_pnc() that are triggered by that change.
This should fix 175.vpr.

[r26977]

14 years agoReplace the shift_table[] by a simple macro.
Christoph Mallon [Fri, 15 Jan 2010 12:53:46 +0000 (12:53 +0000)]
Replace the shift_table[] by a simple macro.

[r26974]

14 years agostruct types still require names.
Christoph Mallon [Fri, 15 Jan 2010 12:23:35 +0000 (12:23 +0000)]
struct types still require names.

[r26973]

14 years agoCorrect typo in comment.
Christoph Mallon [Fri, 15 Jan 2010 12:20:56 +0000 (12:20 +0000)]
Correct typo in comment.

[r26972]

14 years agoImplement and use tarval_andnot().
Christoph Mallon [Fri, 15 Jan 2010 11:57:22 +0000 (11:57 +0000)]
Implement and use tarval_andnot().

[r26970]

14 years agoRemove the or_table[] and simply use |.
Christoph Mallon [Fri, 15 Jan 2010 11:21:54 +0000 (11:21 +0000)]
Remove the or_table[] and simply use |.

[r26969]

14 years agoRemove the and_table[] and simply use &.
Christoph Mallon [Fri, 15 Jan 2010 11:15:07 +0000 (11:15 +0000)]
Remove the and_table[] and simply use &.

[r26968]

14 years agoRemove the xor_table[] and simply use ^.
Christoph Mallon [Fri, 15 Jan 2010 10:18:16 +0000 (10:18 +0000)]
Remove the xor_table[] and simply use ^.

[r26967]

14 years agoRemove the not_table[] and simply use ^ SC_F.
Christoph Mallon [Fri, 15 Jan 2010 10:11:52 +0000 (10:11 +0000)]
Remove the not_table[] and simply use ^ SC_F.

[r26966]

14 years agoFixed register order (arg, the comments were in ATT).
Michael Beck [Fri, 15 Jan 2010 01:22:07 +0000 (01:22 +0000)]
Fixed register order (arg, the comments were in ATT).

[r26965]

14 years agoAdd binary emitter for setcc.
Michael Beck [Fri, 15 Jan 2010 01:16:48 +0000 (01:16 +0000)]
Add binary emitter for setcc.

[r26964]

14 years agoAs a reminiscence to the famous MAC/65 assembler changed modifier + into > and -...
Michael Beck [Thu, 14 Jan 2010 23:49:06 +0000 (23:49 +0000)]
As a reminiscence to the famous MAC/65 assembler changed modifier + into > and - into <, so >R is the hight part of a register, <R the low part!

[r26963]

14 years agoC99 feature removed.
Michael Beck [Thu, 14 Jan 2010 23:45:52 +0000 (23:45 +0000)]
C99 feature removed.

[r26962]

14 years agoLoop inversion does not fail the given test cases but is still 'dumb'.
Christian Helmer [Thu, 14 Jan 2010 15:23:29 +0000 (15:23 +0000)]
Loop inversion does not fail the given test cases but is still 'dumb'.

[r26961]

14 years agoMichael found a nice trick to implement sets for float compares
Matthias Braun [Thu, 14 Jan 2010 12:41:34 +0000 (12:41 +0000)]
Michael found a nice trick to implement sets for float compares

[r26960]

14 years agoReverted r26952, using the blocks irg is ok ...
Michael Beck [Thu, 14 Jan 2010 00:08:39 +0000 (00:08 +0000)]
Reverted r26952, using the blocks irg is ok ...

[r26959]

14 years agoAdd my debugging code it might be useful in the future ...
Michael Beck [Wed, 13 Jan 2010 23:16:27 +0000 (23:16 +0000)]
Add my debugging code it might be useful in the future ...

[r26958]

14 years agoremove cond_kind attribute, it was never used in a consistent or correct way anyway
Matthias Braun [Wed, 13 Jan 2010 15:48:12 +0000 (15:48 +0000)]
remove cond_kind attribute, it was never used in a consistent or correct way anyway

[r26957]

14 years agocleanup and fix some bugs in ir reader/writer
Matthias Braun [Wed, 13 Jan 2010 15:41:28 +0000 (15:41 +0000)]
cleanup and fix some bugs in ir reader/writer

[r26956]

14 years agoBugFix: the name o for the NEW NODE was a little bit misleading ...
Michael Beck [Tue, 12 Jan 2010 23:02:56 +0000 (23:02 +0000)]
BugFix: the name o for the NEW NODE was a little bit misleading ...

[r26955]

14 years agoTry to fix a rare edges bug:
Michael Beck [Tue, 12 Jan 2010 22:27:48 +0000 (22:27 +0000)]
Try to fix a rare edges bug:
- if a node was built with edges disabled gets dead, but is revived by CSE when edges are enabled, it had NO edges
- tries to keep track of such dead nodes ...

[r26954]

14 years agoSimplify pointer arithmetic.
Michael Beck [Tue, 12 Jan 2010 21:35:35 +0000 (21:35 +0000)]
Simplify pointer arithmetic.

[r26953]

14 years agoCreating a block on some irg is pointless if all other nodes are created on current_i...
Michael Beck [Tue, 12 Jan 2010 21:31:30 +0000 (21:31 +0000)]
Creating a block on some irg is pointless if all other nodes are created on current_ir_graph.

[r26952]