I was testing such very simple code

float modelRight_x = 1.1; float modelRight_y = 1.2; float modelRight_z = 1.3; float modelUp_x = 1.1; float modelUp_y = 1.2; float modelUp_z = 1.3; float modelDir_x = 1.1; float modelDir_y = 1.2; float modelDir_z = 1.3; float normal_x[100*1000]; float normal_y[100*1000]; float normal_z[100*1000]; float n_x[100*1000]; float n_y[100*1000]; float n_z[100*1000]; void matrix_mul_float() { for(int i=0; i<100*1000; i++) { normal_x[i] = n_x[i]*modelRight_x + n_y[i]*modelRight_y + n_z[i]*modelRight_z; normal_y[i] = n_x[i]*modelUp_x + n_y[i]*modelUp_y + n_z[i]*modelUp_z; //third line -> normal_z[i] = n_x[i]*modelDir_x + n_y[i]*modelDir_y + n_z[i]*modelDir_z; } return; }

(dam those forum bug eated text again)

I got runtime crash on the third line , when comment this line its ok, when xchange it with normal_x[i] = ... line it crashes on those x third line then, it also works when changing

normal_z[i**/2**] = n_x[i]*modelDir_x + n_y[i]*modelDir_y + n_z[i]*modelDir_z;

normal_z[i/**1*1**] = n_x[i]*modelDir_x + n_y[i]*modelDir_y + n_z[i]*modelDir_z;

crashes

normal_z[i/**2*2**] = n_x[i]*modelDir_x + n_y[i]*modelDir_y + n_z[i]*modelDir_z;

gcc 4.7.1

is this compiler bug?

**Edited by fir, 30 June 2014 - 06:05 AM.**