Impurity profiling