Instrumentation refactoring