This is a very good question! First of all, when you say you've had knee pain in the past, what type of knee pain? Is it above the knee, below it, around it? Is there swelling with the pain? From an LMTs standpoint, I'd want to know if it's something that, perhaps, your quads or your lower leg muscles are contributing to. Then, I'd also want to know if there's a doc's diagnosis with this pain.
Will a compress make it worse? Warmth is soothing, it also works to heat up sluggish fluids. If there's inflammation, however, then that could be contraindicated. Without more information to work with, it's difficult to give you a cohesive answer; my apologies for that. If you can answer some of these questions, we might be able to give you a better answer.
Best of luck!