And the answer is whatever the manufacturer supports. No real rule of thumb here. Some motherboards and sockets are cross platform capable, but not that many, and there were always limitations.
To get an answer you need the chipset of the motherboard as a minimum, preferably the exact model. At that point you just need to look up the motherboard to see the list of supported CPUs.
Many AM2+/AM3 boards had cross platform support. Then the bandwidth available to the CPU was limited by putting a newer CPU in an older socket. Intel less so, but there were many LGA775 socket CPUs, and sometimes you could upgrade. Other times the chipset would have a hard limit on FSB, # of cores, or memory type.