Solved xorg-server: Fatal server error: GLSL compile failure: Failed to compile VS: 0:13(43): error: `pos' undeclared


i am using FreeBSD 12.1-RELEASE (i386) with the i915kms driver and the xorg-server sometimes crashes with the following error:
[   324.818] Failed to compile VS: 0:13(43): error: `pos' undeclared
0:13(14): error: operands to arithmetic operators must be numeric
0:13(13): error: operands to arithmetic operators must be numeric

[   324.818] Program source:
#define ATLAS_DIM_INV 0.000976562500000000
attribute vec2 primitive;
attribute vec2 source;
varying vec2 glyph_pos;
uniform vec2 fill_offset;
uniform vec2 fill_size_inv;
varying vec2 fill_pos;
uniform vec4 v_matrix;
void main() {
       gl_Position.xy = primitive.xy * v_matrix.xz + v_matrix.yw; = vec2(0.0,1.0);
       glyph_pos = source.xy * ATLAS_DIM_INV;
       fill_pos = (fill_offset + primitive.xy + pos) * fill_size_inv;
[   324.818] (EE)
Fatal server error:
[   324.818] (EE) GLSL compile failure
[   324.818] (EE)
[   324.818] (EE)
Please consult the The X.Org Foundation support
for help.
[   324.818] (EE) Please also check the log file at "/var/log/Xorg.0.log" for additional information.
[   324.818] (EE)
[   324.832] (II) AIGLX: Suspending AIGLX clients for VT switch
[   324.847] (EE) Server terminated with error (1). Closing log file.

I made a bug report at PR 243887 but i am unsure if i did it right, since it's my first bug report ever. :)
Do you have any suggestions regarding additional information i can post there?

Never mind. I found and it seems that the Desktop team already's working on a new version of xorg-server in FreeBSD:

I guess i just have to have a little more patience.

Edit 2:
The workaround to this problem is to disable glamor / 2d acceleration in the modesetting driver:
[xxx@xxx ~]$ cat /usr/local/etc/X11/xorg.conf.d/driver-modesetting.conf
Section "Device"
  Identifier "Intel Graphics"
  Driver     "modesetting"
  Option     "AccelMethod" "none"
Last edited: