MLton 20051202 PolyEqual
Home  Index  
PolyEqual is an optimization pass for the SSA IntermediateLanguage, invoked from SSASimplify.

Description

This pass implements polymorphic equality.

Implementation

[WWW]poly-equal.sig [WWW]poly-equal.fun

Details and Notes

For each datatype, tycon, and vector type, it builds and equality function and translates calls to MLton_equal into calls to that function.

Also generates calls to IntInf_equal and Word_equal.

For tuples, it does the equality test inline; i.e., it does not create a separate equality function for each tuple type.

All equality functions are created only if necesary, i.e., if equality is actually used at a type.

Optimizations:


Last edited on 2005-12-01 23:28:42 by StephenWeeks.