I don't think any degree outside of a Ph.D in basic or applied health science makes a difference for purposes of IM residency applications and matching - the kinds of research that these programs are most eager to fit residents into and hopefully retain in subspecialty fellowships are the kinds that involve the basic and applied lab work. The idea is that adding a Ph.D in those areas through the match will add be adding someone who is autonomous in both designing and carrying out research and will be someone who they can turn things over to and even get significant contributions from as far as grant writing while in residency and more importantly will be most likely to secure a solid research grant as a fellow. The perception seems to be that clinical research is something that they can teach you so they key for being able to contribute to clinical rather than bench research is that you be rock solid in medicine so you will have time to work on that in residency. So a PhD in the sciences or rock solid work in clinical rotations and boards are the two independently sufficient conditions for attracting interest from competitive IM residencies. Other types of research are viewed with much less interest, probably for many reasons, one of which may be that they are generally viewed, rightly or wrongly, as less likely to generate/capture large grants which is the lifeblood of high profile residencies.
That said, I matched at the IM residency I wanted and I do have a JD, an MA in philosophy/bioethics and 4 more years of research so far towards my PhD in philosophy but I feel the interest I got was a function of being AOA with high honors in all clerkships, good boards, Lange book award and the college award for Internal Medicine - I don't think I had or would have had any slack cut for my other degrees and research in the sense of being able to get the same interviews and the match without performing at that level in med school but I would have had slack and been able to get by with a lesser performance in med if I had had a PhD in the sciences. I'm happy and I'm not saying the different status of different kinds of research experiences is either good or bad - its just the way it is. On the one hand, I am not looking at residency in IM as a way to hone my legal and ethical research chops - I already have my training and have a dispersed group of mentors and peers and on the flip side I don't think my research background and profile can do much in the way of generating a large grant on the same scale as what a PhD in the sciences can. Residencies know this and act accordingly. I knew it and put a lot of work in on the med side of things and it paid off.