libfirm
11 years agoremove now unused get_irn_outs_computed()
Matthias Braun [Tue, 28 Aug 2012 12:44:52 +0000 (14:44 +0200)]
remove now unused get_irn_outs_computed()

11 years agoremove unused NEW_REASSOC code
Matthias Braun [Tue, 28 Aug 2012 12:43:56 +0000 (14:43 +0200)]
remove unused NEW_REASSOC code

11 years agoremove pointless compute_irp_outs()/free_irp_outs()
Matthias Braun [Tue, 28 Aug 2012 12:36:08 +0000 (14:36 +0200)]
remove pointless compute_irp_outs()/free_irp_outs()

11 years agoremove unused+fragile NULL_OBST
Matthias Braun [Tue, 28 Aug 2012 12:29:34 +0000 (14:29 +0200)]
remove unused+fragile NULL_OBST

11 years agomove load mode shrinking into ldst phase
Matthias Braun [Mon, 27 Aug 2012 12:50:17 +0000 (14:50 +0200)]
move load mode shrinking into ldst phase

Performing it as localopt was hairy as the optimisation dependet on
correct iredges values which were misleading/wrong during construction
of new stuff.

11 years agoia32_transform: remove unused SETCC_TR_SBB
Matthias Braun [Sun, 26 Aug 2012 08:46:10 +0000 (10:46 +0200)]
ia32_transform: remove unused SETCC_TR_SBB

11 years agoshow optimisation warnings in ia32 conv/conv opts
Matthias Braun [Fri, 24 Aug 2012 17:03:54 +0000 (19:03 +0200)]
show optimisation warnings in ia32 conv/conv opts

The middleend should optimize all these cases, it does so for 99% of
them already. There are just some cases where ands get transformed into
conversions which the middleend doesn't catch yet.

11 years agoshrink load mode if not all bits are used
Matthias Braun [Fri, 24 Aug 2012 16:51:21 +0000 (18:51 +0200)]
shrink load mode if not all bits are used

11 years agofactorize upper_bits_clean and use in sparc+ia32
Matthias Braun [Fri, 24 Aug 2012 16:49:53 +0000 (18:49 +0200)]
factorize upper_bits_clean and use in sparc+ia32

This needed some rewriting as ia32 previously checked already
transformed nodes while sparc was checking nodes before transformation.
Change ia32 to check nodes before transformation too. Also improved some
code in sparc+ia32.

11 years agoirop: add more generic function callbacks
Matthias Braun [Mon, 27 Aug 2012 11:41:15 +0000 (13:41 +0200)]
irop: add more generic function callbacks

11 years agotarval: shift variants with unsigned right operand
Matthias Braun [Fri, 24 Aug 2012 15:44:09 +0000 (17:44 +0200)]
tarval: shift variants with unsigned right operand

11 years agoia32: skip downconvs in front of Store
Matthias Braun [Thu, 23 Aug 2012 12:04:55 +0000 (14:04 +0200)]
ia32: skip downconvs in front of Store

11 years agoadd more Conv(Conv) localopt rules
Matthias Braun [Wed, 22 Aug 2012 14:41:09 +0000 (16:41 +0200)]
add more Conv(Conv) localopt rules

11 years agofix some problems in ia32_intrinsice/map_Conv
Matthias Braun [Thu, 23 Aug 2012 11:34:18 +0000 (13:34 +0200)]
fix some problems in ia32_intrinsice/map_Conv

11 years agouse confirm_irg_properties in lower_intrinsics
Matthias Braun [Thu, 23 Aug 2012 09:02:26 +0000 (11:02 +0200)]
use confirm_irg_properties in lower_intrinsics

11 years agoexecfreq calculation fails in case of unreachable code
Matthias Braun [Thu, 23 Aug 2012 09:02:12 +0000 (11:02 +0200)]
execfreq calculation fails in case of unreachable code

11 years agoput execfreq in block-attrs instead of hashmap
Matthias Braun [Thu, 23 Aug 2012 09:00:58 +0000 (11:00 +0200)]
put execfreq in block-attrs instead of hashmap

The hashmap used to point to blocks which have already been deleted.

11 years agoremove unnecessary irma_unitialized
Matthias Braun [Wed, 22 Aug 2012 13:19:40 +0000 (15:19 +0200)]
remove unnecessary irma_unitialized

11 years agoImprove documentation about float mantissa size
Matthias Braun [Wed, 22 Aug 2012 12:21:42 +0000 (14:21 +0200)]
Improve documentation about float mantissa size

11 years agoremove the concept of a strictconv
Matthias Braun [Tue, 21 Aug 2012 13:49:02 +0000 (15:49 +0200)]
remove the concept of a strictconv

