[m-rev.] diff: add two string hash functions

Zoltan Somogyi zs at csse.unimelb.edu.au
Fri Nov 12 13:21:07 AEDT 2010


Until now, all hash tables on strings used a single standard hash function.
However, any single hash function has a pretty good probability of generating
collisions on small hash tables.

This diff adds two new hash functions on strings. When generating hash tables,
we now try out all three hash functions, and use the one that generates
the fewest collisions.

runtime/mercury_string.h:
	Add C implementations of the new hash functions.

library/string.m:
	Add Mercury implementations of the new hash functions.

compiler/builtin_ops.m:
	Add the new hash functions as builtin operations.

compiler/switch_util.m:
	Select the best hash function for each hash switch on strings.

compiler/ml_string_switch.m:
compiler/string_switch.m:
	Use the selected hash function for each hash table.

compiler/bytecode.m:
compiler/c_util.m:
compiler/java_util.m:
compiler/llds.m:
compiler/llds_tox86_64.m:
compiler/mlds_to_gcc.m:
compiler/mlds_to_il.m:
compiler/opt_debumlds_to_ilg.m:
	Conform to the presence of the new hash functions.

Zoltan.

cvs diff: Diffing .
cvs diff: Diffing analysis
cvs diff: Diffing bindist
cvs diff: Diffing boehm_gc
cvs diff: Diffing boehm_gc/Mac_files
cvs diff: Diffing boehm_gc/cord
cvs diff: Diffing boehm_gc/cord/private
cvs diff: Diffing boehm_gc/doc
cvs diff: Diffing boehm_gc/extra
cvs diff: Diffing boehm_gc/include
cvs diff: Diffing boehm_gc/include/extra
cvs diff: Diffing boehm_gc/include/private
cvs diff: Diffing boehm_gc/libatomic_ops
cvs diff: Diffing boehm_gc/libatomic_ops/doc
cvs diff: Diffing boehm_gc/libatomic_ops/src
cvs diff: Diffing boehm_gc/libatomic_ops/src/atomic_ops
cvs diff: Diffing boehm_gc/libatomic_ops/src/atomic_ops/sysdeps
cvs diff: Diffing boehm_gc/libatomic_ops/src/atomic_ops/sysdeps/armcc
cvs diff: Diffing boehm_gc/libatomic_ops/src/atomic_ops/sysdeps/gcc
cvs diff: Diffing boehm_gc/libatomic_ops/src/atomic_ops/sysdeps/hpc
cvs diff: Diffing boehm_gc/libatomic_ops/src/atomic_ops/sysdeps/ibmc
cvs diff: Diffing boehm_gc/libatomic_ops/src/atomic_ops/sysdeps/icc
cvs diff: Diffing boehm_gc/libatomic_ops/src/atomic_ops/sysdeps/msftc
cvs diff: Diffing boehm_gc/libatomic_ops/src/atomic_ops/sysdeps/sunc
cvs diff: Diffing boehm_gc/libatomic_ops/tests
cvs diff: Diffing boehm_gc/libatomic_ops-1.2
cvs diff: Diffing boehm_gc/libatomic_ops-1.2/doc
cvs diff: Diffing boehm_gc/libatomic_ops-1.2/src
cvs diff: Diffing boehm_gc/libatomic_ops-1.2/src/atomic_ops
cvs diff: Diffing boehm_gc/libatomic_ops-1.2/src/atomic_ops/sysdeps
cvs diff: Diffing boehm_gc/libatomic_ops-1.2/tests
cvs diff: Diffing boehm_gc/m4
cvs diff: Diffing boehm_gc/tests
cvs diff: Diffing browser
cvs diff: Diffing bytecode
cvs diff: Diffing compiler
Index: compiler/builtin_ops.m
===================================================================
RCS file: /home/mercury/mercury1/repository/mercury/compiler/builtin_ops.m,v
retrieving revision 1.32
diff -u -b -r1.32 builtin_ops.m
--- compiler/builtin_ops.m	1 Nov 2010 04:02:54 -0000	1.32
+++ compiler/builtin_ops.m	2 Nov 2010 06:34:12 -0000
@@ -35,9 +35,11 @@
     ;       strip_tag
     ;       mkbody
     ;       unmkbody
-    ;       hash_string
     ;       bitwise_complement
-    ;       logical_not.
+    ;       logical_not
+    ;       hash_string
+    ;       hash_string2
+    ;       hash_string3.
 
 :- type binary_op
     --->    int_add
Index: compiler/bytecode.m
===================================================================
RCS file: /home/mercury/mercury1/repository/mercury/compiler/bytecode.m,v
retrieving revision 1.76
diff -u -b -r1.76 bytecode.m
--- compiler/bytecode.m	1 Nov 2010 04:02:54 -0000	1.76
+++ compiler/bytecode.m	2 Nov 2010 06:34:16 -0000
@@ -1122,9 +1122,11 @@
 unop_code(mkbody,               3).
 unop_code(unmkbody,             4).
 unop_code(strip_tag,            5).
-unop_code(hash_string,          6).
-unop_code(bitwise_complement,   7).
-unop_code(logical_not,          8).
+unop_code(bitwise_complement,   6).
+unop_code(logical_not,          7).
+unop_code(hash_string,          8).
+unop_code(hash_string2,         9).
+unop_code(hash_string3,        10).
 
 :- pred unop_debug(unary_op::in, string::out) is det.
 
@@ -1134,9 +1136,11 @@
 unop_debug(mkbody,              "mkbody").
 unop_debug(unmkbody,            "unmkbody").
 unop_debug(strip_tag,           "strip_tag").
-unop_debug(hash_string,         "hash_string").
 unop_debug(bitwise_complement,  "bitwise_complement").
 unop_debug(logical_not,         "not").
+unop_debug(hash_string,         "hash_string").
+unop_debug(hash_string2,        "hash_string2").
+unop_debug(hash_string3,        "hash_string3").
 
 %---------------------------------------------------------------------------%
 
Index: compiler/c_util.m
===================================================================
RCS file: /home/mercury/mercury1/repository/mercury/compiler/c_util.m,v
retrieving revision 1.47
diff -u -b -r1.47 c_util.m
--- compiler/c_util.m	1 Nov 2010 04:02:54 -0000	1.47
+++ compiler/c_util.m	2 Nov 2010 06:34:19 -0000
@@ -544,9 +544,11 @@
 unary_prefix_op(strip_tag,          "MR_strip_tag").
 unary_prefix_op(mkbody,             "MR_mkbody").
 unary_prefix_op(unmkbody,           "MR_unmkbody").
-unary_prefix_op(hash_string,        "MR_hash_string").
 unary_prefix_op(bitwise_complement, "~").
 unary_prefix_op(logical_not,        "!").
+unary_prefix_op(hash_string,        "MR_hash_string").
+unary_prefix_op(hash_string2,       "MR_hash_string2").
+unary_prefix_op(hash_string3,       "MR_hash_string3").
 
 % The operator strings for array_index, compound_lt and compound_eq are
 % dummies; they should never be used.
