2 added auto documentation in Makefiles, configure, etc
3 example in ir/ir/ircons.c - much must be added
4 creation of documentation by 'make autodoc' in architecture directory
7 added lots of #ifdef HAVE_CONFIG_G #include "config.h" #endif
8 replaced some C++ style comments (//) by standard C comments /**/
11 - configure (with some features, see --help for more)
12 - make [depend | tags | install]
13 - make [run] in testprograms
15 - compilation on SunOS
17 - automatic call of autoconf if required
20 More colours in vcg output.
21 Fixed bug: cse found that start block equals it's
22 first successor as both have the Start block as predecessor.
23 This only happens for local_optimize_graph() as during construction
24 the Start block is not entered in the value table.
25 Changed implementation: irgmod: local_optimize_graph() did not
26 empty the hash table with the irnodes for cse. This might cause that
27 cse turns up with a node that seems better but was removed from the
28 graph in an earlier optimization phase.
29 Removed old #if 1 from ircons.c
30 Commented in call of optimization for Block nodes in irgopt.c, copy_preds():
31 Optimizes blocks that had bad predecessors.
36 Moved struct from irprog.h to irprog_t.h, same for irmode.h.
37 Added a module deb_info in debug.h. Adapted makefile. Added example
39 Removed use of debug.h in ident.c. Now debug.c|h can be moved to
41 Removed inabled code for dead node elimination in irgopt.h.
42 Renamed some missnamed access routines (_of_). Macros with old names
43 are in old_fctnames.h.
44 Edited makefiles to remove #* and *.flc.
47 Some minor bugfixes...
50 After compacting of in arrays in dead_node_elimination
51 merge blocks and remove Phis with one pred.
54 Freeing of obstack in dead_node_elimination commented in.
55 Compacting in arrays of Block and Phi nodes in dead_node_
60 added set/get_SymConst_type_or_id in irnode.h
61 added field offset to entity in entity.h
62 added field size to type_class in type.h
63 include "gmp.h" in tv.h with "" instead <>
66 Some changes to make the lib better portable
69 Initialize max_node_nr in irprog.
72 Now outputs warning if faulty type in irdump, dump_type_info.
73 Explicit string termination in irdump, vcg_open.
76 Added external to declaration of irp.
77 Added typedef before pns and pnc_number.
78 irmode.c, init_mode(): We need to memset all new modes as
79 tarval_vrfy reads fields before they are initialized: It
80 compares to min/max when tarvals for min/max are allocated!
83 Changed parameter of Methods in type.h and type.c from
84 class to clss. Class is a C++ keyword.
87 Changed some testprograms to accomodate Uebprakt.
90 Finished implementation of dump_all_types.
91 Added new testprogram inheritance_example.
94 Added seven access routines in type.[hc]:
95 get_class_n_member, get_class_n_subtype, get_class_n_supertype,
96 get_strct_n_member, add_strct_member, get_strct_member and set_strct_member.
97 Fixed the type_walk_2 for those seven routines.
100 Added irdump routine dump_all_types.
101 Did changes to irprog, type, typewalk to achieve this.
102 typewalk needs to walk along members, sub and supertypes, this
103 is still missing! irdump then needs to output these edges.
105 ======================================================================
106 ==================== New version: 0.2.5 ==============================
107 ======================================================================
110 Made new Version: 0.2.5
112 15.8.2000 Goetz until 3.9.00
113 Separated irnode.h and many others into two files: one public
115 Added funcionality to extract headers for lib.
118 type_dump also dumps irg->ent
119 if_example: corrected nr of locals
122 irgopt: Correct copy of self pointer in start block.
123 irgopt: Correct treatment of loops: pre function in walker
124 breaks all possible loops in Phi and Block nodes.
125 irr_loop_example: wrong Return statement
126 Now I fixed all but one error: in memory_example.
127 This error showed a conceptual problem, so I wrote
128 a slightly different algorithm. This now runs for
130 dead_node_example: cse is buggy!! merges start and the
134 looking at bug in dead_node_elimination.
136 irnode: all get_..._arr functions changed
137 ircons: new_r_Block: set matured flag.
138 ircons: new_r_SymConst: needs mode_p for linkage_ptr_info.
139 adapted call_str_example to new concepts.
142 Implemented simpler Phi construction algorithm that constructs
143 correct code for three_cfpred_example in ircons. This algorithm
144 generates more Id nodes than the original algorithm and therefore
146 Also made some changes to optimizations of Not.
149 Fixed a bug, caused by the recursive use in type.h and entity.h.
150 Deleted the _TYPE_TYPEDEF_ and inserted the _ENTITY_TYPEDEF_ instead.
151 Fixed a problem in if_while testprogram, so it now works.
154 Fixed bug in optimize(). Returned Null instead n if
155 get_optimize() == false.
158 Added some access routines in type.[hc]. Solved a recursive definition
159 of type_class struct, entity struct and type union.
162 Separated entity header into pure functional header and header
166 ... a bunch small changes not documented
169 Changed output of oo_prog_example: now uses the internal list
170 of all irgs. Had to implement some of the access routines for
171 that. Also fixed a bug in irdump. Main routines did not use
172 current_ir_graph properly.
175 Implemented some missing parts in irgopt.
176 Added field irg to entity. Only valid if entity is a method.
177 Had to resove a cyclic de[endency between irgraph.h and entity.h
179 Added fields sub and super to type_class for inheritance.
180 Added field main_irg to irprog.
183 Fixed some bugs in irgopt.c
184 Added some missing 'get_new_node' methods, so the new obstack contains
188 Renamed ir_vrfy to irn_vrfy and vrfy_graphg to irg_vrfy.
189 Solved some copy'n'paste problems. Deleted most debug-code!
190 Added comments to several files.
193 Fixed bug in _r_ constructors for all four Div operations.
194 Fixed bug in turn_into_tuple: didn't remember the block.
195 Tested transform_node.
198 Fixed some testprograms to new semantics of firm.
199 Added testprogram global_var_example.
200 Fixed a bug in irop: Size of Sel node was (entity *) instead of
201 sel_attr. Therefor array_heap_example aborted.
202 Also found a missing break in typewalk, case iro_Alloc.
203 Added a construct that unifies all things constructed by the lib
204 and needed to represent a program: irprog.ch
205 This contains a list of all types as well as a list of all ir graphs.
206 I added calls to initialization and constructors so that this is constructed
207 automatically. I changed firm.c, type.c, irgraph.c and ev. more.
208 Removed strange block struct and constructor from ircons.c.
209 Moved routines for automatic Phi construction from irgmod to ircons.
210 Sorted functions in ircons to reflect the different interfaces.
211 Renamed dataseg to globals to be conformant with documentation.
212 Added conservation of current_ir_graph to irgopt.c.
213 Corrected bug in Makefiles: wrong path to directory ./inlude.
216 Commented a whole bunch of stuff, e.g. in ircons.h (Procedure to construct)
217 We should change the naming of the Block constructor.
218 Removed acces routines to attr. "closed" of Block.
219 Removed second implementation of new_ir_node from ircons and some comments
220 concerned with the now resolved cyclic dependency.
221 Fixed some bugs in irgopt so that the compilation goes through.
224 Changed the irnode attribut 'visit' into 'visited'.
225 Added some access functions, like get/set_irn_visit etc.
228 Renamed some access funtion in irgraph.*.
229 Deleted two global flags (ir_visited and block_visited) from irgraph.*.
230 Added two attributes to the irgraph struct. The visited flags belongs
231 to a ir graph, not to a whole program.
234 A new optimization has been finished. The dead-node-elimination copies
235 the existing ir graph from one opstack to another. While walking the
236 graph, only the reachable nodes will be copied, so the "dead-nodes"
237 (unreachable in the controlflow) are removed.
240 Solved some problems in the 'copy_node' function. The in array was not
241 as easy as it seamed.
244 Wrote a new 'post' funtion, for future use in 'dead-node-elimination'
245 optimization, which is needed in the paramter list of 'irg_walk'.
248 Moved 'optimze_in_place_wrapper' from iropt.* tothe new files irgopt.*.
249 New functions 'local_optimze_graph' and 'dead_node_elimination' are added,
253 Removed some files from the archive, after dependencies and usage are
255 - 'ir/common/strerror.c'
257 - 'ir/ident/xx_ident.h'
258 an empty file, only included by 'ident.c', but never used;
259 - 'ir/tv/label.c' and
261 contained a numeric counter;
262 The files were included in 'tv.h' and implemented in 'tarval.c'. The two
263 functions 'tarval_label' and 'tarval_forall_labeled' were also never used.
264 In the old fiasco compiler, the label thing is used in the backend.
265 Search for 'babil' to see the usage.
266 Also removed the two attributes 'lab' and 'used' in the tarval struct.
269 Moved the 'new_ir_node' constructor from ircons.* to irnode.* and fixed
270 afterwards some recursive includes, so libfirm works again.
273 Did a lot of changes, which I never commented until now (4.7.00).
275 * Added new result to Start node: Pointer to global data segment.
276 * Extended Semantics of SymConst node to represent information for the
278 * Added arithmeitc nodes (Shrs, Minus ...)
280 Rearranged the directory structure and adjusted the makefiles.
281 The directories contain:
282 ir: everything for the intermediate representation (better: src?)
283 /ir: the ir itself, and standard optimizations.
284 /tv: the target value module
285 /tr: the type and entity representation
286 /adt: abstract data types
287 /common: stuff needed by all other dirs
288 /debug: debugging Unterstuetzung
290 include: external files needen as includes
291 testprograms: examples to test the lib.
293 The makefiles generate files with extension .d that contain the dependencies
297 Added access routine to attribute link of irnode in irnode.ch.
298 Added get_negated_pnc to irnode.ch.
301 Added an iterator in iropt that calls the optimization for all nodes.
302 Copied optimize's code to optimize_in_place and removed deallocations.
303 Made set_irn_n in irnode.c public.
304 Added Bad as possible cfg predecessor in is_cfg_node in irnode. Bads
305 are allowded as cfgpredecessors to represent dead "incoming" control
307 Added call to optimize_in_place in mature_block. Is this useful?
310 Changed tests from comparing enums to comparing pointers. This is more
311 efficient (is it?) and reads better. e.g., instead get_irn_opcode == irm_And
312 now get_irn_op == op_And
315 Compared equivalent_value to the one in the original fiasco.
316 Added a test in case iro_And.
317 Changed implementation of iro_Div. Added routines turn_into_tuple
318 and set_irn_op() in irgmod/irnode.
319 Changed implementation of irn_Minus (although commented out).
320 Now all features are ported or documented for this function.
323 Compared computed_value to the one in the original fiasco.
324 Added one further optimization in case iro_Proj.
325 Now all features are ported for this function.
328 Updated comments in ircons.h.
331 Changed possible attribute of SymConst from type_class to type.
332 SymConst size could be the size of a union, array, ...
335 Implemented two dumpers that dump type information and a graph with
339 Implemented a walker that walks over the type informatin that can
340 be reached from an ir node.
341 Added routine get_kind(firm_thing) in common.h, Added file common.c.
342 Added files typewalk.ch and routines to irdump.
343 Added visited flags and initialization to entity and all types.
344 Implemented some of the missing access routines in type.c, entity.c
347 Implemented constructor for ShrA.
349 Added routine that iterates the graph and verifies all nodes.
350 Added Phi_in stack to irgraph. This allows to build several
351 graphs at once with respect to the Phi building algorithm.
354 Implemented dumper for control flow graphs. Changed irr_* and dead_*
355 examples to dump cfg.
358 Implemeted explicit stack for the Phi node generation. See ircons.c.
361 added include string.h in xoprintf.c to get rid of warning:
362 implicit declaration of function `bcopy'
366 Added more cases to equivalent_node.
367 Portet gigo, identify, identify_remember.
368 The set/pset library can not handle several hash tables. At least,
369 compiling several procedures causes a segmentation fault during access
370 to the tables (oo_program_example). Need to work on this.
371 transform_node still needs to be ported.
372 some cases in equivalent_node are still missing.
374 To get it running I had to remove the call to optimize in the
375 new_Block constructor. It can only be called when the Block is
379 Introduced a walker that walks only over blocks. The asserts
380 might be too strict for general graphs, but so far it works.
381 For the walker I introduced an additional flag in the attribute
382 of Blocks, an a global block_visited variable (in irgraph.h).
383 Furhter I modularized dump_ir_node, implemented dump_ir_graph
384 with the existing walker, and added new routines to output a
386 Changed the examples to call the new dump routine.
389 Added auxiliary routines to ir_node:
390 skip_Proj, skip_Nop, is_Bad ...
391 Changed access routines to use get_irn_n instead of explicit array
392 accesses. Changed get_irn_n to call skip_Id, so that the access routines
393 never will return Id nodes.
396 Repaired Phi computation, changed new_r_Phi_in. Added test program to
397 test irregular controlflow.
400 Updated optimizations computed_value and equivalent_node to new
401 Syntax of FIRM nodes and to use access routines.
402 Added routine skip_Proj in irnode.
404 2.2.2000 Boris Boesler
405 Added files irgwalk.c and irgwalk.h. They include a simple function to
406 traverse an ir graph and execute pre and post functions to current node.
409 Added arrays with parameters and result types to the type informtion
410 of a procedure. This is needed for the code generation. Also added
411 the corresponding access routines.
412 Adapted the testprograms.
415 Found a bug / complication: the call order
416 get_value (makes Phi0, put's it into graph_arr)
417 set_value (overwrites Phi0 in graph_arr)
418 mature_block (upgrades Phi0, puts it again into graph_arr, overwriting
420 fails. Added test wether graph_arr is already set in phi_merge.
422 Added tons of comments to explain Phi generation -- the stack hack.
426 irdump now outputs the pnc_number for projs of Cmp nodes.
427 Added routine to access the pnc_string.
430 Added result "dataseg" to Start node, with all it's consequences.
431 We need this for the compiler lab to translate global variables.
432 Now they can be selected from the data segment, and the start
433 node supplies the pointer to this segment.
434 These changes are guarded by preprocessor variable UEBPRAKT in
436 Changed files: common.h, irgraph.ch, irnode.h
440 removed array_example, added array-heap_example and
441 array-stack_example and adapted makefile.
443 Entity now also allows type_method as owner. This is to model
444 the stack, Sel nodes that select a variable (array) from the
445 stack need an entity that describes what they select. This
446 entity gets the type of the enclosing procedure as owner.
449 Added future access routines in `irmode.[ch]' as comments,
450 that all attributes in the ir_mode struct can be user-defined.
451 Added access routines in `irgraph.[ch]', for all attributes.
454 Moved verify routines from `irgraph.[ch]' to own files `irvrfy.[ch]'.
455 Added `irvrfy.[ch]' to MAKEFILE
456 Added "inline" before access routines in `irnode.h', that no warnings
457 will appear furthermore.
458 Added three more access routines in `irmode.[ch]':
459 struct tarval *get_min_of_mode (ir_mode *mode);
460 struct tarval *get_max_of_mode (ir_mode *mode);
461 struct tarval *get_null_of_mode (ir_mode *mode);
464 Adaption of Alloc, Sel and Entity to new types:
465 Changed array_example to use type instead of type_class.
466 Changed entity to allow all types as owner instead of
467 only type_class. Added routine "assert_legal_owner_of_ent(type* type)".
468 Changed alloc to allow allocating variables of any type instead of
470 Adapted all testprograms to avoid warnings.
472 removed dtest ... from Makefile, replaced by test.
475 Added "run" to makefile, added array_example to makefile of testprograms.
476 Corrected testprogram array
477 Changed assert in irvrfy -- Conv.