This means floatingpoint calculation in a firm graph must be performed
in the mode specified (and may not be performed in a wider mode as
before).

11 years agoremove unused dead_node_elim_subst hook
Matthias Braun [Fri, 17 Aug 2012 11:25:37 +0000 (13:25 +0200)]
remove unused dead_node_elim_subst hook

11 years agoavoid usage of modifies_fp flags in sparc backend
Matthias Braun [Thu, 16 Aug 2012 17:49:48 +0000 (19:49 +0200)]
avoid usage of modifies_fp flags in sparc backend

11 years agouse be_foreach_definition in liveness_transfer
Matthias Braun [Thu, 16 Aug 2012 14:30:56 +0000 (16:30 +0200)]
use be_foreach_definition in liveness_transfer

11 years agofix be_foreach_definition cls argument
Matthias Braun [Thu, 16 Aug 2012 14:21:15 +0000 (16:21 +0200)]
fix be_foreach_definition cls argument

11 years agosimplify by using C99
Matthias Braun [Thu, 16 Aug 2012 12:25:01 +0000 (14:25 +0200)]
simplify by using C99

11 years agorefactor specfiles/scripts
Matthias Braun [Thu, 16 Aug 2012 11:43:55 +0000 (13:43 +0200)]
refactor specfiles/scripts

11 years agofix dwarf abbrev registration
Matthias Braun [Wed, 15 Aug 2012 17:27:14 +0000 (19:27 +0200)]
fix dwarf abbrev registration

apparently abbrev number 0 is not allowed, so we have to start our
abbrev numbers at 1

11 years agoDon't use consecutive numbers for basic blocks from different functions.
Manuel Mohr [Mon, 13 Aug 2012 12:44:00 +0000 (14:44 +0200)]
Don't use consecutive numbers for basic blocks from different functions.

Consecutive numbers can make it difficult to combine assembly output from
different compiler runs, which is done by the check/checkfile scripts to find
bugs in the SPEC suite.  If the number of basic blocks of a function changed
between compiler runs, the assembler will likely complain about duplicate labels.
Leaving a bit more space, e.g. 100, is a pragmatic fix.

11 years agosparc: Use be_peephole_exchange instead of exchange to update liveness information.
Manuel Mohr [Mon, 13 Aug 2012 12:42:04 +0000 (14:42 +0200)]
sparc: Use be_peephole_exchange instead of exchange to update liveness information.

11 years agofix bug introduced in 'cleanup' commit
Matthias Braun [Thu, 9 Aug 2012 16:40:40 +0000 (18:40 +0200)]
fix bug introduced in 'cleanup' commit

11 years agosparc: fix wrong delay slot test
Matthias Braun [Thu, 9 Aug 2012 16:34:30 +0000 (18:34 +0200)]
sparc: fix wrong delay slot test

11 years agosparc: fix delayslot picking order
Matthias Braun [Thu, 9 Aug 2012 14:53:37 +0000 (16:53 +0200)]
sparc: fix delayslot picking order

11 years agobeprefalloc: fix assignment of big values
Matthias Braun [Thu, 9 Aug 2012 10:06:34 +0000 (12:06 +0200)]
beprefalloc: fix assignment of big values

11 years agosparc: support float perms
Matthias Braun [Thu, 9 Aug 2012 10:04:59 +0000 (12:04 +0200)]
sparc: support float perms

11 years agosparc: split128 bit float loads into 2x64bit load
Matthias Braun [Thu, 9 Aug 2012 10:03:59 +0000 (12:03 +0200)]
sparc: split128 bit float loads into 2x64bit load

11 years agobeprefalloc: simplify by using C99
Matthias Braun [Mon, 6 Aug 2012 09:25:56 +0000 (11:25 +0200)]
beprefalloc: simplify by using C99

11 years agomore irouts cleanup
Matthias Braun [Mon, 6 Aug 2012 08:08:35 +0000 (10:08 +0200)]
more irouts cleanup

11 years agoirouts: cleanup use C99
Matthias Braun [Thu, 2 Aug 2012 20:45:47 +0000 (22:45 +0200)]
irouts: cleanup use C99

11 years agouse is_$KIND(n) instead of get_irn_op(n) == op_$KIND.
Christoph Mallon [Sun, 5 Aug 2012 09:37:12 +0000 (11:37 +0200)]
use is_$KIND(n) instead of get_irn_op(n) == op_$KIND.

11 years agoRemove duplicate calls to register_node_cmp_func().
Christoph Mallon [Sun, 5 Aug 2012 09:37:58 +0000 (11:37 +0200)]
Remove duplicate calls to register_node_cmp_func().

