It's a question that's much more complex than syntax or subject alone can show. It might be easy for me to save a complete stranger if I'm not attached to the dog - even if that dog is "mine" on a legal or social standpoint - but any serious emotional connection to either of them would make things very difficult.
We tend to give our pets anthropomorph qualities without even being conscious of it. Spend a few years tending to even a rabbit or a hamster, and you'll start to gauge its moods, wants and needs in the same way you would a human being you've known for a long while. The dog will never speak, he'll never write poetry, solve math problems or get a job, but he can very much come to mean more to you than any human life you might be familiar with. In that case, I'd save the dog.
The same thing really applies to people. There's always a tipping point where you realize that this or that person isn't just a tool you use or an acquaintance. If they were, they're not anymore. They've gained a tremendous amount of value, to the point of imagining your life without them being a little difficult. In that case, I'd save the human.
Unfortunately, most of us are geared to have empathy towards people who suffer or who are fearful of something. In a knee-jerk situation where I'd see *both* a human and a dog holding on for dear life?
I honestly don't know which one I'd save. It's not something I can pick apart rationally. I think my higher thought processes would just go bye-bye and I'd pick the coward's way out as a sudden means to ensure my continued existence. If there's two people about to die by falling off a cliff, who's to say it won't happen to me if I try to help them?
I don't know. As sensitive as I am (and I really am a big softie), I think I'd be unable to do anything. Not because of callousness or evil or selfishness - just because I'd be afraid, and because that underlying complexity would be too much for me to handle in a split-second.