Tracking Process to a particular

I've tried to see what I can find on my own but I'm coming up with goose eggs. Basically I was wondering if there was a way of querying the scheduler (or something similar) to track a process back to a particular CPU it's executing on at the time of the command. ps has a "cpu" output option but apparently only prints out a hyphen for every single process. I don't think setting processor affinity would work since I don't really know which processes are jacking up the iowait on this cpu and I don't want to just start offloading every process on the system onto a single cpu (if that were even possible, which I don't think it is, correct me if I'm wrong).

Basically, I need help tracking a running process to a cpu so I can see which of these state D's are causing the issue for this processor.

When a process is in 'D' state, as in 'device driver' it's actually not running -- it's suspended, waiting for a system call to finish. Which CPU the kernel uses for what is not managed by the usual process controls (probably why it's only showing - too.) Might be better to find out why you're getting a high iowait.