Index: compiler/java_util.m
===================================================================
RCS file: /home/mercury/mercury1/repository/mercury/compiler/java_util.m,v
retrieving revision 1.22
diff -u -b -r1.22 java_util.m
--- compiler/java_util.m	11 May 2009 04:56:45 -0000	1.22
+++ compiler/java_util.m	2 Nov 2010 06:34:22 -0000
@@ -69,10 +69,12 @@
 java_unary_prefix_op(strip_tag,       "/* strip_tag */ ").
 java_unary_prefix_op(mkbody,          "/* mkbody */ ").
 java_unary_prefix_op(unmkbody,        "/* unmkbody */ ").
-java_unary_prefix_op(hash_string,     "mercury.String.hash_1_f_0").
 java_unary_prefix_op(bitwise_complement,  "~").
 java_unary_prefix_op(logical_not,      "!").
 java_unary_prefix_op(tag, "").    % This case is never used.
+java_unary_prefix_op(hash_string,     "mercury.String.hash_1_f_0").
+java_unary_prefix_op(hash_string2,    "mercury.String.hash2_1_f_0").
+java_unary_prefix_op(hash_string3,    "mercury.String.hash3_1_f_0").
 
 java_string_compare_op(str_eq, "==").
 java_string_compare_op(str_ne, "!=").
Index: compiler/llds.m
===================================================================
RCS file: /home/mercury/mercury1/repository/mercury/compiler/llds.m,v
retrieving revision 1.367
diff -u -b -r1.367 llds.m
--- compiler/llds.m	1 Nov 2010 04:02:56 -0000	1.367
+++ compiler/llds.m	2 Nov 2010 06:34:25 -0000
@@ -1559,9 +1559,11 @@
 unop_return_type(strip_tag, lt_word).
 unop_return_type(mkbody, lt_word).
 unop_return_type(unmkbody, lt_word).
-unop_return_type(hash_string, lt_integer).
 unop_return_type(bitwise_complement, lt_integer).
 unop_return_type(logical_not, lt_bool).
+unop_return_type(hash_string, lt_integer).
+unop_return_type(hash_string2, lt_integer).
+unop_return_type(hash_string3, lt_integer).
 
 unop_arg_type(mktag, lt_word).
 unop_arg_type(tag, lt_word).
@@ -1569,9 +1571,11 @@
 unop_arg_type(strip_tag, lt_word).
 unop_arg_type(mkbody, lt_word).
 unop_arg_type(unmkbody, lt_word).
-unop_arg_type(hash_string, lt_string).
 unop_arg_type(bitwise_complement, lt_integer).
 unop_arg_type(logical_not, lt_bool).
+unop_arg_type(hash_string, lt_string).
+unop_arg_type(hash_string2, lt_string).
+unop_arg_type(hash_string3, lt_string).
 
 binop_return_type(int_add, lt_integer).
 binop_return_type(int_sub, lt_integer).
Index: compiler/llds_to_x86_64.m
===================================================================
RCS file: /home/mercury/mercury1/repository/mercury/compiler/llds_to_x86_64.m,v
retrieving revision 1.14
diff -u -b -r1.14 llds_to_x86_64.m
--- compiler/llds_to_x86_64.m	1 Nov 2010 04:02:56 -0000	1.14
+++ compiler/llds_to_x86_64.m	2 Nov 2010 06:34:28 -0000
@@ -819,7 +819,6 @@
 unop_instrs(strip_tag, _, _, [x86_64_comment("<<strip_tag>>")]).
 unop_instrs(mkbody, _, _, [x86_64_comment("<<mkbody>>")]).
 unop_instrs(unmkbody, _, _, [x86_64_comment("<<unmkbody>>")]).
-unop_instrs(hash_string, _, _, [x86_64_comment("<<hash_string>>")]).
 unop_instrs(bitwise_complement, Op, Instrs0, Instrs) :-
     (
         Op = yes(OpRes),
@@ -838,6 +837,9 @@
         )
     ).
 unop_instrs(logical_not, _, _, [x86_64_comment("<<logical_not>>")]).
+unop_instrs(hash_string, _, _, [x86_64_comment("<<hash_string>>")]).
+unop_instrs(hash_string2, _, _, [x86_64_comment("<<hash_string2>>")]).
+unop_instrs(hash_string3, _, _, [x86_64_comment("<<hash_string3>>")]).
 
     % Equivalent x86_64 instructions for a binary operation.
     %