11 years agos/get_irn_n(irn, -1)/get_nodes_block(irn)/.
Christoph Mallon [Sun, 5 Aug 2012 08:56:35 +0000 (10:56 +0200)]
s/get_irn_n(irn, -1)/get_nodes_block(irn)/.

11 years agoRemove redundant retrieval of blocks.
Christoph Mallon [Sun, 5 Aug 2012 08:56:10 +0000 (10:56 +0200)]
Remove redundant retrieval of blocks.

11 years agoUse get_Block_cfgpred_pos().
Christoph Mallon [Sat, 4 Aug 2012 12:21:16 +0000 (14:21 +0200)]
Use get_Block_cfgpred_pos().

11 years agoReturn the profile init irg from ir_profile_instrument() instead of guessing that...
Christoph Mallon [Sat, 4 Aug 2012 08:36:00 +0000 (10:36 +0200)]
Return the profile init irg from ir_profile_instrument() instead of guessing that it is the last irg.

11 years agoSimplify control flow.
Christoph Mallon [Sat, 4 Aug 2012 07:27:53 +0000 (09:27 +0200)]
Simplify control flow.

11 years agoReplace the reassoc env struct by its only member.
Christoph Mallon [Fri, 3 Aug 2012 17:05:18 +0000 (19:05 +0200)]
Replace the reassoc env struct by its only member.

11 years agoRemove irg from the reassoc env.
Christoph Mallon [Fri, 3 Aug 2012 17:05:06 +0000 (19:05 +0200)]
Remove irg from the reassoc env.

11 years agoRemove the write-only variable changes from reassoc.
Christoph Mallon [Fri, 3 Aug 2012 16:59:24 +0000 (18:59 +0200)]
Remove the write-only variable changes from reassoc.

11 years agosparc: rework emitter/delayslot handling
Matthias Braun [Wed, 1 Aug 2012 16:22:29 +0000 (18:22 +0200)]
sparc: rework emitter/delayslot handling

We can now pull instructions from other blocks up and use the annul bits
if profitable.

11 years agofix bugs in execfreq rework commit
Matthias Braun [Wed, 1 Aug 2012 16:20:18 +0000 (18:20 +0200)]
fix bugs in execfreq rework commit

11 years agobe: Proj_Cmp transformers are unnecessary
Matthias Braun [Wed, 1 Aug 2012 11:28:32 +0000 (13:28 +0200)]
be: Proj_Cmp transformers are unnecessary

11 years agouse C99 to cleanup code
Matthias Braun [Tue, 31 Jul 2012 12:24:13 +0000 (14:24 +0200)]
use C99 to cleanup code

11 years agoAssert that there is currently no object under construction, when calling be_get_be_o...
Christoph Mallon [Thu, 2 Aug 2012 06:31:02 +0000 (08:31 +0200)]
Assert that there is currently no object under construction, when calling be_get_be_obst().

11 years agoFactorise code to set the register contraints and registers of the SPARC start node.
Christoph Mallon [Wed, 1 Aug 2012 08:19:42 +0000 (10:19 +0200)]
Factorise code to set the register contraints and registers of the SPARC start node.

11 years agoFactorise code to get the register projs of the SPARC start node.
Christoph Mallon [Wed, 1 Aug 2012 08:14:51 +0000 (10:14 +0200)]
Factorise code to get the register projs of the SPARC start node.

11 years agoPut SPARC initial register info into a struct.
Christoph Mallon [Thu, 2 Aug 2012 07:05:13 +0000 (09:05 +0200)]
Put SPARC initial register info into a struct.

11 years agoSimplify emit_sparc_Div(): Pass the instruction mnemonic instead of a bool flag.
Christoph Mallon [Wed, 1 Aug 2012 08:08:03 +0000 (10:08 +0200)]
Simplify emit_sparc_Div(): Pass the instruction mnemonic instead of a bool flag.

11 years agoTalk a bit about ADTs in firms API
Matthias Braun [Mon, 30 Jul 2012 16:31:28 +0000 (18:31 +0200)]
Talk a bit about ADTs in firms API

11 years agosimplify and cleanup execfreq API
Matthias Braun [Mon, 30 Jul 2012 16:30:51 +0000 (18:30 +0200)]
simplify and cleanup execfreq API

11 years agofix import/export of ASM
Matthias Braun [Fri, 27 Jul 2012 11:53:06 +0000 (13:53 +0200)]
fix import/export of ASM

11 years agomake get_op_ops result non-const
Matthias Braun [Thu, 26 Jul 2012 14:44:27 +0000 (16:44 +0200)]
make get_op_ops result non-const

