Bug on "get_global_id(0) + get_global_id(1)*x" clause

Hunt this down for day…

following line produces weird result like 1101245634 etc.

  size_t blockAddress=get_global_id(0)+get_global_id(1)*width;

Following works ok;

  size_t x=get_global_id(0);
  size_t y=get_global_id(1);
  size_t blockAddress=x+y*width;

Is there some restriction to use get_global_id() directly on formulas?