4 * TS: Type check constraint declarations.
5 * TS: Trie stores hidden behind `experimental' option.
6 * TS: New option `verbose' prints constraint indices.
7 * TS: Don't compute term_hash for int and natural types.
11 * TS: Avoid trivial warning for declare_stored_constraints.
12 * TS: Bug fix: missing full store was causing compiler to loop.
16 * TS: Bug fix: atomic_constants store was causing compiler
18 * TS: Clean-up and avoid adding additional global_ground store
19 if atomic_constants store covers all cases.
20 * TS: Clean-up and bug fix.
24 * TS: Performance improvement: use new store
25 implementation for multi-argument lookups
26 on manifest ground terms. Should be faster than
31 * TS: Performance improvement: use new store
32 implementation for single-argument lookups
33 on manifest atomics. Should be faster than
34 hashtable. Will be generalized to arbitrary
35 manifest ground lookups and non-manifest
36 atomically typed lookups .
40 * TS: Modified error messages of declare_stored_constraints
41 option, to distinguish between stored, temporarily stored
43 * TS: write/1, writeln/1 and format/2 are now treated as non-binding
45 * TS: Properly inline inthash constraint lookup.
49 * TS: Additional assertion # default(Goal) for the
50 declare_stored_constraints, which specifies that
51 an unconditional simplification rule for the constraint
52 must be added to the end of the program. The Goal
53 parameter specifies the goal of that rule, e.g.
54 true or fail or throw(...). Experimental.
58 * TS: Experimental option declare_stored_constraints for
59 telling the compiler to warn for stored constraints
60 that are not asserted to be stored. Use the
61 :- chr_constraint f(...) # stored.
62 notation for asserting that a constraint is expected to
67 * TS: Inline constraint lookup.
69 * TS: Precompile term hashing.
73 * TS: Code cleaning was hampered by line numbers.
74 Reported by Mike Elston.
78 * PVW: Bug fix in observation analysis.
79 * PVW: Consistency checks of experimental history pragma.
83 * TS: Lessened worst bottlenecks in CHR compiler,
84 in the guard simplification phase.
88 * TS: Experimental dynattr option, for dynamic size attribute terms.
92 * TS: Extended observation analysis (abstract interpretation)
93 to deal with disjunctions. With Paolo Tacchella.
97 * TS: Renamed hprolog:substitute/4 to substitute_eq/4, because of
98 name conflict with library(edit).
102 * TS: Use line numbers in error and warning messages.
106 * TS: Added maintenance of line numbers through CHR compilation
107 as an option: chr_option(line_numbers,on).
111 * TS: Bug fix: setarg/3 instantiation error reported by Mike Elston.
112 Caused by missing suspension argument in debug off, optimize off
117 * LDK: O(1) removal from hashtables, with experimental
118 chr_option(ht_removal,on).
122 * PVW: Bugfixes for optional use of CHR constraints in rule guards.
126 * PVW: Optional use of CHR constraints in rule guards.
130 * TS: Bug fix in compiler_errors.pl.
134 * TS: Bug fix in occurrence subsumption by Jon Sneyers.
138 * TS: New preprocessor feature.
140 * TS: Parametrization of experimental chr_identifier type.
146 * TS: Stronger static type checking.
148 * TS: Omitted buggy FD analysis from bootstrapping process.
154 * TS: Experimental chr_identifier type.
158 * TS: Allow for empty type definitions aka phantom types. These are
159 useful for some type-level tricks. A warning is issued so the
160 user can check whether a phantom type is intended. No other
161 phantom type-specific checks are in place yet.
163 * TS: Fixed static type checking of built-in types.
167 * TS: The dense_int type can now appear on the rhs of type alias
172 * TS: Fixed bug concerning matchings between ground and possibly
173 non-ground arguments.
177 * TS: Fixed a bug in code generation, overeager removal of a clause.
181 * TS: Refactored some code.
185 * TS: Add exception handler to initialize chr_leash in new threads.
189 * TS: Bug fix for programs in debugging mode.
193 * JW: Fixed make clean
194 * JW: Enlarged stacks to make build succeed
198 * JW: Add target ln-install
202 * TS: Fixed wrong arities in not inlined predicates. Mike Elston.
206 * TS: Code clean-up, more inlining, only generate used imports.
210 * TS: Inlining and more specialization of auxiliary predicates.
214 * TS: Fixed bug for constraints without rules in debug mode.
216 * TS: Compiler clean-up
218 * TS: Experimental var_assoc_store.
223 * TS: Various minor code generation improvements, including smaller
228 * TS: Absolutely no lock checking when check_guard_bindings is disabled.
232 * TS: Minor optimizations for (-) arguments.
234 * TS: Important optimization for awakening fewer suspended constraints
238 * TS: Fixed typo in static type checker.
240 * TS: Documented static and dynamic type checking.
244 * TS: Fixed bug (type alias related) in static type checker. Mike Elston.
246 * TS: Added static type checking on variable matching in rule heads.
248 * TS: Added static type checking on CHR constraints in rule bodies.
252 * TS: New (limited) compile time type checking of rule heads.
256 * TS: New experimental robustness feature in debug mode:
257 runtime type checking of CHR constraints.
261 * TS: Minor bug fixes.
265 * TS: Improved performance of ai_observation_analysis,
266 mainly via additional tabling and passive declarations.
270 * TS: Disabled some code only intended for SICStus.
272 * TS: Fixed bug in removal of constraints. Spotted by Leslie De Koninck.
276 * TS: Next fix to tracer. Cconstraints in propagation
277 rules are shown in textual order.
281 * TS: Next few fixes to tracer. Constraints in simpagation rules
282 are now shown on the right side of the backslash.
286 * TS: Synchronization with SICStus version of K.U.Leuven CHR.
288 * TS: First few fixes to tracer. Cconstraints in simplification
289 rules are shown in textual order. Constraint insertions
294 * TS: Termination bug fixed in guard_entailment.
296 * TS: Runtime library predicate run_suspensions is now specialized
297 per constraint, avoiding requirement of fixed suspension layout.
299 * TS: Further update to suspension term layout. Only constraints for
300 which the propagation history is used get a history field.
304 * TS: Ignore propagation rules with trivial body 'true'.
308 * TS: Guard entailment now first simplifies the formula it processes,
309 in order to reduce the number of disjunctions, to obtain a smaller
314 * TS: Bug fix by Jon Sneyers: type aliases now support built-in types.
315 Spotted by Mike Elston.
317 * TS: Small refactorings based on Ciao port experience.
319 * TS: Removed -singleton stylecheck option now that portray_clause
320 prints singleton variables as _.
324 * JW: Make library(chr) load its private stuff silent.
328 * TS: Bug fix: too many guards were locked.
332 * TS: Most runtime library predicates are now specialized
333 per constraint, avoiding generic =.. and lists code.
335 Mayor update to suspension term layout. Layout may now
336 differ from one constraint to the other. Some unused suspension
337 fields (continuation goal and generation number) are omitted.
338 Further analysis can remove more fields.
340 Default store constraints now each have
341 their own global variable: a list of all the suspensions.
342 Removal from this list is now O(1) thanks to setarg/1 and
343 back pointers in the suspension terms. This can cause time
344 time complexity improvements in solvers that always have
345 variable indexing on their constraints.
347 Ground, non-indexed constraints are now removed from
348 their global list store in O(1), as for the default store.
350 Minor bug fixes in a number of places.
354 * TS: Fixed subtle bug in ai_observation analysis,
355 that caused goal sequences to only generate
356 the optimistic default answer pattern, leading
357 to invalid 'not observed' conclusions.
358 * TS: Variable indexing/suspension analysis now ignores functor/3
359 in guards. Could be extended to other built-ins
360 that cause an error when arguments are not
361 properly instantiated.
365 * TS: Renamed global variable id to chr_id in chr_runtime.pl.
368 * JS: Synchronization with experimental version:
369 - minor optimizations, e.g. efficient lookups with statically known
371 - new alternative syntax for passive declarations
372 - new dense_int built-in type + underlying store
373 - new type alias definitions, like in Mercury
376 * BD: small changes in chr_compiler_options.pl and chr_translate.chr
377 affecting only the SICStus port
380 * BD: lots of changes related to porting to SICStus
381 * TS: Now exception/3 hook is only used in SWI-Prolog
385 * TS: Use exception/3 hook to catch undefined
386 global variables of chr_runtime.pl and CHR modules,
387 for multi-threaded programs and saved states.
391 * JW: Fix "make check" path issues.
392 * TS: Removed all is_chr_file tests when loading file.
396 * BD: chr_swi.pl: option(optimize --> :- chr_option(optimize
397 * TS: Removed obsolete experimental optimization option.
398 * TS: Correctly report variable pragmas!
399 * TS: No constraints declared is no longer a special case.
403 * BD: chr_swi.pl - use_module(hprolog added for SICStus port
404 * TS: Removed operator declaration for '::'. No longer used.
408 * TS: Removed chr_constraints declaration again, in favor
409 of only the chr_constraint declaration and modified
410 documentation accordingly.
411 * TS: Modified documentation based on recommendations of Bart Demoen.
412 * TS: Added chr_info/3 predicate to chr_compiler_errors, as suggested by
413 Jon Sneyers. Now print banner on calling compiler.
417 * TS: warnings are now written to user_error stream.
421 * TS: option and constraints declarations are now deprecated. They
422 are replaced by chr_option and chr_constraint(s).
423 * TR: Made an interface for warnings and errors. Errors now implemented
425 * TR: Revised documentation.
428 * BD: chr_translate.chr, chr_translate_bootstrap2.chr
429 mutables "abstracted"
430 * BD: chr_translate_bootstrap1.chr
431 atomic_concat - some duplicate code of it is in more than one file :-(
432 create_get_mutable definitions if-deffed
433 verbosity_on/0 for porting
435 definitions of init_store/2, get_store/2, update_store/2
436 and of make_init_store_goal/make_get_store_goal/make_update_store_goal
437 removed prolog_flag/3 (seemed nowhere used)
438 chr_translate_bootstrap2.chr
439 make_init_store_goal/make_get_store_goal/make_update_store_goal introduced
440 verbosity_on/0 for porting
441 chr_translate_bootstrap.pl
442 atom_concat -> atomic_concat
443 verbosity_on/0 for porting
444 conditional import van library(terms)
446 make_init_store_goal etc. introduced
447 create_get_mutable_ref wherever needed (chr_translate*)
451 * BD: chr_runtime.pl:
453 included contents of chr_debug.pl
455 create_mutable changed into 'chr create_mutable'
456 got rid of explicit inlining and did it by goal expansion
457 inlining also of 'chr default_store'
459 removed :- use_module(chr(chr_debug))
460 module header: version for SICStus
461 * BD: chr_debug.pl: emptied
462 * BD: chr_translate.chr:
463 system specific declarations factored out in insert_declarations
464 changed two atom_concat/3 into atomic_concat/3 (because arg 2 was sometimes an int)
465 * BD: chr_compiler_utility.pl:
466 put atomic_concat/3 there
467 adapted atom_concat_list/2 to use it
468 * BD: chr_swi_bootstrap.pl:
469 introduced chr_swi_bootstrap/2 for ease of porting
470 exported also chr_compile/3
471 porting code for get_time stuff/read_term/absolute_file_name
472 * BD: builtins.pl, a_star.pl, clean_code.pl:
477 * BD: hprolog.pl: removed strip_attributes/2 and restore_attributes/2
480 * BD: chr_swi.pl: Removed code that took Handler for Module (in chr_expand(end_of_file)
481 Added :- chr_option(_,_) with same meaning as option(_,_)
482 is_chr_file: .chr is no longer a recognised suffix
483 added use_module(library(lists))
484 changed calls to source_location/2 into prolog_load_context/2
485 * BD: chr_translate.chr: chr_translate/2: added end_of_file to translated program
486 adapted SICStus compatibility message
487 made :- chr_option(_,_) available
488 changed precedence of + - ? to 980 (these ops are
489 probably not local enough to the module)
493 * TS: Further synchronization with hProlog.
497 * TS: Removed dead code in guard_entailment.chr
498 * TS: Fixed performance bug: now lookup is indexed
499 on maximal number of arguments.
500 * TS: Removed some redundant intermediate predicates
502 * TS: It is now possible to disable the printing
503 of the CHR constraint store per module,
504 through the option toplevel_show_store on/off
505 * TS: Synchronized with hProlog
506 * TS: bug fix in functional dependency analysis
510 * TS: Removed two dead predicates in chr_translate.chr
511 and hooked up the late_storage_analysis
512 that was being bypassed.
513 * TS: Renamed global_term_ref_1 to default_store.
514 * TS: Removed redundant predicate values_ht.
515 * TS: Compiler no longer generates dead code for never stored constraints,
516 i.e. attach/detach predicates.
517 This reduces the generated .pl by about 700 lines.
521 * TS: Two more bug fixes for constraints without
522 active occurrences that trigger.
526 * TS: Small optimization of code for constraints
527 without any active occurrence.
528 * TS: Fixed bug caused by previous bug fix:
529 added only_ground_indexed_arguments/1 test
530 to separate out that meaning from may_trigger/1.
534 * TS: Removed strip_attributes code.
535 * TS: Fixed bug that causes new constraints to be added on triggering.
539 * TS: Two minor bug fixes.
543 * TS: Fixed bug due to overly aggressive inlining of get_mutable_value.
547 * JS: Compiled code is broken, if debug is off and optimize too.
548 Debug off now entails optimize on.
550 * TS: Some fixes of the documentation. Thanks to Bart Demoen
555 * TS: Synchronized with hProlog.
559 * TS: Added missing operator declarations for prefix (?).
563 * JW: import lists into chr_compiler_utility.pl
565 * JW: make message hook for query(yes) detect CHR global variables.
567 * JW: Exported pairlist_delete_eq/3 from pairlist and use this in
568 chr_hashtable_store.pl
572 * TS: Renamed pairlist:delete/3 to pairlist:pairlist_delete/3.
576 * TS: Extended more efficient ground matching code to
577 removed simpagation occurrence code.
581 * TS: New input verification: duplicate constraint declaration
582 now reported as an error. Requested by Mike Elston.
583 * TS: More efficient matching code for ground constraints
584 when matching an argument of a partner constraint with
586 * JS: Bug fix in guard simplification.
590 * TS: Factored out option functionality into separate module.
591 * TS: Factored out utility code into separate module.
595 * TS: Changed chr_show_store/1 to use print/1 instead of write/1.
599 * TS: Removed spurious and conflicting operator definitions
600 for +, - and ? as mode declarations.
604 * TS: Added find_chr_constraint/1 functionality.
608 * TS: Improved compiler scalability: use nb_setval/2 to
609 remember compiled code through backtracking over
610 compilation process instead of assert/1.
611 * TS: Removed spurious comma from file.
615 * TS: Added option to disable toplevel constraint store printing.
616 * TS: Slightly improved hash table constraint store implementation.
620 * JW: Added patch from Jon Sneyers.
624 * TS: Improved head reordering heuristic.
625 * TS: Added support primitive for alternate built-in solver dependency.
629 * TS: Fixed bug that causes wrong output in chr_show_store.
633 * TS: Fixed several bugs in generation of debugable code.
637 * JW: Cleanup integration in SWI-Prolog environment:
638 - Extended SWI-Prolog library ordsets. Renamed ord_delete/3 to
639 ord_del_element/3 and ord_difference/3 to ord_subtract/3 for
640 better compatibility.
641 - Renamed module find to chr_find to avoid name conflict and declared
642 preds as meta-predicate.
643 - Re-inserted and exported strip_attributes/2 and
644 restore_attributes/2 in hprolog.pl. Deleted hprolog: from
646 - Added dummy option declarations to bootstrap compiler.
647 - Fixed path problems in makefile (-p chr=.) and install new
649 - Fixed typo 'chr show_store' --> chr_show_store.
653 * JS: Added guard entailment optimizations and
654 new syntax for type and mode declarations.
658 * TS: Use prolog:message/3 hook to automatically print
659 contents of CHR constraint stores with query bindings
664 * TS: Bugfix in code generation. Reported by Lyosha Ilyukhin.
668 * TS: Updated hashtable stores. They now start small and expand.
672 * JW: Removed chr_pp: module prefixes
673 * JW: Updated Windows makefile.mak (more similar organisation, added check)
677 * TS: Added chr_hashtable_store library.
678 * TS: Added find library.
679 * TS: Added builtins library.
680 * TS: Added clean_code library.
681 * TS: Added binomial_heap library.
682 * TS: Added a_star library.
683 * TS: Added new intermediate bootstrapping step
684 * TS: Synchronized CHR compiler with most recent development version
688 "The new version of the compiler contains several new optimizations, both
689 fully automatic, such as the antimonotny-based delay avoidance (see
690 http://www.cs.kuleuven.be/publicaties/rapporten/cw/CW385.abs.html for
691 the technical report), and enabled by mode declarations (see CHR
692 documentation), such as hashtable-based constraint indexes."
696 * JW: Added chr_messages.pl. Make all debug messages use the print_message/2
697 interface to enable future embedding.
701 * JW: Added chr:debug_interact/3 hook. Defined in chr_swi.pl to void
702 showing constraints first as goal and then as CHR call.
703 * JW: Added chr:debug_event/2 hook. Defined in chr_swi.pl to make the
704 CHR debugger honour a skip command from the Prolog tracer.
708 * JW: Added b (break) to the CHR debugger.
709 * TS: added chr_expandable/2 clause for pragma/2
713 * JW: fixed reference to format_rule/2.
714 * JW: Use select/3 rather than delete/3 in diff/2 in Tests/zebra.pl
715 * TS: CHR translation now leaves CHR store empty
719 * JW: added :- use_module(library(chr)) to all examples.
720 * JW: mapped -O --> option(optimize, full).
721 * JW: introduced file-search-path `chr' for clarity and to enable running
722 make check from the local environment instead of the public installation.
723 * JW: mapped prolog flag generate_debug_info --> option(debug, on)
724 * JW: Replaced the chr -> pl step with term_expansion/2.
725 * JW: Moved insert_declarations/2 to chr_swi.pl
729 * JW: fixed Undefined procedure: chr_runtime:run_suspensions_loop_d/1
730 * TS: Added <space> for creep and shortened debug line prefix to CHR:
734 * JW: Use \+ \+ in chr_compile/3 to undo changes to the constraint
735 pool. Regression test suite using "make check" works again.
739 * TS: Added skip and ancestor debug commands
743 * TS: Added bootstrapping process for CHR compiler using CHR.
744 * TS: CHR compiler now uses CHR.
745 * TS: Fixed bug in compilation of multi-headed simpagation rules.
746 * TS: Cleaned up compiler.
747 * TS: Added analysis + optimization for never attached constraints.
748 * TS: Exploit uniqueness (functional dependency) results to detect
749 set semantics type simpagation rules where one rule can be passive
750 * TS: Compiler generates 'chr debug_event'/1 calls
751 * TS: Rudimentary support for debugging.
752 option(debug,on) causes a trace of CHR events to be printed
756 * JW: Fix operator handling.
760 * JW: Integrated new version from Tom Schrijvers.