so external users can set their own opcode functions.

11 years agoprefere local registers when allocating for sparc
Matthias Braun [Mon, 23 Jul 2012 12:16:47 +0000 (14:16 +0200)]
prefere local registers when allocating for sparc

11 years agoAdd and use amd64_emitf().
Christoph Mallon [Tue, 24 Jul 2012 17:42:09 +0000 (19:42 +0200)]
Add and use amd64_emitf().

11 years agoia32: avoid assembler warning for 16bit stores
Matthias Braun [Mon, 23 Jul 2012 12:35:30 +0000 (14:35 +0200)]
ia32: avoid assembler warning for 16bit stores

11 years agoupdate TEMPLATE backend
Matthias Braun [Thu, 19 Jul 2012 08:38:11 +0000 (10:38 +0200)]
update TEMPLATE backend

Still broken for anything except int f(void) { return 0; } though...

11 years agorework ASM node, it always has a memory input now
Matthias Braun [Mon, 23 Jul 2012 12:15:08 +0000 (14:15 +0200)]
rework ASM node, it always has a memory input now

You can still attach NoMem if no memory input is present.
This makes it more consistent with the Call node and fixes failing
get_ASM_mem in case of no memory input.

11 years agoget_Call_n_params: use int for consistency
Matthias Braun [Mon, 23 Jul 2012 11:26:52 +0000 (13:26 +0200)]
get_Call_n_params: use int for consistency

This makes it consistent with other functions like get_irn_arity().
(Though I must admit that we should change all these functions from
 "int" to unsigned at some point)

11 years agoFix random scheduler.
Manuel Mohr [Mon, 23 Jul 2012 12:15:28 +0000 (14:15 +0200)]
Fix random scheduler.

After the switch to C99, the foreach_ir_nodeset macro introduced a separate
loop variable, which shadowed the local variable "irn".  Thus, an uninitialized
pointer was passed to is_cfop.

11 years agoEat format specifier parameter.
Sebastian Buchwald [Mon, 23 Jul 2012 08:30:03 +0000 (10:30 +0200)]
Eat format specifier parameter.

This fixes backend/setmem.c.

11 years agoLet list_for_each_entry(), list_for_each_entry_reverse() and list_for_each_entry_safe...
Christoph Mallon [Fri, 20 Jul 2012 08:24:00 +0000 (10:24 +0200)]
Let list_for_each_entry(), list_for_each_entry_reverse() and list_for_each_entry_safe() declare their iterator variables.

11 years agoRemove __list_for_each().
Christoph Mallon [Fri, 20 Jul 2012 07:43:48 +0000 (09:43 +0200)]
Remove __list_for_each().

It is identical to list_for_each(), though its comment claimed otherwise.

11 years agoRemove the unused ir_lnk_nodeset.
Christoph Mallon [Fri, 20 Jul 2012 07:58:43 +0000 (09:58 +0200)]
Remove the unused ir_lnk_nodeset.

11 years agoRemove the unused ir_lnk_nodemap.
Christoph Mallon [Fri, 20 Jul 2012 07:52:19 +0000 (09:52 +0200)]
Remove the unused ir_lnk_nodemap.

11 years agoLet matrix_foreach(), matrix_foreach_in_col() and matrix_foreach_in_row() declare...
Christoph Mallon [Fri, 20 Jul 2012 07:14:06 +0000 (09:14 +0200)]
Let matrix_foreach(), matrix_foreach_in_col() and matrix_foreach_in_row() declare their iterator variables.

11 years agoLet foreach_ir_nodeset() declare its iterator variables.
Christoph Mallon [Thu, 19 Jul 2012 16:17:24 +0000 (18:17 +0200)]
Let foreach_ir_nodeset() declare its iterator variables.

11 years agoLet panic() print file, line and function.
Christoph Mallon [Thu, 19 Jul 2012 07:50:57 +0000 (09:50 +0200)]
Let panic() print file, line and function.

Remove now redundant (and sometimes wrong) location info from the panic messages.

11 years agoMake \n in arm_emitf() work.
Christoph Mallon [Thu, 19 Jul 2012 07:51:52 +0000 (09:51 +0200)]
Make \n in arm_emitf() work.

11 years agoRemove unused emit_templates.
Christoph Mallon [Thu, 19 Jul 2012 07:51:25 +0000 (09:51 +0200)]
Remove unused emit_templates.

11 years agoAdd sparc_emitf() to make the SPARC emitter more readable.
Christoph Mallon [Tue, 17 Jul 2012 13:46:08 +0000 (15:46 +0200)]
Add sparc_emitf() to make the SPARC emitter more readable.