Index: compiler/ml_string_switch.m
===================================================================
RCS file: /home/mercury/mercury1/repository/mercury/compiler/ml_string_switch.m,v
retrieving revision 1.45
diff -u -b -r1.45 ml_string_switch.m
--- compiler/ml_string_switch.m	1 Nov 2010 04:02:57 -0000	1.45
+++ compiler/ml_string_switch.m	2 Nov 2010 06:49:01 -0000
@@ -107,7 +107,7 @@
     % Compute the hash table.
     construct_string_hash_jump_cases(Cases, TableSize, HashMask,
         gen_tagged_case_code_for_string_switch(CodeModel),
-        map.init, CodeMap, unit, _, !Info, HashSlotsMap),
+        map.init, CodeMap, unit, _, !Info, HashSlotsMap, HashOp),
 
     % Generate the code for when the hash lookup fails.
     (
@@ -220,7 +220,7 @@
         statement(
             ml_stmt_atomic(assign(SlotVarLval,
                 ml_binop(bitwise_and,
-                    ml_unop(std_unop(hash_string), VarRval),
+                    ml_unop(std_unop(HashOp), VarRval),
                     ml_const(mlconst_int(HashMask))))),
             MLDS_Context),
         statement(ml_stmt_atomic(comment("hash chain loop")), MLDS_Context),
Index: compiler/mlds_to_gcc.m
===================================================================
RCS file: /home/mercury/mercury1/repository/mercury/compiler/mlds_to_gcc.m,v
retrieving revision 1.153
diff -u -b -r1.153 mlds_to_gcc.m
--- compiler/mlds_to_gcc.m	1 Nov 2010 04:02:57 -0000	1.153
+++ compiler/mlds_to_gcc.m	2 Nov 2010 06:34:32 -0000
@@ -3433,6 +3433,13 @@
         gcc.build_binop(gcc.bit_and_expr, 'MR_intptr_t',
             Arg, InvertedMask, Expr, !IO)
     ;
+        Unop = bitwise_complement,
+        gcc.build_unop(gcc.bit_not_expr, 'MR_Integer', Arg, Expr, !IO)
+    ;
+        Unop = logical_not,
+        gcc.build_unop(gcc.truth_not_expr, gcc.boolean_type_node,
+            Arg, Expr, !IO)
+    ;
         Unop = hash_string,
         gcc.build_func_addr_expr(gcc.hash_string_func_decl,
             HashStringFuncExpr, !IO),
@@ -3442,12 +3449,10 @@
         gcc.build_call_expr(HashStringFuncExpr, GCC_ArgList, IsTailCall,
             Expr, !IO)
     ;
-        Unop = bitwise_complement,
-        gcc.build_unop(gcc.bit_not_expr, 'MR_Integer', Arg, Expr, !IO)
-    ;
-        Unop = logical_not,
-        gcc.build_unop(gcc.truth_not_expr, gcc.boolean_type_node,
-            Arg, Expr, !IO)
+        ( Unop = hash_string2
+        ; Unop = hash_string3
+        ),
+        unexpected(this_file, "build_unop_expr: hash_string2/3")
     ).
 
 :- pred build_std_binop(builtin_ops.binary_op::in,
Index: compiler/mlds_to_il.m
===================================================================
RCS file: /home/mercury/mercury1/repository/mercury/compiler/mlds_to_il.m,v
retrieving revision 1.217
diff -u -b -r1.217 mlds_to_il.m
--- compiler/mlds_to_il.m	1 Nov 2010 04:02:57 -0000	1.217
+++ compiler/mlds_to_il.m	2 Nov 2010 06:34:35 -0000
@@ -2517,14 +2517,18 @@
 unaryop_to_il(std_unop(mkbody), _, comment_node("mkbody (a no-op)"), !Info).
 unaryop_to_il(std_unop(unmkbody), _, comment_node("unmkbody (a no-op)"),
         !Info).
-unaryop_to_il(std_unop(hash_string), _,
-        singleton(call(il_mercury_string_hash)), !Info).
 unaryop_to_il(std_unop(bitwise_complement), _, singleton(bitwise_not), !Info).
 
     % Might want to revisit this and define not to be only valid on 1 or 0,
     % then we can use ldc.i4.1 and xor, which might be more efficient.
 unaryop_to_il(std_unop(logical_not), _,
         from_list([ldc(int32, i(1)), clt(unsigned)]), !Info).
+unaryop_to_il(std_unop(hash_string), _,
+        singleton(call(il_mercury_string_hash)), !Info).
+unaryop_to_il(std_unop(hash_string2), _, _, !Info) :-
+    unexpected(this_file, "unaryop_to_il: hash_string2").
+unaryop_to_il(std_unop(hash_string3), _, _, !Info) :-
+    unexpected(this_file, "unaryop_to_il: hash_string3").
 
     % XXX Should detect casts to System.Array from array types
     % and ignore them, as they are not necessary.
Index: compiler/opt_debug.m
===================================================================
RCS file: /home/mercury/mercury1/repository/mercury/compiler/opt_debug.m,v
retrieving revision 1.215
diff -u -b -r1.215 opt_debug.m
--- compiler/opt_debug.m	1 Nov 2010 04:02:57 -0000	1.215
+++ compiler/opt_debug.m	2 Nov 2010 06:34:39 -0000
@@ -628,8 +628,10 @@
 dump_unop(mkbody) = "mkbody".
 dump_unop(unmkbody) = "unmkbody".
 dump_unop(logical_not) = "not".
-dump_unop(hash_string) = "hash_string".
 dump_unop(bitwise_complement) = "bitwise_complement".
+dump_unop(hash_string) = "hash_string".
+dump_unop(hash_string2) = "hash_string2".
+dump_unop(hash_string3) = "hash_string3".
 
 dump_binop(array_index(_)) = "array_index".
 dump_binop(compound_lt) = "compound<".
Index: compiler/string_switch.m
===================================================================
RCS file: /home/mercury/mercury1/repository/mercury/compiler/string_switch.m,v
retrieving revision 1.67
diff -u -b -r1.67 string_switch.m
--- compiler/string_switch.m	1 Nov 2010 04:02:59 -0000	1.67
+++ compiler/string_switch.m	9 Nov 2010 04:37:05 -0000
@@ -120,7 +120,7 @@
     map.init(CaseLabelMap0),
     construct_string_hash_jump_cases(Cases, TableSize, HashMask,
         represent_tagged_case_for_llds(Params),
-        CaseLabelMap0, CaseLabelMap, no, MaybeEnd, !CI, HashSlotsMap),
+        CaseLabelMap0, CaseLabelMap, no, MaybeEnd, !CI, HashSlotsMap, HashOp),
 
     % Generate the data structures for the hash table.
     FailLabel = HashSwitchInfo ^ shsi_fail_label,
@@ -144,7 +144,8 @@
     ]),
 
     generate_string_hash_switch_search(HashSwitchInfo, VarRval, TableAddrRval,
-        ArrayElemType, HashMask, NumColumns, MatchCode, HashLookupCode),
+        ArrayElemType, NumColumns, HashOp, HashMask, MatchCode,
+        HashLookupCode),
 
     % Generate the code for the cases.
     map.foldl(add_remaining_case, CaseLabelMap, empty, CasesCode),
@@ -239,7 +240,7 @@
 
     % Compute the hash table.
     construct_string_hash_lookup_cases(CaseValues, TableSize, HashMask,
-        HashSlotsMap),
+        HashSlotsMap, HashOp),
 
     % Generate the static lookup table for this switch.
     DummyOutRvals = list.map(default_value_for_type, OutTypes),
@@ -293,7 +294,7 @@
     ),
     MatchCode = SetBaseRegCode ++ BranchEndCode ++ GotoEndLabelCode,
     generate_string_hash_switch_search(HashSwitchInfo,
-        VarRval, VectorAddrRval, ArrayElemType, HashMask, NumColumns,
+        VarRval, VectorAddrRval, ArrayElemType, NumColumns, HashOp, HashMask,
         MatchCode, HashSearchCode),
 
     EndLabelCode = singleton(
@@ -379,7 +380,7 @@
 
     % Compute the hash table.
     construct_string_hash_lookup_cases(CaseSolns, TableSize, HashMask,
-        HashSlotsMap),
+        HashSlotsMap, HashOp),
 
     % Generate the static lookup table for this switch.
     InitLaterSolnRowNumber = 1,
@@ -425,8 +426,8 @@
     MatchCode = SetBaseRegCode ++ LookupResultsCode,
 
     generate_string_hash_switch_search(HashSwitchInfo,
-        VarRval, MainVectorAddrRval, ArrayElemType, HashMask, NumColumns,
-        MatchCode, HashSearchCode),
+        VarRval, MainVectorAddrRval, ArrayElemType, NumColumns,
+        HashOp, HashMask, MatchCode, HashSearchCode),
     EndLabelCode = singleton(
         llds_instr(label(EndLabel),
             "end of simple hash string lookup switch")
@@ -538,11 +539,11 @@
         LoopStartLabel, NoMatchLabel, FailLabel, BranchStart, FailCode).
 
 :- pred generate_string_hash_switch_search(string_hash_switch_info::in,
-    rval::in, rval::in, array_elem_type::in, int::in, int::in,
+    rval::in, rval::in, array_elem_type::in, int::in, unary_op::in, int::in,
     llds_code::in, llds_code::out) is det.
 
 generate_string_hash_switch_search(Info, VarRval, TableAddrRval,
-        ArrayElemType, HashMask, NumColumns, MatchCode, Code) :-
+        ArrayElemType, NumColumns, HashOp, HashMask, MatchCode, Code) :-
     SlotReg = Info ^ shsi_slot_reg,
     RowStartReg = Info ^ shsi_row_start_reg,
     StringReg = Info ^ shsi_string_reg,
