Okay...Try this...
Pull the driver's side valve cover...With a big socket and breaker bar on the crank bolt, rotate the motor over clockwise while watching the rocker arms...The valves should all be opening up the same amount...Pay close attention to the #3 exhaust valve...(third one back from the front)...Make sure it is opening the same as all of them...If it looks like it is barely opening up, then most likely you have a wiped cam lobe...That would give you your knock that you're ecm is picking up...#3 exh is the most likely lobe to go, but check the others to be sure...As I've said, they should all look like they are moving the same amount...
That would also explain your miss, nosing over at higher rpms(due to louder knock and timing retarding), not being able to rev higher than 4k(same reason), etc...
If the driver's side looks fine, then hate to say it, but then pull the passenger side and check that side...After everything else that you have checked and done, a wiped cam seems to me like it would be the cause of all the problems...
What valves springs are you running on there now??? If it is the cam, when you replace the cam, change the valve springs out for some old, used stockers to break the cam and lifters in with...Then after you put on a few miles, change them back out for some CC979s or CC980s...
I hope you eventually get that car running right...I'm curious to see what it'll run...You've got a lot of good parts on there to give up on it...
Good Luck...