单项选择题

设n是描述问题规模的非负整数,下面程序片段的时间复杂度是()。
x=2;
while(xx=2*x;

A、O(logn) 
B、O(n) 
C、O(nlogn) 
D、O(n2)