@@ -553,7 +554,7 @@
 
     Code = from_list([
         llds_instr(assign(SlotReg,
-            binop(bitwise_and, unop(hash_string, VarRval),
+            binop(bitwise_and, unop(HashOp, VarRval),
                 const(llconst_int(HashMask)))),
             "compute the hash value of the input string"),
         llds_instr(label(LoopStartLabel),
Index: compiler/switch_util.m
===================================================================
RCS file: /home/mercury/mercury1/repository/mercury/compiler/switch_util.m,v
retrieving revision 1.47
diff -u -b -r1.47 switch_util.m
--- compiler/switch_util.m	1 Nov 2010 04:02:59 -0000	1.47
+++ compiler/switch_util.m	2 Nov 2010 07:03:46 -0000
@@ -18,6 +18,7 @@
 :- interface.
 
 :- import_module backend_libs.rtti.         % for sectag_locn
+:- import_module backend_libs.builtin_ops.
 :- import_module hlds.
 :- import_module hlds.code_model.
 :- import_module hlds.hlds_data.
@@ -188,13 +189,14 @@
     pred(tagged_case, CaseRep, StateA, StateA, StateB, StateB, StateC, StateC)
         ::in(pred(in, out, in, out, in, out, in, out) is det),
     StateA::in, StateA::out, StateB::in, StateB::out, StateC::in, StateC::out,
-    map(int, string_hash_slot(CaseRep))::out) is det.
+    map(int, string_hash_slot(CaseRep))::out, unary_op::out) is det.
 
     % For a string lookup switch, compute the hash value for each string,
     % and store the associated data in a map from the hash values.
     %
 :- pred construct_string_hash_lookup_cases(assoc_list(string, CaseRep)::in,
-    int::in, int::in, map(int, string_hash_slot(CaseRep))::out) is det.
+    int::in, int::in, map(int, string_hash_slot(CaseRep))::out, unary_op::out)
+    is det.
 
 %-----------------------------------------------------------------------------%
 %
@@ -738,9 +740,25 @@
 %
 
 construct_string_hash_jump_cases(TaggedCases, TableSize, HashMask,
-        RepresentCase, !StateA, !StateB, !StateC, HashSlotsMap) :-
+        RepresentCase, !StateA, !StateB, !StateC, HashSlotsMap, HashOp) :-
     string_hash_jump_cases(TaggedCases, HashMask, RepresentCase,
-        !StateA, !StateB, !StateC, map.init, HashValsMap),
+        !StateA, !StateB, !StateC,
+        map.init, HashValsMap1, map.init, HashValsMap2, map.init, HashValsMap3,
+        0, NumCollisions1, 0, NumCollisions2, 0, NumCollisions3),
+    trace [compiletime(flag("hashcollisions")), io(!IO)] (
+        io.format("string jump hash collisions: %d %d %d\n",
+            [i(NumCollisions1), i(NumCollisions2), i(NumCollisions3)], !IO)
+    ),
+    ( NumCollisions1 =< NumCollisions2, NumCollisions1 =< NumCollisions3 ->
+        HashValsMap = HashValsMap1,
+        HashOp = hash_string
+    ; NumCollisions2 =< NumCollisions3 ->
+        HashValsMap = HashValsMap2,
+        HashOp = hash_string2
+    ;
+        HashValsMap = HashValsMap3,
+        HashOp = hash_string3
+    ),
     map.to_assoc_list(HashValsMap, HashValsList),
     calc_string_hash_slots(TableSize, HashValsList, HashValsMap, HashSlotsMap).
 
@@ -749,61 +767,135 @@
         ::in(pred(in, out, in, out, in, out, in, out) is det),
     StateA::in, StateA::out, StateB::in, StateB::out, StateC::in, StateC::out,
     map(int, assoc_list(string, CaseRep))::in,
-    map(int, assoc_list(string, CaseRep))::out) is det.
+    map(int, assoc_list(string, CaseRep))::out,
+    map(int, assoc_list(string, CaseRep))::in,
+    map(int, assoc_list(string, CaseRep))::out,
+    map(int, assoc_list(string, CaseRep))::in,
+    map(int, assoc_list(string, CaseRep))::out,
+    int::in, int::out, int::in, int::out, int::in, int::out) is det.
 
-string_hash_jump_cases([], _, _, !StateA, !StateB, !StateC, !HashMap).
+string_hash_jump_cases([], _, _,
+        !StateA, !StateB, !StateC, !HashMap1, !HashMap2, !HashMap3,
+        !NumCollisions1, !NumCollisions2, !NumCollisions3).
 string_hash_jump_cases([TaggedCase | TaggedCases], HashMask, RepresentCase,
-        !StateA, !StateB, !StateC, !HashMap) :-
+        !StateA, !StateB, !StateC, !HashMap1, !HashMap2, !HashMap3,
+        !NumCollisions1, !NumCollisions2, !NumCollisions3) :-
     RepresentCase(TaggedCase, CaseRep, !StateA, !StateB, !StateC),
     TaggedCase = tagged_case(MainTaggedConsId, OtherTaggedConsIds, _, _),
-    string_hash_cons_id(CaseRep, HashMask, MainTaggedConsId, !HashMap),
-    list.foldl(string_hash_cons_id(CaseRep, HashMask), OtherTaggedConsIds,
-        !HashMap),
+    string_hash_cons_id(CaseRep, HashMask, MainTaggedConsId,
+        !HashMap1, !HashMap2, !HashMap3,
+        !NumCollisions1, !NumCollisions2, !NumCollisions3),
+    list.foldl6(string_hash_cons_id(CaseRep, HashMask), OtherTaggedConsIds,
+        !HashMap1, !HashMap2, !HashMap3,
+        !NumCollisions1, !NumCollisions2, !NumCollisions3),
     string_hash_jump_cases(TaggedCases, HashMask, RepresentCase,
-        !StateA, !StateB, !StateC, !HashMap).
+        !StateA, !StateB, !StateC, !HashMap1, !HashMap2, !HashMap3,
+        !NumCollisions1, !NumCollisions2, !NumCollisions3).
 
 :- pred string_hash_cons_id(CaseRep::in, int::in, tagged_cons_id::in,
     map(int, assoc_list(string, CaseRep))::in,
-    map(int, assoc_list(string, CaseRep))::out) is det.
+    map(int, assoc_list(string, CaseRep))::out,
+    map(int, assoc_list(string, CaseRep))::in,
+    map(int, assoc_list(string, CaseRep))::out,
+    map(int, assoc_list(string, CaseRep))::in,
+    map(int, assoc_list(string, CaseRep))::out,
+    int::in, int::out, int::in, int::out, int::in, int::out) is det.
 
