c4-project / c4t

Runs concurrent C compiler tests
MIT License
1 stars 0 forks source link

Allow operator names in mutant ranges #126

Open MattWindsor91 opened 3 years ago

MattWindsor91 commented 3 years ago

In the mutation experiments I've been doing, it's common for mutants to be grouped into multiple invocations of a named mutant operator. Right now, mutants are always just raw IDs that are indices into the compilers' mutation table, but things would be a little easier on the data analysis style if we could assign systematic mutant names over those IDs.

A nice approach would be to assign an operator name to ranges, like so:

[[machines.foo.mutation.auto.ranges]]
  operator = "FA" # flip isAtLeastOrStrongerThan
  start    = 50
  end      = 99

This would then systematically name mutant 50 as FA1, mutant 51 as FA2, and so on to FA49 in all user-facing output (though 50, 51, etc would still be passed to the compiler).

This would necessitate a change to the Mutant type, either to be an index into a table, or to be something like

type Mutant struct {
  Name string
  ID   int
}