Spending time with IBM CEO Ginni Rometty shows how she is trying to reinvent the nearly 104-year-old tech icon while it continues a yearslong slump. Her task is unlike that of past CEOs, who remade IBM by shifting toward new markets it could dominate.