abhishek-kaushik22 wrote: > Can't we make RegAllocFilterFunc a raw function pointer instead? I think none of the users require captures and std::function is inefficient. I will try and update here. Thanks! https://github.com/llvm/llvm-project/pull/157825