Hi future applicants! Time to repay all the advice I read online over the last year or so...
I was admitted at MIT, Michigan, NYU, Rutgers, and some other places, waitlisted at Princeton, and rejected at Berkeley, Pitt HPS, and I assume Toronto. At least one of the schools that admitted me (NYU) mentioned my writing sample as the reason, and I think it's true that the sample is the most important part (though I'm sure I benefited from a somewhat well-known undergrad, etc.). So here are my two pieces of writing sample advice. I think they go somewhat against the prevailing advice on this thread so far.
Polishing and presenting is important, but not essential (my sample had typos, was in MS word, and worse, had math in MS word!). Feedback is great, but not the only way (I had a bit -- one prof read the first half). The best use of your time (I suspect) is preparing to write! That is, brainstorming, thinking, reading, and so on. I didn't plan it this way, but I spent about 9 months scratching my head over my topic: talking about it with my advisor, coming up with ideas, abandoning ideas (3 or 4 'grand theories' in the trash), writing class papers on adjacent problems, reading books on it, and so on. The result was that I had a good understanding of my problem, and some fairly cutting edge things to say about it. Then I wrote for a month and edited for a couple weeks. My point is that for your paper to stand out you need a comparatively deep understanding of your topic, and lots of feedback-revision cycles are not as effective a way of getting there as reading and thinking (especially if your profs aren't experts on your particular problem!).
Here's a second piece of advice which may be more controversial: if a "publishable paper" is consummately self-contained, thoroughly situates itself in the literature, and develops all its points without leaving gaps, then the ideal result is not a publishable paper. In particular, it might be better to do something slightly more ambitious (that to properly argue for could take 40-80 pages!) than something that meets all these criteria. This is what I did -- thought I was overshooting at first. I had enough stuff to say that I addressed very few counterarguments and had lots of explicit "this requires development that I won't give here" footnotes. By the end, I was fully in sketching mode: "I hope I have suggested how such an account can do X (even though fully showing that would take another 30, shh)." The theory is that (a) it's more compelling to demonstrate your philosophical creativity than your ability to flawlessly present an argument, (b) these two things are in tension because of the page limits, and so (c) you should err on the side of demonstrating creativity so long as the ideas are good and you don't come off as utterly undisciplined. My evidence for this theory, of course, is anecdotal at best... But if you find yourself 3 weeks before deadline thinking "oh no this should have been a 50 pager," don't despair. (This is more of an academic rhetoric problem, in that you have to write it so the reader doesn't think 'uhoh, big gap neglected there.' I don't mean try to pull one over on them! But address the omission and make it seem reasonable.)
So taken together, these come to: don't spend all your effort revising and tuning in hopes of getting the perfect journal-quality article. Instead, spend a lot of time trying to come to an understanding of your topic so that you have a lot of good ideas to write about. Otherwise, I second everything the very hungry caterpillar said above, especially taking time off after your BA. Best of luck and don't let it get you down!