-string_hash_cons_id(CaseRep, HashMask, TaggedConsId, !HashMap) :-
+string_hash_cons_id(CaseRep, HashMask, TaggedConsId,
+        !HashMap1, !HashMap2, !HashMap3,
+        !NumCollisions1, !NumCollisions2, !NumCollisions3) :-
     TaggedConsId = tagged_cons_id(_ConsId, Tag),
     ( Tag = string_tag(StringPrime) ->
         String = StringPrime
     ;
         unexpected(this_file, "string_hash_cases: non-string case?")
     ),
-    string.hash(String, StringHashVal),
-    HashVal = StringHashVal /\ HashMask,
-    ( map.search(!.HashMap, HashVal, OldStringCaseReps) ->
-        svmap.det_update(HashVal, [String - CaseRep | OldStringCaseReps],
-            !HashMap)
+    StringCaseRep = String - CaseRep,
+    HashVal1 = string.hash(String) /\ HashMask,
+    HashVal2 = string.hash2(String) /\ HashMask,
+    HashVal3 = string.hash3(String) /\ HashMask,
+    ( map.search(!.HashMap1, HashVal1, OldEntries1) ->
+        svmap.det_update(HashVal1, [StringCaseRep | OldEntries1], !HashMap1),
+        !:NumCollisions1 = !.NumCollisions1 + 1
+    ;
+        svmap.det_insert(HashVal1, [StringCaseRep], !HashMap1)
+    ),
+    ( map.search(!.HashMap2, HashVal2, OldEntries2) ->
+        svmap.det_update(HashVal2, [StringCaseRep | OldEntries2], !HashMap2),
+        !:NumCollisions2 = !.NumCollisions2 + 1
+    ;
+        svmap.det_insert(HashVal2, [StringCaseRep], !HashMap2)
+    ),
+    ( map.search(!.HashMap3, HashVal3, OldEntries3) ->
+        svmap.det_update(HashVal3, [StringCaseRep | OldEntries3], !HashMap3),
+        !:NumCollisions3 = !.NumCollisions3 + 1
     ;
-        svmap.det_insert(HashVal, [String - CaseRep], !HashMap)
+        svmap.det_insert(HashVal3, [StringCaseRep], !HashMap3)
     ).
 
 %-----------------------------------------------------------------------------%
 
 construct_string_hash_lookup_cases(StrsDatas, TableSize, HashMask,
-        HashSlotsMap) :-
-    string_hash_lookup_cases(StrsDatas, HashMask, map.init, HashValsMap),
+        HashSlotsMap, HashOp) :-
+    string_hash_lookup_cases(StrsDatas, HashMask,
+        map.init, HashValsMap1, map.init, HashValsMap2, map.init, HashValsMap3,
+        0, NumCollisions1, 0, NumCollisions2, 0, NumCollisions3),
+    trace [compiletime(flag("hash_collisions")), io(!IO)] (
+        io.format("string lookup hash collisions: %d %d %d\n",
+            [i(NumCollisions1), i(NumCollisions2), i(NumCollisions3)], !IO)
+    ),
+    ( NumCollisions1 =< NumCollisions2, NumCollisions1 =< NumCollisions3 ->
+        HashValsMap = HashValsMap1,
+        HashOp = hash_string
+    ; NumCollisions2 =< NumCollisions3 ->
+        HashValsMap = HashValsMap2,
+        HashOp = hash_string2
+    ;
+        HashValsMap = HashValsMap3,
+        HashOp = hash_string3
+    ),
     map.to_assoc_list(HashValsMap, HashValsList),
     calc_string_hash_slots(TableSize, HashValsList, HashValsMap, HashSlotsMap).
 
 :- pred string_hash_lookup_cases(assoc_list(string, CaseRep)::in, int::in,
     map(int, assoc_list(string, CaseRep))::in,
-    map(int, assoc_list(string, CaseRep))::out) is det.
+    map(int, assoc_list(string, CaseRep))::out,
+    map(int, assoc_list(string, CaseRep))::in,
+    map(int, assoc_list(string, CaseRep))::out,
+    map(int, assoc_list(string, CaseRep))::in,
+    map(int, assoc_list(string, CaseRep))::out,
+    int::in, int::out, int::in, int::out, int::in, int::out) is det.
 
-string_hash_lookup_cases([], _, !HashMap).
-string_hash_lookup_cases([Str - Data | StrsDatas], HashMask, !HashMap) :-
-    string.hash(Str, StringHashVal),
-    HashVal = StringHashVal /\ HashMask,
-    ( map.search(!.HashMap, HashVal, OldStringDatas) ->
-        svmap.det_update(HashVal, [Str - Data | OldStringDatas], !HashMap)
-    ;
-        svmap.det_insert(HashVal, [Str - Data], !HashMap)
-    ),
-    string_hash_lookup_cases(StrsDatas, HashMask, !HashMap).
+string_hash_lookup_cases([], _, !HashMap1, !HashMap2, !HashMap3,
+        !NumCollisions1, !NumCollisions2, !NumCollisions3).
+string_hash_lookup_cases([StrData | StrsDatas], HashMask,
+        !HashMap1, !HashMap2, !HashMap3,
+        !NumCollisions1, !NumCollisions2, !NumCollisions3) :-
+    StrData = Str - _Data,
+    HashVal1 = string.hash(Str) /\ HashMask,
+    HashVal2 = string.hash(Str) /\ HashMask,
+    HashVal3 = string.hash(Str) /\ HashMask,
+    ( map.search(!.HashMap1, HashVal1, OldEntries1) ->
+        svmap.det_update(HashVal1, [StrData | OldEntries1], !HashMap1),
+        !:NumCollisions1 = !.NumCollisions1 + 1
+    ;
+        svmap.det_insert(HashVal1, [StrData], !HashMap1)
+    ),
+    ( map.search(!.HashMap2, HashVal2, OldEntries2) ->
+        svmap.det_update(HashVal2, [StrData | OldEntries2], !HashMap2),
+        !:NumCollisions2 = !.NumCollisions2 + 1
+    ;
+        svmap.det_insert(HashVal2, [StrData], !HashMap2)
+    ),
+    ( map.search(!.HashMap3, HashVal3, OldEntries3) ->
+        svmap.det_update(HashVal3, [StrData | OldEntries3], !HashMap3),
+        !:NumCollisions3 = !.NumCollisions3 + 1
+    ;
+        svmap.det_insert(HashVal3, [StrData], !HashMap3)
+    ),
+    string_hash_lookup_cases(StrsDatas, HashMask,
+        !HashMap1, !HashMap2, !HashMap3,
+        !NumCollisions1, !NumCollisions2, !NumCollisions3).
 
 %-----------------------------------------------------------------------------%
 
