Solving recurrence


How to solve the recursion:

$ T(n) = \begin{cases} T(n/2) + O(1), & \text{if $ n$ is even} \ T(\lceil n/2 \rceil) + T(\lfloor n/2 \rfloor) + O(1), & \text{if $ n$ is odd} \end{cases} $

I think T(n) is O(logn). Can somebody show a proof?