True story: I got back into writing-with-intent-to-publish in 2009, after a decade hiatus. I thought I was ready to query my just-finished novel in 2010. I spent a total of 3 months researching agents and publishers in the science fiction and fantasy genres. Over 200 agents, and around 85 different publishers. Some I knew were not a good fit, instantly. Others took some more research. I ended up with a list of 125 agents, whom I started querying first before I went near publishers. That took a year. The book excerpts got Silver Honorable Mention on the Writers of the Future, and a third place in a Random House writing contest. I got agent requests for three partials leading to rejections, 85 flat-out rejections, and the rest were no-response. I trunked that book because it was a hot mess under the pretty words. I'll fix it someday.
Because I did that research, I have a historical context in which to place ongoing publisher dramas. I was able to see clues well in advance, when certain publishers went into messy death-spirals, many of them documented exhaustively here on AW. I can spot the clueless and predatory publishers a mile away, often by just watching what their sockpuppets are saying about places like AW, Hi Piers, Making Light, Writer Beware, Preditors & Editors, etc.
In early 2011 I wrote another book in about four months. Spent another two months, off and on, researching which agents were good and/or available in that genre (turned out, none) and which publishers (seven, out of the hundreds around.) I sold the book a little over a month after querying those seven publishers. Then I used that contract offer to get an agent's help, and she eventually agreed to represent my other works. There was a lot of slow and careful research there, lots of polite messages to AW members who could help me, and lots of patience.
I used to send people (who asked me politely) copies of my old agent/publisher list. I can't anymore, because it's dangerously out of date. If I needed a new list I'd start over, and do exactly the same research. I frankly wouldn't trust any list that someone just handed to me, because I wouldn't know the level of information involved. Fer gawdssake, I just caught a major fantasy author thoughtlessly endorsing a substandard spammy display site, because she apparently bought their hype without researching!
Tl;dr Do your work.