How important is publication for PhD admission? As a master's student in computer science, I would really like to go for a PhD at a good CS department. However until now, I have no publications and really have no idea how to start research. I'm interested in many subjects but I have not yet been able to narrow down the choice to a specific one. For someone like me who just began his or her master's studies and wants to plan for a PhD, what is the real number one priority besides a good GPA?
I would say publications dont matter to start with a PhD, in general. Having them might help in reducing length of your PhD.

A good thing to have is liking for one area in CS, and good knowledge in that area atleast. e.g. systems or security or algorithms or formal verification or databases or distributed systems etc. Later when you join for the PhD program, you will do courses and talk with people to get an understanding on what is a good research problem etc.