If I understand your model number correctly, you have an HP M3970AM-HP motherboard. The best cpu that board officially supports is the AMD FX-8150. HP support is not clear, but you can probably also run an FX 8350 CPU which would be much better.
Perhaps if you could explain why you need the seemingly arbitrary 4Ghz, I could help you better. GHz by itself is not typically a very useful measure of actual performance capability.