cvs diff: Diffing compiler/notes
cvs diff: Diffing deep_profiler
cvs diff: Diffing deep_profiler/notes
cvs diff: Diffing doc
cvs diff: Diffing extras
cvs diff: Diffing extras/base64
cvs diff: Diffing extras/cgi
cvs diff: Diffing extras/complex_numbers
cvs diff: Diffing extras/complex_numbers/samples
cvs diff: Diffing extras/complex_numbers/tests
cvs diff: Diffing extras/concurrency
cvs diff: Diffing extras/curs
cvs diff: Diffing extras/curs/samples
cvs diff: Diffing extras/curses
cvs diff: Diffing extras/curses/sample
cvs diff: Diffing extras/dynamic_linking
cvs diff: Diffing extras/error
cvs diff: Diffing extras/fixed
cvs diff: Diffing extras/gator
cvs diff: Diffing extras/gator/generations
cvs diff: Diffing extras/gator/generations/1
cvs diff: Diffing extras/graphics
cvs diff: Diffing extras/graphics/easyx
cvs diff: Diffing extras/graphics/easyx/samples
cvs diff: Diffing extras/graphics/mercury_allegro
cvs diff: Diffing extras/graphics/mercury_allegro/examples
cvs diff: Diffing extras/graphics/mercury_allegro/samples
cvs diff: Diffing extras/graphics/mercury_allegro/samples/demo
cvs diff: Diffing extras/graphics/mercury_allegro/samples/mandel
cvs diff: Diffing extras/graphics/mercury_allegro/samples/pendulum2
cvs diff: Diffing extras/graphics/mercury_allegro/samples/speed
cvs diff: Diffing extras/graphics/mercury_cairo
cvs diff: Diffing extras/graphics/mercury_cairo/samples
cvs diff: Diffing extras/graphics/mercury_cairo/samples/data
cvs diff: Diffing extras/graphics/mercury_cairo/tutorial
cvs diff: Diffing extras/graphics/mercury_glut
cvs diff: Diffing extras/graphics/mercury_opengl
cvs diff: Diffing extras/graphics/mercury_tcltk
cvs diff: Diffing extras/graphics/samples
cvs diff: Diffing extras/graphics/samples/calc
cvs diff: Diffing extras/graphics/samples/gears
cvs diff: Diffing extras/graphics/samples/maze
cvs diff: Diffing extras/graphics/samples/pent
cvs diff: Diffing extras/lazy_evaluation
cvs diff: Diffing extras/lex
cvs diff: Diffing extras/lex/samples
cvs diff: Diffing extras/lex/tests
cvs diff: Diffing extras/log4m
cvs diff: Diffing extras/logged_output
cvs diff: Diffing extras/monte
cvs diff: Diffing extras/moose
cvs diff: Diffing extras/moose/samples
cvs diff: Diffing extras/moose/tests
cvs diff: Diffing extras/mopenssl
cvs diff: Diffing extras/morphine
cvs diff: Diffing extras/morphine/non-regression-tests
cvs diff: Diffing extras/morphine/scripts
cvs diff: Diffing extras/morphine/source
cvs diff: Diffing extras/net
cvs diff: Diffing extras/odbc
cvs diff: Diffing extras/posix
cvs diff: Diffing extras/posix/samples
cvs diff: Diffing extras/quickcheck
cvs diff: Diffing extras/quickcheck/tutes
cvs diff: Diffing extras/references
cvs diff: Diffing extras/references/samples
cvs diff: Diffing extras/references/tests
cvs diff: Diffing extras/solver_types
cvs diff: Diffing extras/solver_types/library
cvs diff: Diffing extras/trailed_update
cvs diff: Diffing extras/trailed_update/samples
cvs diff: Diffing extras/trailed_update/tests
cvs diff: Diffing extras/windows_installer_generator
cvs diff: Diffing extras/windows_installer_generator/sample
cvs diff: Diffing extras/windows_installer_generator/sample/images
cvs diff: Diffing extras/xml
cvs diff: Diffing extras/xml/samples
cvs diff: Diffing extras/xml_stylesheets
cvs diff: Diffing java
cvs diff: Diffing java/runtime
cvs diff: Diffing library
Index: library/string.m
===================================================================
RCS file: /home/mercury/mercury1/repository/mercury/library/string.m,v
retrieving revision 1.303
diff -u -b -r1.303 string.m
--- library/string.m	15 Oct 2010 05:54:48 -0000	1.303
+++ library/string.m	2 Nov 2010 03:21:22 -0000
@@ -752,6 +752,10 @@
 :- func string.hash(string) = int.
 :- pred string.hash(string::in, int::out) is det.
 
+    % Two other hash functions for strings.
+:- func string.hash2(string) = int.
+:- func string.hash3(string) = int.
+
     % string.sub_string_search(String, SubString, Index).
     % `Index' is the position in `String' where the first occurrence of
     % `SubString' begins. Indices start at zero, so if `SubString' is a prefix
@@ -2017,31 +2021,67 @@
 join_list_2(Sep, [H | T]) = Sep ++ H ++ join_list_2(Sep, T).
 
 %-----------------------------------------------------------------------------%
+%
+% NOTE: string.hash, hash2 and hash3 are also defined as MR_hash_string,
+% MR_hash_string2 and MR_hash_string3 in runtime/mercury_string.h.
+% The corresponding definitions must be kept identical.
 
-    % NOTE: string.hash is also defined as MR_hash_string in
-    % runtime/mercury_string.h. The two definitions must be kept identical.
-    %
 string.hash(String, HashVal) :-
+    HashVal = string.hash(String).
+
+string.hash(String) = HashVal :-
+    string.length(String, Length),
+    string.hash_loop(String, 0, Length, 0, HashVal1),
+    HashVal = HashVal1 `xor` Length.
+
+:- pred string.hash_loop(string::in, int::in, int::in, int::in, int::out)
+    is det.
+
+string.hash_loop(String, Index, Length, !HashVal) :-
+    ( Index < Length ->
+        C = char.to_int(string.unsafe_index(String, Index)),
+        !:HashVal = !.HashVal `xor` (!.HashVal `unchecked_left_shift` 5),
+        !:HashVal= !.HashVal `xor` C,
+        string.hash_loop(String, Index + 1, Length, !HashVal)
+    ;
+        true
+    ).
+
+string.hash2(String) = HashVal :-
     string.length(String, Length),
-    string.hash_2(String, 0, Length, 0, HashVal0),
-    HashVal = HashVal0 `xor` Length.
+    string.hash2_loop(String, 0, Length, 0, HashVal1),
+    HashVal = HashVal1 `xor` Length.
 
-:- pred string.hash_2(string::in, int::in, int::in, int::in, int::out) is det.
+:- pred string.hash2_loop(string::in, int::in, int::in, int::in, int::out)
+    is det.
 