11 years agoUse ia32_emitf() in ia32_spec.pl.
Christoph Mallon [Wed, 18 Jul 2012 15:47:28 +0000 (17:47 +0200)]
Use ia32_emitf() in ia32_spec.pl.

11 years agointroduce TEMPLATE_emitf
Matthias Braun [Wed, 18 Jul 2012 14:48:25 +0000 (16:48 +0200)]
introduce TEMPLATE_emitf

11 years agointroduce arm_emitf
Matthias Braun [Wed, 18 Jul 2012 12:12:49 +0000 (14:12 +0200)]
introduce arm_emitf

11 years agouse arch_emitf for emit lines without dot prefix
Matthias Braun [Wed, 18 Jul 2012 12:09:33 +0000 (14:09 +0200)]
use arch_emitf for emit lines without dot prefix

11 years agosparc: Fix Alloc nodes.
Manuel Mohr [Fri, 13 Jul 2012 14:22:03 +0000 (16:22 +0200)]
sparc: Fix Alloc nodes.

11 years agorename hashset.c to hashset.c.inl
Matthias Braun [Mon, 16 Jul 2012 16:17:32 +0000 (18:17 +0200)]
rename hashset.c to hashset.c.inl

11 years agoadd missing doxygen docu
Matthias Braun [Mon, 16 Jul 2012 15:06:27 +0000 (17:06 +0200)]
add missing doxygen docu

11 years agorework hashset
Matthias Braun [Mon, 16 Jul 2012 14:32:55 +0000 (16:32 +0200)]
rework hashset

Only define functions for which the user provided a renaming #define
(instead of forcing the users to create name for everything)
Only define iterator struct if a rename #define is present (instead of
forcing the user to define NO_ITERATOR if he doesn't want one)

11 years agoreplace gnu extension with C99
Matthias Braun [Mon, 16 Jul 2012 14:30:31 +0000 (16:30 +0200)]
replace gnu extension with C99

11 years agofix prefalloc after sched_foreach changes
Matthias Braun [Mon, 16 Jul 2012 13:57:19 +0000 (15:57 +0200)]
fix prefalloc after sched_foreach changes

11 years agouse bool as return value in XXX_insert and ID_HASH
Matthias Braun [Mon, 16 Jul 2012 12:53:46 +0000 (14:53 +0200)]
use bool as return value in XXX_insert and ID_HASH

also flip true/false in the implementation to match the documentation in
irnodeset.h

11 years agosimplify + optimize be_lv_foreach
Matthias Braun [Fri, 13 Jul 2012 21:04:41 +0000 (23:04 +0200)]
simplify + optimize be_lv_foreach

11 years agomake cpset, pset_new API private
Matthias Braun [Mon, 16 Jul 2012 13:22:51 +0000 (15:22 +0200)]
make cpset, pset_new API private

11 years agofix warning
Matthias Braun [Mon, 16 Jul 2012 12:54:31 +0000 (14:54 +0200)]
fix warning

11 years agosparc: Fix gen_Const on 64-bit machines.
Manuel Mohr [Fri, 13 Jul 2012 15:18:59 +0000 (17:18 +0200)]
sparc: Fix gen_Const on 64-bit machines.

11 years agoFixed warnings.
Sebastian Buchwald [Mon, 16 Jul 2012 06:10:49 +0000 (08:10 +0200)]
Fixed warnings.

11 years agoAdd a wrapper macro for ir_nodehashmap_get(), which has the return type as additional...
Christoph Mallon [Fri, 13 Jul 2012 20:57:54 +0000 (22:57 +0200)]
Add a wrapper macro for ir_nodehashmap_get(), which has the return type as additional parameter.

11 years agoUse get_blocksched_entry().
Christoph Mallon [Fri, 13 Jul 2012 20:25:37 +0000 (22:25 +0200)]
Use get_blocksched_entry().

11 years agoAdd wrapper macros for pset_first() and pset_next(), which have the return type as...
Christoph Mallon [Fri, 13 Jul 2012 19:33:43 +0000 (21:33 +0200)]
Add wrapper macros for pset_first() and pset_next(), which have the return type as additional parameter.

11 years agoAdd the * for the type in foreach_pset() automatically.
Christoph Mallon [Fri, 13 Jul 2012 19:16:01 +0000 (21:16 +0200)]
Add the * for the type in foreach_pset() automatically.

11 years agoMake the pointer in the dump_*_FUNC typedefs explicit.
Christoph Mallon [Fri, 13 Jul 2012 19:08:23 +0000 (21:08 +0200)]
Make the pointer in the dump_*_FUNC typedefs explicit.