Hi, I have a honda civic 2001 prosmatic. It runs just fine but when the engine warms up the engine drops the rpm from 800 to 500 on D and R and jumps back to 1000rpm when I put it in P or N. I have cleaned the IACV and throttle but the problem still remains.

We call that a Civic in Canada - good car - I'd say scan the car's computer for fault codes and lets start from that point to diagnose - also given it's age I'd be changing out most of the vacuum hoses since they may be causing a small vacuum leak - check very closely

Try this video of Scotty's, if no MAF sensor, ignore that part of it:

finally fixed the problem. the culprit was an old Cam shaft sensor grip. the wires were mixing up and causing the issue. replaced the sensor and its grip and the car runs fine now.