-string.hash_2(String, Index, Length, !HashVal) :-
+string.hash2_loop(String, Index, Length, !HashVal) :-
     ( Index < Length ->
-        string.combine_hash(char.to_int(string.unsafe_index(String, Index)),
-            !HashVal),
-        string.hash_2(String, Index + 1, Length, !HashVal)
+        C = char.to_int(string.unsafe_index(String, Index)),
+        !:HashVal = !.HashVal * 37,
+        !:HashVal= !.HashVal + C,
+        string.hash2_loop(String, Index + 1, Length, !HashVal)
     ;
         true
     ).
 
-:- pred string.combine_hash(int::in, int::in, int::out) is det.
+string.hash3(String) = HashVal :-
+    string.length(String, Length),
+    string.hash3_loop(String, 0, Length, 0, HashVal1),
+    HashVal = HashVal1 `xor` Length.
 
-string.combine_hash(X, H0, H) :-
-    H1 = H0 `xor` (H0 `unchecked_left_shift` 5),
-    H = H1 `xor` X.
+:- pred string.hash3_loop(string::in, int::in, int::in, int::in, int::out)
+    is det.
+
+string.hash3_loop(String, Index, Length, !HashVal) :-
+    ( Index < Length ->
+        C = char.to_int(string.unsafe_index(String, Index)),
+        !:HashVal = !.HashVal * 49,
+        !:HashVal= !.HashVal + C,
+        string.hash3_loop(String, Index + 1, Length, !HashVal)
+    ;
+        true
+    ).
 
 %-----------------------------------------------------------------------------%
 
@@ -5040,9 +5080,6 @@
 string.unsafe_substring(S1, N1, N2) = S2 :-
     string.unsafe_substring(S1, N1, N2, S2).
 
-string.hash(S) = N :-
-    string.hash(S, N).
-
 string.format(S1, PT) = S2 :-
     string.format(S1, PT, S2).
 
cvs diff: Diffing mdbcomp
cvs diff: Diffing profiler
cvs diff: Diffing robdd
cvs diff: Diffing runtime
Index: runtime/mercury_string.h
===================================================================
RCS file: /home/mercury/mercury1/repository/mercury/runtime/mercury_string.h,v
retrieving revision 1.36
diff -u -b -r1.36 mercury_string.h
--- runtime/mercury_string.h	1 Nov 2010 04:03:04 -0000	1.36
+++ runtime/mercury_string.h	2 Nov 2010 03:09:47 -0000
@@ -184,16 +184,15 @@
 	} while(0)
 
 /*
-** MR_do_hash_string(int & hash, MR_Word string):
+** MR_do_hash_string{,2,3}(int & hash, MR_Word string):
 ** Given a Mercury string `string', set `hash' to the hash value
 ** for that string.  (`hash' must be an lvalue.)
 **
-** This is an implementation detail used to implement MR_hash_string().
-** It should not be used directly.  Use MR_hash_string() instead.
+** This is an implementation detail used to implement MR_hash_string{,2,3}().
+** It should not be used directly. Use MR_hash_string{,2,3}() instead.
 **
-** Note that hash_string is also defined in library/string.m.
-** The definition here and the definition in string.m
-** must be kept equivalent.
+** Note that these functions are also defined in library/string.m.
+** The definition heres and in string.m must be kept equivalent.
 */
 
 #define MR_do_hash_string(hash, s)					\
@@ -211,12 +210,44 @@
 		hash ^= len;						\
 	}
 
+#define MR_do_hash_string2(hash, s)					\
+	{								\
+		int len;						\
+		MR_CHECK_EXPR_TYPE(hash, int);				\
+		MR_CHECK_EXPR_TYPE(s, MR_ConstString);			\
+		len = 0;						\
+		hash = 0;						\
+		while(((MR_ConstString)(s))[len]) {			\
+			hash = hash * 37;				\
+			hash += (MR_UnsignedChar) ((MR_ConstString)(s))[len]; \
+			len++;						\
+		}							\
+		hash ^= len;						\
+	}
+
+#define MR_do_hash_string3(hash, s)					\
+	{								\
+		int len;						\
+		MR_CHECK_EXPR_TYPE(hash, int);				\
+		MR_CHECK_EXPR_TYPE(s, MR_ConstString);			\
+		len = 0;						\
+		hash = 0;						\
+		while(((MR_ConstString)(s))[len]) {			\
+			hash = hash * 49;				\
+			hash += (MR_UnsignedChar) ((MR_ConstString)(s))[len]; \
+			len++;						\
+		}							\
+		hash ^= len;						\
+	}
+
 /*
-** MR_hash_string(s):
+** MR_hash_string{,2,3}(s):
 **	Given a Mercury string `s', return a hash value for that string.
 */
 
 MR_Integer	MR_hash_string(MR_ConstString);
+MR_Integer	MR_hash_string2(MR_ConstString);
+MR_Integer	MR_hash_string3(MR_ConstString);
 
 #ifdef __GNUC__
 #define MR_hash_string(s)						\
@@ -226,18 +257,39 @@
 		MR_do_hash_string(hash_string_result, s);		\
 		hash_string_result;					\
 	})
+
+#define MR_hash_string2(s)						\
+	({								\
+	 	MR_Integer hash_string_result;				\
+		MR_CHECK_EXPR_TYPE(s, MR_ConstString);			\
+		MR_do_hash_string2(hash_string_result, s);		\
+		hash_string_result;					\
+	})
+
+#define MR_hash_string3(s)						\
+	({								\
+	 	MR_Integer hash_string_result;				\
+		MR_CHECK_EXPR_TYPE(s, MR_ConstString);			\
+		MR_do_hash_string3(hash_string_result, s);		\
+		hash_string_result;					\
+	})
 #endif
 
 /*
-** If we're not using gcc, the actual definition of MR_hash_string is in
-** runtime/mercury_misc.c;
-** it uses the macro MR_HASH_STRING_FUNC_BODY below.
+** If we are not using gcc, the actual definitions of these functions
+** are runtime/mercury_misc.c; they use the macros below.
 */
 
 #define MR_HASH_STRING_FUNC_BODY					\
 	   MR_Integer hash_string_result;				\
 	   MR_do_hash_string(hash_string_result, s);			\
 	   return hash_string_result;
