Code optimization is a service you can expect at the highest levels of search engine optimization services, as it involves an overhaul of your website HTML. The optimization of your HTML can impact search engine rankings in two ways. First, it can help alleviate code-clutter, and present your content in an easy-to-understand (for machines, that is, search engine algorithms) format. Second, it can help reduce the load-time of your website pages, so that search engine spiders don't have to wait around while your page loads (because it's too long, or has too many images, etc).
A comprehensive search engine optimization campaign will have all the above elements, but it will also incorporate other important services such as keyword research, ranking reports, traffic reports, and conversion tracking.