How to get into computer science research as a college student
The first problem you will have is coming up with a problem worth exploring. If you don't yet have much experience it is a very hard thing to discover. So, yes, talk to one or more professors, perhaps your advisor, about what sorts of problems they are interested in. 

Perhaps they can get you started with some part of their own explorations, or give you a problem they have set aside for lack of time to explore it. 

In your first time out, it may not be vitally important that  you actually come up with results. Learning the process may be enough. But who knows. Maybe you learn something that can be published. 

In fact, some problems worth exploring don't really have accessible solutions. They may be beyond the current state of knowledge to solve. The same is true in math, of course. It is very difficult to predict in advance whether a problem is actually solvable with the resources available - including time. 

Eventually - many years - you will probably develop the insight to see the problems that are unsolved, but solvable, and also worth the effort to explore. But like anything else, that takes practice. Start with someone who has already been there to help guide your initial steps.