It depends on how many other homeless people I've done something for that week.
I'm pretty bad at walking past a homeless person without doing something. It's a character flaw. Luckily, there aren't that many of them in Norwich. I'll normally buy a Big Issue if they're selling one, otherwise maybe give them a pound or two.
It's really tricky when you go to your wallet to give them money and then realise you only have notes. You can't then walk away without giving them anything, so they get £5 off you. That's annoying.
Thus the "depends on how many homeless people I've already done something for". If it's been a week where I've haemorrhaged money to many homeless people then I'll have to walk by.
Though on Christmas Eve 2009 I was walking home from the city centre after work Christmas party and this one guy sitting in the snow made me feel so bad that I gave him my coat.
I really regretted that one about 10 minutes later. At least it was my cheap coat.
I never buy them something to eat. What if someone else has done the same 5 minutes earlier? What if they're not hungry now, but might be hungry tomorrow? What if what they need more is warmth or shelter? What if I don't want to assume all homeless people are addicts and insult them by giving them a sandwich instead of money, like they're not capable of making their own decisions?
Edit: On the more general topic of how empathetic I am, I don't think the homeless people example is that great a way to judge. From the above you'd think that I'm the most empathetic person in the universe. But I can read a news report about a genocide in Africa and barely feel a thing. It's all about proximity.
Cognitive and behavioural science has shown that, generally, empathy really decreases the further a person is from you, both in terms of geography but more importantly in terms of social grouping. So I might have strong empathy for my family and friends, less for passing acquaintances (e.g. homeless people), further less for my countrymen in general, further less for Europeans and Anglo-American nations, and least for everyone else.
On the other hand, other people are the exact opposite to this general rule. My best friend never gives anything to homeless people (maybe she knows that they're getting enough off me!) but is always much more concerned than I about distant events.