Many organizations implement a full-featured code search/intelligence tool — e.g., SourceGraph or Atlassian Fisheye — allowing engineers to search the enterprise code base. Other orgs just use the native search of the hosted version control system, such as GitHub‘s or GitLab‘s search. There are other commercial and open sources ways to search code.
Most of us, however, do not regularly work on code spanning the enterprise and would prefer results related to our current activities. You may also need to search the open source projects incorporated into your work. If this describes you, running OpenGrok on your laptop with a limited set of projects might be a solution.