Estimated hours taken: 25
Branches: main
Replace the implementation of `ctgc.selector.subsumed_by', which was not
working correctly for some selectors which contained type selectors. For
instance, `subsumed_by(ModuleInfo, S1, S2, Extension)' wouldn't succeed if
S1 = [typesel(t1)], S2 = [termsel(f/1,1)] even if it would be possible to
select a node with the selector [termsel(f/1,1), typesel(t1)]. In this
case S2 does subsume S1, with Extension = [typesel(t1)].
The bug caused the structure sharing "comb" operation to not work as
intended, so that information about sharing between data structures would be
lost when `--structure-sharing-widening' was enabled, as it introduces type
selectors.
compiler/ctgc.selector.m:
Replace `subsumed_by' by a more direct version which hopefully works
as intended.
Delete procedures which are longer used.
tests/hard_coded/Mercury.options:
tests/hard_coded/Mmakefile:
tests/hard_coded/sharing_comb.exp:
tests/hard_coded/sharing_comb.m:
Add a test case.