+#define MR_HASH_STRING2_FUNC_BODY					\
+	   MR_Integer hash_string_result;				\
+	   MR_do_hash_string2(hash_string_result, s);			\
+#define MR_HASH_STRING3_FUNC_BODY					\
+	   MR_Integer hash_string_result;				\
+	   MR_do_hash_string3(hash_string_result, s);			\
 
 /*
 ** A version of strcmp to which we can pass Mercury words
cvs diff: Diffing runtime/GETOPT
cvs diff: Diffing runtime/machdeps
cvs diff: Diffing samples
cvs diff: Diffing samples/c_interface
cvs diff: Diffing samples/c_interface/c_calls_mercury
cvs diff: Diffing samples/c_interface/cplusplus_calls_mercury
cvs diff: Diffing samples/c_interface/mercury_calls_c
cvs diff: Diffing samples/c_interface/mercury_calls_cplusplus
cvs diff: Diffing samples/c_interface/mercury_calls_fortran
cvs diff: Diffing samples/c_interface/simpler_c_calls_mercury
cvs diff: Diffing samples/c_interface/simpler_cplusplus_calls_mercury
cvs diff: Diffing samples/c_interface/standalone_c
cvs diff: Diffing samples/concurrency
cvs diff: Diffing samples/concurrency/dining_philosophers
cvs diff: Diffing samples/diff
cvs diff: Diffing samples/java_interface
cvs diff: Diffing samples/java_interface/java_calls_mercury
cvs diff: Diffing samples/java_interface/mercury_calls_java
cvs diff: Diffing samples/muz
cvs diff: Diffing samples/rot13
cvs diff: Diffing samples/solutions
cvs diff: Diffing samples/solver_types
cvs diff: Diffing samples/tests
cvs diff: Diffing samples/tests/c_interface
cvs diff: Diffing samples/tests/c_interface/c_calls_mercury
cvs diff: Diffing samples/tests/c_interface/cplusplus_calls_mercury
cvs diff: Diffing samples/tests/c_interface/mercury_calls_c
cvs diff: Diffing samples/tests/c_interface/mercury_calls_cplusplus
cvs diff: Diffing samples/tests/c_interface/mercury_calls_fortran
cvs diff: Diffing samples/tests/c_interface/simpler_c_calls_mercury
cvs diff: Diffing samples/tests/c_interface/simpler_cplusplus_calls_mercury
cvs diff: Diffing samples/tests/diff
cvs diff: Diffing samples/tests/muz
cvs diff: Diffing samples/tests/rot13
cvs diff: Diffing samples/tests/solutions
cvs diff: Diffing samples/tests/toplevel
cvs diff: Diffing scripts
cvs diff: Diffing slice
cvs diff: Diffing ssdb
cvs diff: Diffing tests
cvs diff: Diffing tests/analysis
cvs diff: Diffing tests/analysis/ctgc
cvs diff: Diffing tests/analysis/excp
cvs diff: Diffing tests/analysis/ext
cvs diff: Diffing tests/analysis/sharing
cvs diff: Diffing tests/analysis/table
cvs diff: Diffing tests/analysis/trail
cvs diff: Diffing tests/analysis/unused_args
cvs diff: Diffing tests/benchmarks
cvs diff: Diffing tests/debugger
cvs diff: Diffing tests/debugger/declarative
cvs diff: Diffing tests/dppd
cvs diff: Diffing tests/general
cvs diff: Diffing tests/general/accumulator
cvs diff: Diffing tests/general/string_format
cvs diff: Diffing tests/general/structure_reuse
cvs diff: Diffing tests/grade_subdirs
cvs diff: Diffing tests/hard_coded
cvs diff: Diffing tests/hard_coded/exceptions
cvs diff: Diffing tests/hard_coded/purity
cvs diff: Diffing tests/hard_coded/sub-modules
cvs diff: Diffing tests/hard_coded/typeclasses
cvs diff: Diffing tests/invalid
cvs diff: Diffing tests/invalid/purity
cvs diff: Diffing tests/misc_tests
cvs diff: Diffing tests/mmc_make
cvs diff: Diffing tests/mmc_make/lib
cvs diff: Diffing tests/par_conj
cvs diff: Diffing tests/recompilation
cvs diff: Diffing tests/stm
cvs diff: Diffing tests/stm/orig
cvs diff: Diffing tests/stm/orig/stm-compiler
cvs diff: Diffing tests/stm/orig/stm-compiler/test1
cvs diff: Diffing tests/stm/orig/stm-compiler/test10
cvs diff: Diffing tests/stm/orig/stm-compiler/test2
cvs diff: Diffing tests/stm/orig/stm-compiler/test3
cvs diff: Diffing tests/stm/orig/stm-compiler/test4
cvs diff: Diffing tests/stm/orig/stm-compiler/test5
cvs diff: Diffing tests/stm/orig/stm-compiler/test6
cvs diff: Diffing tests/stm/orig/stm-compiler/test7
cvs diff: Diffing tests/stm/orig/stm-compiler/test8
cvs diff: Diffing tests/stm/orig/stm-compiler/test9
cvs diff: Diffing tests/stm/orig/stm-compiler-par
cvs diff: Diffing tests/stm/orig/stm-compiler-par/bm1
cvs diff: Diffing tests/stm/orig/stm-compiler-par/bm2
cvs diff: Diffing tests/stm/orig/stm-compiler-par/stmqueue
cvs diff: Diffing tests/stm/orig/stm-compiler-par/test1
cvs diff: Diffing tests/stm/orig/stm-compiler-par/test10
cvs diff: Diffing tests/stm/orig/stm-compiler-par/test11
cvs diff: Diffing tests/stm/orig/stm-compiler-par/test2
cvs diff: Diffing tests/stm/orig/stm-compiler-par/test3
cvs diff: Diffing tests/stm/orig/stm-compiler-par/test4
cvs diff: Diffing tests/stm/orig/stm-compiler-par/test5
cvs diff: Diffing tests/stm/orig/stm-compiler-par/test6
cvs diff: Diffing tests/stm/orig/stm-compiler-par/test7
cvs diff: Diffing tests/stm/orig/stm-compiler-par/test8
cvs diff: Diffing tests/stm/orig/stm-compiler-par/test9
cvs diff: Diffing tests/stm/orig/stm-compiler-par-asm_fast
cvs diff: Diffing tests/stm/orig/stm-compiler-par-asm_fast/test1
cvs diff: Diffing tests/stm/orig/stm-compiler-par-asm_fast/test2
cvs diff: Diffing tests/stm/orig/stm-compiler-par-asm_fast/test3
cvs diff: Diffing tests/stm/orig/stm-compiler-par-asm_fast/test4
cvs diff: Diffing tests/stm/orig/stm-compiler-par-asm_fast/test5
cvs diff: Diffing tests/stm/orig/stm-compiler-par-asm_fast/test6
cvs diff: Diffing tests/stm/orig/stm-compiler-par-asm_fast/test7
cvs diff: Diffing tests/stm/orig/stm-compiler-par-asm_fast/test8
cvs diff: Diffing tests/stm/orig/stm-compiler-par-asm_fast/test9
cvs diff: Diffing tests/tabling
cvs diff: Diffing tests/term
cvs diff: Diffing tests/trailing
cvs diff: Diffing tests/valid
cvs diff: Diffing tests/warnings
cvs diff: Diffing tools
cvs diff: Diffing trace
cvs diff: Diffing util
cvs diff: Diffing vim
cvs diff: Diffing vim/after
cvs diff: Diffing vim/ftplugin
cvs diff: Diffing vim/syntax
--------------------------------------------------------------------------
mercury-reviews mailing list
Post messages to:       mercury-reviews at csse.unimelb.edu.au
Administrative Queries: owner-mercury-reviews at csse.unimelb.edu.au
Subscriptions:          mercury-reviews-request at csse.unimelb.edu.au
--------------------------------------------------------------------------



More information about the reviews mailing list