https://gcc.gnu.org/bugzilla/show_bug.cgi?id=92283
--- Comment #13 from Richard Biener <rguenth at gcc dot gnu.org> --- (In reply to Richard Biener from comment #12) > more complex "ranges" for debug counters appreciated, > -fdbg-cnt=foo:{5-6,9,1-10} or some sorts of that (lists of ranges / values). > I'm definitely missing a all-but-N as well. ~6 and ~6-9 maybe. Guess > {} don't work very well due to shell limitations so maybe > simply foo:5-6:9:1-10,bar:... with changing semantics of previous handling. > Implementation-wise we'd have instead of high/low arrays > an array of pair<counter, vec<pair<high, low> > which we only look at > the last element of the vec (sort it backwards), popping it whenever > we reach it's max and checking against the current min. or some > other data structure mimicing this, that is, dbg_cnt () is still O(1) > just parsing the option might involve sorting. If we store the "inverse" in the vector then an empty vector would be the natural default value [0,+INF] included. So we could continue to statically initialize it (or treat .exists () as special value as opposed to empty).