ISSOtm / fortISSimO

A speed-and size-focused Game Boy music driver, drop-in replacement for hUGEDriver ~ Try the demo!
http://eldred.fr/fortISSimO/
Other
20 stars 3 forks source link

Allow disabling teNOR's optimisation passes #14

Open ISSOtm opened 1 year ago

ISSOtm commented 1 year ago

This should be relatively easy:

  1. Add a new option (in main.rs); I'm thinking something like -O -trim_patterns,+prune_instruments. (-O is a common "optimisation" flag, e.g. in C compilers.) The argument would be a comma-separated list of pass toggles, with the + or - prefix indicating whether to enable or disable the pass.
  2. For each pass, if it's disabled, then replace it with a dummy operation that doesn't perform any optimisations. (For example, the "row overlap" pass would instead return some arbitrary order, and no overlap.)

Rationale

This would be useful for people doing tricks with the song data (e.g. using routines to manipulate the song pointer).