Rework ocperf flags handling

Now flags are properly merged and not duplicated
Also sanitize the event rmap interface
And fix/improve the test suite