Bug 342582 - Intel hd 4600 + OpenGL + kwin = can't load
Summary: Intel hd 4600 + OpenGL + kwin = can't load
Status: RESOLVED FIXED
Alias: None
Product: kwin
Classification: Plasma
Component: scene-opengl (show other bugs)
Version: git master
Platform: Kubuntu Linux
: NOR normal
Target Milestone: ---
Assignee: KWin default assignee
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2015-01-07 14:52 UTC by Kakadu.hafanana
Modified: 2023-11-12 08:34 UTC (History)
6 users (show)

See Also:
Latest Commit:
Version Fixed In:


Attachments
Log when I can't login (startup indicator freezes) (73.54 KB, text/plain)
2015-01-07 14:56 UTC, Kakadu.hafanana
Details
Kwin support information when I have SUCCEEDED to login (3.15 KB, text/plain)
2015-01-07 15:04 UTC, Kakadu.hafanana
Details
glx: Fix the swap event filter for DRI3 drivers (3.02 KB, patch)
2015-01-08 06:16 UTC, Fredrik Höglund
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Kakadu.hafanana 2015-01-07 14:52:26 UTC
Problem.
Can't load (log in) with OpenGL. Loading indicator is stuck somewhere near 75% and doesn't move.

Workaround: export KWIN_OPENGL_INTERFACE=egl and startkde


Reproducible: Always

Steps to Reproduce:
1. Find PC with Core i7 and Ubuntu 14.10
2. Start separate X session something like 'xinit /usr/bin/xterm startkde -- /etc/X11/xinit/xserverrc :1`


Actual Results:  
Loading is stuck near 75% (indicator from breeze theme)

Expected Results:  
Plasma appears

how to get log: 
➜  kde_backup  cat ~/startkde 
#!/usr/bin/env bash
set -xe
startkde > log.startkde 2>&1

and

xinit /usr/bin/xterm ~/startkde -- /etc/X11/xinit/xserverrc :1

My log for failed start: http://paste.in.ua/10232/

Workaround: _Groo_ from Freenode IRC channel have said that glx is broken with Intel drivers. So I have added 'export KWIN_OPENGL_INTERFACE=egl' to my 'startkde' script and I have log in successfully.
Comment 1 Kakadu.hafanana 2015-01-07 14:56:00 UTC
Created attachment 90271 [details]
Log when I can't login (startup indicator freezes)

Also can be found at http://paste.in.ua/10232/ .
I'm not sure that it is helpful but I let it here.
Comment 2 Kakadu.hafanana 2015-01-07 14:59:23 UTC
I use kubuntu ppa if it does matter.
deb http://ppa.launchpad.net/kubuntu-ppa/next/ubuntu utopic main

My video card is Intel HD 4600 
http://ark.intel.com/products/80807/Intel-Core-i7-4790K-Processor-8M-Cache-up-to-4_40-GHz

I have seen bugs https://bugs.kde.org/show_bug.cgi?id=335983
and https://bugs.kde.org/show_bug.cgi?id=333249
but they seems not to be related to my issue.
Comment 3 Kakadu.hafanana 2015-01-07 15:04:02 UTC
Created attachment 90272 [details]
Kwin support information when I have SUCCEEDED to login

I don't know will it help but that it is . Also available in http://paste.in.ua/10233/raw/
Comment 4 Kakadu.hafanana 2015-01-07 15:08:51 UTC
kwin is 5.1.90
Comment 5 Thomas Lübking 2015-01-07 15:21:45 UTC
> Compositing is not active
You're not compositing in the successfull login.

a) can you start the compositor (Shift+Alt+F12) (and provide a new supportInformation)
b) otherwise please attach the output of "glxinfo"
c) does "export KWIN_USE_BUFFER_AGE=0" help? (revert the egl selection for this)
d) does "export KWIN_EXPLICIT_SYNC=0" help? (revert the egl selection for this as well)
Comment 6 Martin Flöser 2015-01-07 15:43:20 UTC
I just experienced the same problem with the latest weekly iso.

a) + b) nothing interesting (cannot attach as no internet right now on the system)
c) nope
d) nope
Comment 7 Martin Flöser 2015-01-07 15:51:50 UTC
glxinfo:
name of display: :0
display: :0  screen: 0
direct rendering: Yes
server glx vendor string: SGI
server glx version string: 1.4
server glx extensions:
    GLX_ARB_create_context, GLX_ARB_create_context_profile, 
    GLX_ARB_create_context_robustness, GLX_ARB_fbconfig_float, 
    GLX_ARB_framebuffer_sRGB, GLX_ARB_multisample, 
    GLX_EXT_create_context_es2_profile, GLX_EXT_framebuffer_sRGB, 
    GLX_EXT_import_context, GLX_EXT_texture_from_pixmap, GLX_EXT_visual_info, 
    GLX_EXT_visual_rating, GLX_INTEL_swap_event, GLX_MESA_copy_sub_buffer, 
    GLX_OML_swap_method, GLX_SGIS_multisample, GLX_SGIX_fbconfig, 
    GLX_SGIX_pbuffer, GLX_SGIX_visual_select_group, GLX_SGI_swap_control
client glx vendor string: Mesa Project and SGI
client glx version string: 1.4
client glx extensions:
    GLX_ARB_create_context, GLX_ARB_create_context_profile, 
    GLX_ARB_create_context_robustness, GLX_ARB_fbconfig_float, 
    GLX_ARB_framebuffer_sRGB, GLX_ARB_get_proc_address, GLX_ARB_multisample, 
    GLX_EXT_buffer_age, GLX_EXT_create_context_es2_profile, 
    GLX_EXT_fbconfig_packed_float, GLX_EXT_framebuffer_sRGB, 
    GLX_EXT_import_context, GLX_EXT_texture_from_pixmap, GLX_EXT_visual_info, 
    GLX_EXT_visual_rating, GLX_INTEL_swap_event, GLX_MESA_copy_sub_buffer, 
    GLX_MESA_multithread_makecurrent, GLX_MESA_query_renderer, 
    GLX_MESA_swap_control, GLX_OML_swap_method, GLX_OML_sync_control, 
    GLX_SGIS_multisample, GLX_SGIX_fbconfig, GLX_SGIX_pbuffer, 
    GLX_SGIX_visual_select_group, GLX_SGI_make_current_read, 
    GLX_SGI_swap_control, GLX_SGI_video_sync
GLX version: 1.4
GLX extensions:
    GLX_ARB_create_context, GLX_ARB_create_context_profile, 
    GLX_ARB_create_context_robustness, GLX_ARB_fbconfig_float, 
    GLX_ARB_framebuffer_sRGB, GLX_ARB_get_proc_address, GLX_ARB_multisample, 
    GLX_EXT_buffer_age, GLX_EXT_create_context_es2_profile, 
    GLX_EXT_framebuffer_sRGB, GLX_EXT_import_context, 
    GLX_EXT_texture_from_pixmap, GLX_EXT_visual_info, GLX_EXT_visual_rating, 
    GLX_INTEL_swap_event, GLX_MESA_copy_sub_buffer, 
    GLX_MESA_multithread_makecurrent, GLX_MESA_query_renderer, 
    GLX_MESA_swap_control, GLX_OML_swap_method, GLX_OML_sync_control, 
    GLX_SGIS_multisample, GLX_SGIX_fbconfig, GLX_SGIX_pbuffer, 
    GLX_SGIX_visual_select_group, GLX_SGI_make_current_read, 
    GLX_SGI_swap_control, GLX_SGI_video_sync
OpenGL vendor string: Intel Open Source Technology Center
OpenGL renderer string: Mesa DRI Intel(R) Sandybridge Mobile 
OpenGL core profile version string: 3.1 (Core Profile) Mesa 10.3.0
OpenGL core profile shading language version string: 1.40
OpenGL core profile context flags: (none)
OpenGL core profile extensions:
    GL_3DFX_texture_compression_FXT1, GL_AMD_draw_buffers_blend, 
    GL_AMD_performance_monitor, GL_AMD_seamless_cubemap_per_texture, 
    GL_AMD_shader_trinary_minmax, GL_ANGLE_texture_compression_dxt3, 
    GL_ANGLE_texture_compression_dxt5, GL_APPLE_object_purgeable, 
    GL_ARB_ES2_compatibility, GL_ARB_ES3_compatibility, GL_ARB_base_instance, 
    GL_ARB_blend_func_extended, GL_ARB_buffer_storage, 
    GL_ARB_clear_buffer_object, GL_ARB_clear_texture, 
    GL_ARB_compressed_texture_pixel_storage, 
    GL_ARB_conditional_render_inverted, GL_ARB_copy_buffer, GL_ARB_copy_image, 
    GL_ARB_debug_output, GL_ARB_depth_buffer_float, GL_ARB_depth_clamp, 
    GL_ARB_draw_buffers, GL_ARB_draw_buffers_blend, 
    GL_ARB_draw_elements_base_vertex, GL_ARB_draw_instanced, 
    GL_ARB_explicit_attrib_location, GL_ARB_explicit_uniform_location, 
    GL_ARB_fragment_coord_conventions, GL_ARB_fragment_shader, 
    GL_ARB_framebuffer_object, GL_ARB_framebuffer_sRGB, 
    GL_ARB_get_program_binary, GL_ARB_half_float_pixel, 
    GL_ARB_half_float_vertex, GL_ARB_instanced_arrays, 
    GL_ARB_internalformat_query, GL_ARB_invalidate_subdata, 
    GL_ARB_map_buffer_alignment, GL_ARB_map_buffer_range, GL_ARB_multi_bind, 
    GL_ARB_occlusion_query2, GL_ARB_pixel_buffer_object, GL_ARB_point_sprite, 
    GL_ARB_provoking_vertex, GL_ARB_robustness, GL_ARB_sample_shading, 
    GL_ARB_sampler_objects, GL_ARB_seamless_cube_map, 
    GL_ARB_seamless_cubemap_per_texture, GL_ARB_separate_shader_objects, 
    GL_ARB_shader_bit_encoding, GL_ARB_shader_objects, 
    GL_ARB_shader_texture_lod, GL_ARB_shading_language_420pack, 
    GL_ARB_shading_language_packing, GL_ARB_sync, 
    GL_ARB_texture_buffer_object, GL_ARB_texture_buffer_object_rgb32, 
    GL_ARB_texture_buffer_range, GL_ARB_texture_compression_rgtc, 
    GL_ARB_texture_cube_map_array, GL_ARB_texture_float, 
    GL_ARB_texture_gather, GL_ARB_texture_mirror_clamp_to_edge, 
    GL_ARB_texture_multisample, GL_ARB_texture_non_power_of_two, 
    GL_ARB_texture_query_levels, GL_ARB_texture_query_lod, 
    GL_ARB_texture_rectangle, GL_ARB_texture_rg, GL_ARB_texture_rgb10_a2ui, 
    GL_ARB_texture_storage, GL_ARB_texture_storage_multisample, 
    GL_ARB_texture_swizzle, GL_ARB_timer_query, GL_ARB_uniform_buffer_object, 
    GL_ARB_vertex_array_bgra, GL_ARB_vertex_array_object, 
    GL_ARB_vertex_attrib_binding, GL_ARB_vertex_shader, 
    GL_ARB_vertex_type_10f_11f_11f_rev, GL_ARB_vertex_type_2_10_10_10_rev, 
    GL_ATI_blend_equation_separate, GL_ATI_texture_float, GL_EXT_abgr, 
    GL_EXT_blend_equation_separate, GL_EXT_draw_buffers2, 
    GL_EXT_draw_instanced, GL_EXT_framebuffer_blit, 
    GL_EXT_framebuffer_multisample, GL_EXT_framebuffer_multisample_blit_scaled, 
    GL_EXT_framebuffer_sRGB, GL_EXT_packed_depth_stencil, GL_EXT_packed_float, 
    GL_EXT_pixel_buffer_object, GL_EXT_provoking_vertex, 
    GL_EXT_shader_integer_mix, GL_EXT_texture_array, 
    GL_EXT_texture_compression_dxt1, GL_EXT_texture_compression_rgtc, 
    GL_EXT_texture_compression_s3tc, GL_EXT_texture_filter_anisotropic, 
    GL_EXT_texture_integer, GL_EXT_texture_sRGB, GL_EXT_texture_sRGB_decode, 
    GL_EXT_texture_shared_exponent, GL_EXT_texture_snorm, 
    GL_EXT_texture_swizzle, GL_EXT_timer_query, GL_EXT_transform_feedback, 
    GL_EXT_vertex_array_bgra, GL_IBM_multimode_draw_arrays, 
    GL_INTEL_performance_query, GL_KHR_debug, GL_MESA_pack_invert, 
    GL_MESA_texture_signed_rgba, GL_NV_conditional_render, GL_NV_depth_clamp, 
    GL_NV_packed_depth_stencil, GL_OES_EGL_image, GL_OES_read_format, 
    GL_S3_s3tc

OpenGL version string: 3.0 Mesa 10.3.0
OpenGL shading language version string: 1.30
OpenGL context flags: (none)
OpenGL extensions:
    GL_3DFX_texture_compression_FXT1, GL_AMD_draw_buffers_blend, 
    GL_AMD_performance_monitor, GL_AMD_seamless_cubemap_per_texture, 
    GL_AMD_shader_trinary_minmax, GL_ANGLE_texture_compression_dxt3, 
    GL_ANGLE_texture_compression_dxt5, GL_APPLE_object_purgeable, 
    GL_APPLE_packed_pixels, GL_APPLE_vertex_array_object, 
    GL_ARB_ES2_compatibility, GL_ARB_ES3_compatibility, 
    GL_ARB_blend_func_extended, GL_ARB_buffer_storage, 
    GL_ARB_clear_buffer_object, GL_ARB_clear_texture, 
    GL_ARB_color_buffer_float, GL_ARB_compressed_texture_pixel_storage, 
    GL_ARB_conditional_render_inverted, GL_ARB_copy_buffer, GL_ARB_copy_image, 
    GL_ARB_debug_output, GL_ARB_depth_buffer_float, GL_ARB_depth_clamp, 
    GL_ARB_depth_texture, GL_ARB_draw_buffers, GL_ARB_draw_buffers_blend, 
    GL_ARB_draw_elements_base_vertex, GL_ARB_draw_instanced, 
    GL_ARB_explicit_attrib_location, GL_ARB_explicit_uniform_location, 
    GL_ARB_fragment_coord_conventions, GL_ARB_fragment_program, 
    GL_ARB_fragment_program_shadow, GL_ARB_fragment_shader, 
    GL_ARB_framebuffer_object, GL_ARB_framebuffer_sRGB, 
    GL_ARB_get_program_binary, GL_ARB_half_float_pixel, 
    GL_ARB_half_float_vertex, GL_ARB_instanced_arrays, 
    GL_ARB_internalformat_query, GL_ARB_invalidate_subdata, 
    GL_ARB_map_buffer_alignment, GL_ARB_map_buffer_range, GL_ARB_multi_bind, 
    GL_ARB_multisample, GL_ARB_multitexture, GL_ARB_occlusion_query, 
    GL_ARB_occlusion_query2, GL_ARB_pixel_buffer_object, 
    GL_ARB_point_parameters, GL_ARB_point_sprite, GL_ARB_provoking_vertex, 
    GL_ARB_robustness, GL_ARB_sample_shading, GL_ARB_sampler_objects, 
    GL_ARB_seamless_cube_map, GL_ARB_seamless_cubemap_per_texture, 
    GL_ARB_separate_shader_objects, GL_ARB_shader_bit_encoding, 
    GL_ARB_shader_objects, GL_ARB_shader_texture_lod, 
    GL_ARB_shading_language_100, GL_ARB_shading_language_420pack, 
    GL_ARB_shading_language_packing, GL_ARB_shadow, GL_ARB_sync, 
    GL_ARB_texture_border_clamp, GL_ARB_texture_compression, 
    GL_ARB_texture_compression_rgtc, GL_ARB_texture_cube_map, 
    GL_ARB_texture_cube_map_array, GL_ARB_texture_env_add, 
    GL_ARB_texture_env_combine, GL_ARB_texture_env_crossbar, 
    GL_ARB_texture_env_dot3, GL_ARB_texture_float, GL_ARB_texture_gather, 
    GL_ARB_texture_mirror_clamp_to_edge, GL_ARB_texture_mirrored_repeat, 
    GL_ARB_texture_multisample, GL_ARB_texture_non_power_of_two, 
    GL_ARB_texture_query_levels, GL_ARB_texture_query_lod, 
    GL_ARB_texture_rectangle, GL_ARB_texture_rg, GL_ARB_texture_rgb10_a2ui, 
    GL_ARB_texture_storage, GL_ARB_texture_storage_multisample, 
    GL_ARB_texture_swizzle, GL_ARB_timer_query, GL_ARB_transpose_matrix, 
    GL_ARB_uniform_buffer_object, GL_ARB_vertex_array_bgra, 
    GL_ARB_vertex_array_object, GL_ARB_vertex_attrib_binding, 
    GL_ARB_vertex_buffer_object, GL_ARB_vertex_program, GL_ARB_vertex_shader, 
    GL_ARB_vertex_type_10f_11f_11f_rev, GL_ARB_vertex_type_2_10_10_10_rev, 
    GL_ARB_window_pos, GL_ATI_blend_equation_separate, GL_ATI_draw_buffers, 
    GL_ATI_separate_stencil, GL_ATI_texture_env_combine3, 
    GL_ATI_texture_float, GL_EXT_abgr, GL_EXT_bgra, GL_EXT_blend_color, 
    GL_EXT_blend_equation_separate, GL_EXT_blend_func_separate, 
    GL_EXT_blend_minmax, GL_EXT_blend_subtract, GL_EXT_compiled_vertex_array, 
    GL_EXT_copy_texture, GL_EXT_draw_buffers2, GL_EXT_draw_instanced, 
    GL_EXT_draw_range_elements, GL_EXT_fog_coord, GL_EXT_framebuffer_blit, 
    GL_EXT_framebuffer_multisample, GL_EXT_framebuffer_multisample_blit_scaled, 
    GL_EXT_framebuffer_object, GL_EXT_framebuffer_sRGB, 
    GL_EXT_gpu_program_parameters, GL_EXT_multi_draw_arrays, 
    GL_EXT_packed_depth_stencil, GL_EXT_packed_float, GL_EXT_packed_pixels, 
    GL_EXT_pixel_buffer_object, GL_EXT_point_parameters, 
    GL_EXT_polygon_offset, GL_EXT_provoking_vertex, GL_EXT_rescale_normal, 
    GL_EXT_secondary_color, GL_EXT_separate_specular_color, 
    GL_EXT_shader_integer_mix, GL_EXT_shadow_funcs, GL_EXT_stencil_two_side, 
    GL_EXT_stencil_wrap, GL_EXT_subtexture, GL_EXT_texture, GL_EXT_texture3D, 
    GL_EXT_texture_array, GL_EXT_texture_compression_dxt1, 
    GL_EXT_texture_compression_rgtc, GL_EXT_texture_compression_s3tc, 
    GL_EXT_texture_cube_map, GL_EXT_texture_edge_clamp, 
    GL_EXT_texture_env_add, GL_EXT_texture_env_combine, 
    GL_EXT_texture_env_dot3, GL_EXT_texture_filter_anisotropic, 
    GL_EXT_texture_integer, GL_EXT_texture_lod_bias, GL_EXT_texture_object, 
    GL_EXT_texture_rectangle, GL_EXT_texture_sRGB, GL_EXT_texture_sRGB_decode, 
    GL_EXT_texture_shared_exponent, GL_EXT_texture_snorm, 
    GL_EXT_texture_swizzle, GL_EXT_timer_query, GL_EXT_transform_feedback, 
    GL_EXT_vertex_array, GL_EXT_vertex_array_bgra, 
    GL_IBM_multimode_draw_arrays, GL_IBM_rasterpos_clip, 
    GL_IBM_texture_mirrored_repeat, GL_INGR_blend_func_separate, 
    GL_INTEL_performance_query, GL_KHR_debug, GL_MESA_pack_invert, 
    GL_MESA_texture_signed_rgba, GL_MESA_window_pos, GL_NV_blend_square, 
    GL_NV_conditional_render, GL_NV_depth_clamp, GL_NV_light_max_exponent, 
    GL_NV_packed_depth_stencil, GL_NV_primitive_restart, 
    GL_NV_texgen_reflection, GL_NV_texture_env_combine4, 
    GL_NV_texture_rectangle, GL_OES_EGL_image, GL_OES_read_format, 
    GL_S3_s3tc, GL_SGIS_generate_mipmap, GL_SGIS_texture_border_clamp, 
    GL_SGIS_texture_edge_clamp, GL_SGIS_texture_lod, GL_SUN_multi_draw_arrays

OpenGL ES profile version string: OpenGL ES 3.0 Mesa 10.3.0
OpenGL ES profile shading language version string: OpenGL ES GLSL ES 3.0
OpenGL ES profile extensions:
    GL_ANGLE_texture_compression_dxt3, GL_ANGLE_texture_compression_dxt5, 
    GL_APPLE_texture_max_level, GL_EXT_blend_minmax, 
    GL_EXT_color_buffer_float, GL_EXT_discard_framebuffer, 
    GL_EXT_map_buffer_range, GL_EXT_multi_draw_arrays, 
    GL_EXT_read_format_bgra, GL_EXT_separate_shader_objects, 
    GL_EXT_shader_integer_mix, GL_EXT_texture_compression_dxt1, 
    GL_EXT_texture_filter_anisotropic, GL_EXT_texture_format_BGRA8888, 
    GL_EXT_texture_rg, GL_EXT_texture_type_2_10_10_10_REV, 
    GL_EXT_unpack_subimage, GL_INTEL_performance_query, GL_NV_draw_buffers, 
    GL_NV_fbo_color_attachments, GL_NV_read_buffer, GL_OES_EGL_image, 
    GL_OES_EGL_image_external, GL_OES_compressed_ETC1_RGB8_texture, 
    GL_OES_depth24, GL_OES_depth_texture, GL_OES_depth_texture_cube_map, 
    GL_OES_element_index_uint, GL_OES_fbo_render_mipmap, 
    GL_OES_get_program_binary, GL_OES_mapbuffer, GL_OES_packed_depth_stencil, 
    GL_OES_rgb8_rgba8, GL_OES_standard_derivatives, GL_OES_stencil8, 
    GL_OES_surfaceless_context, GL_OES_texture_3D, GL_OES_texture_npot, 
    GL_OES_vertex_array_object

16 GLX Visuals
    visual  x   bf lv rg d st  colorbuffer  sr ax dp st accumbuffer  ms  cav
  id dep cl sp  sz l  ci b ro  r  g  b  a F gb bf th cl  r  g  b  a ns b eat
----------------------------------------------------------------------------
0x020 24 tc  0  32  0 r  y .   8  8  8  8 .  .  0 24  8  0  0  0  0  0 0 None
0x021 24 dc  0  32  0 r  y .   8  8  8  8 .  .  0 24  8  0  0  0  0  0 0 None
0x086 24 tc  0  32  0 r  y .   8  8  8  8 .  .  0  0  0  0  0  0  0  0 0 None
0x087 24 tc  0  32  0 r  . .   8  8  8  8 .  .  0  0  0  0  0  0  0  0 0 None
0x088 24 tc  0  32  0 r  . .   8  8  8  8 .  .  0 24  8  0  0  0  0  0 0 None
0x089 24 tc  0  32  0 r  y .   8  8  8  8 .  .  0 24  8 16 16 16 16  0 0 Slow
0x08a 24 tc  0  32  0 r  y .   8  8  8  8 .  .  0  0  0  0  0  0  0  4 1 None
0x08b 24 tc  0  32  0 r  y .   8  8  8  8 .  .  0 24  8  0  0  0  0  4 1 None
0x08c 24 dc  0  32  0 r  y .   8  8  8  8 .  .  0  0  0  0  0  0  0  0 0 None
0x08d 24 dc  0  32  0 r  . .   8  8  8  8 .  .  0  0  0  0  0  0  0  0 0 None
0x08e 24 dc  0  32  0 r  . .   8  8  8  8 .  .  0 24  8  0  0  0  0  0 0 None
0x08f 24 dc  0  32  0 r  y .   8  8  8  8 .  .  0 24  8  0  0  0  0  0 0 None
0x090 24 dc  0  32  0 r  y .   8  8  8  8 .  .  0 24  8 16 16 16 16  0 0 Slow
0x091 24 dc  0  32  0 r  y .   8  8  8  8 .  .  0  0  0  0  0  0  0  4 1 None
0x092 24 dc  0  32  0 r  y .   8  8  8  8 .  .  0 24  8  0  0  0  0  4 1 None
0x061 32 tc  0  32  0 r  y .   8  8  8  8 .  .  0 24  8  0  0  0  0  0 0 None

36 GLXFBConfigs:
    visual  x   bf lv rg d st  colorbuffer  sr ax dp st accumbuffer  ms  cav
  id dep cl sp  sz l  ci b ro  r  g  b  a F gb bf th cl  r  g  b  a ns b eat
----------------------------------------------------------------------------
0x062  0 tc  0  16  0 r  y .   5  6  5  0 .  .  0  0  0  0  0  0  0  0 0 None
0x063  0 tc  0  16  0 r  . .   5  6  5  0 .  .  0  0  0  0  0  0  0  0 0 None
0x064  0 tc  0  16  0 r  y .   5  6  5  0 .  .  0 16  0  0  0  0  0  0 0 None
0x065  0 tc  0  16  0 r  . .   5  6  5  0 .  .  0 16  0  0  0  0  0  0 0 None
0x066  0 tc  0  16  0 r  y .   5  6  5  0 .  .  0 24  8  0  0  0  0  0 0 None
0x067  0 tc  0  16  0 r  . .   5  6  5  0 .  .  0 24  8  0  0  0  0  0 0 None
0x068 24 tc  0  32  0 r  y .   8  8  8  8 .  .  0  0  0  0  0  0  0  0 0 None
0x069 24 tc  0  32  0 r  . .   8  8  8  8 .  .  0  0  0  0  0  0  0  0 0 None
0x06a 24 tc  0  32  0 r  y .   8  8  8  8 .  .  0 24  8  0  0  0  0  0 0 None
0x06b 24 tc  0  32  0 r  . .   8  8  8  8 .  .  0 24  8  0  0  0  0  0 0 None
0x06c  0 tc  0  16  0 r  y .   5  6  5  0 .  .  0 16  0  0  0  0  0  0 0 None
0x06d  0 tc  0  16  0 r  y .   5  6  5  0 .  .  0 16  0 16 16 16  0  0 0 Slow
0x06e 32 tc  0  32  0 r  y .   8  8  8  8 .  .  0 24  8  0  0  0  0  0 0 None
0x06f 24 tc  0  32  0 r  y .   8  8  8  8 .  .  0 24  8 16 16 16 16  0 0 Slow
0x070  0 tc  0  16  0 r  y .   5  6  5  0 .  .  0  0  0  0  0  0  0  4 1 None
0x071  0 tc  0  16  0 r  y .   5  6  5  0 .  .  0 16  0  0  0  0  0  4 1 None
0x072 24 tc  0  32  0 r  y .   8  8  8  8 .  .  0  0  0  0  0  0  0  4 1 None
0x073 24 tc  0  32  0 r  y .   8  8  8  8 .  .  0 24  8  0  0  0  0  4 1 None
0x074  0 dc  0  16  0 r  y .   5  6  5  0 .  .  0  0  0  0  0  0  0  0 0 None
0x075  0 dc  0  16  0 r  . .   5  6  5  0 .  .  0  0  0  0  0  0  0  0 0 None
0x076  0 dc  0  16  0 r  y .   5  6  5  0 .  .  0 16  0  0  0  0  0  0 0 None
0x077  0 dc  0  16  0 r  . .   5  6  5  0 .  .  0 16  0  0  0  0  0  0 0 None
0x078  0 dc  0  16  0 r  y .   5  6  5  0 .  .  0 24  8  0  0  0  0  0 0 None
0x079  0 dc  0  16  0 r  . .   5  6  5  0 .  .  0 24  8  0  0  0  0  0 0 None
0x07a 24 dc  0  32  0 r  y .   8  8  8  8 .  .  0  0  0  0  0  0  0  0 0 None
0x07b 24 dc  0  32  0 r  . .   8  8  8  8 .  .  0  0  0  0  0  0  0  0 0 None
0x07c 24 dc  0  32  0 r  y .   8  8  8  8 .  .  0 24  8  0  0  0  0  0 0 None
0x07d 24 dc  0  32  0 r  . .   8  8  8  8 .  .  0 24  8  0  0  0  0  0 0 None
0x07e  0 dc  0  16  0 r  y .   5  6  5  0 .  .  0 16  0  0  0  0  0  0 0 None
0x07f  0 dc  0  16  0 r  y .   5  6  5  0 .  .  0 16  0 16 16 16  0  0 0 Slow
0x080 24 dc  0  32  0 r  y .   8  8  8  8 .  .  0 24  8  0  0  0  0  0 0 None
0x081 24 dc  0  32  0 r  y .   8  8  8  8 .  .  0 24  8 16 16 16 16  0 0 Slow
0x082  0 dc  0  16  0 r  y .   5  6  5  0 .  .  0  0  0  0  0  0  0  4 1 None
0x083  0 dc  0  16  0 r  y .   5  6  5  0 .  .  0 16  0  0  0  0  0  4 1 None
0x084 24 dc  0  32  0 r  y .   8  8  8  8 .  .  0  0  0  0  0  0  0  4 1 None
0x085 24 dc  0  32  0 r  y .   8  8  8  8 .  .  0 24  8  0  0  0  0  4 1 None
Comment 8 Martin Flöser 2015-01-07 15:53:30 UTC
support information when broken:
Version
=======
KWin version: 5.1.90
Qt Version: 5.4.0

Operation Mode: X11 only

Decoration
==========
Plugin: org.kde.breeze
Theme: 
Blur: 0
onAllDesktopsAvailable: false
alphaChannelSupported: true
closeOnDoubleClickOnMenu: false
decorationButtonsLeft: 0, 2
decorationButtonsRight: 6, 3, 4, 5
borderSize: 3
gridUnit: 10
font: Oxygen-Sans,10,-1,0,50,0,0,0,0,0
smallSpacing: 2
largeSpacing: 10

Options
=======
focusPolicy: 0
nextFocusPrefersMouse: false
clickRaise: true
autoRaise: false
autoRaiseInterval: 0
delayFocusInterval: 0
shadeHover: false
shadeHoverInterval: 250
separateScreenFocus: false
placement: 4
focusPolicyIsReasonable: true
borderSnapZone: 10
windowSnapZone: 10
centerSnapZone: 0
snapOnlyWhenOverlapping: false
showDesktopIsMinimizeAll: false
rollOverDesktops: true
focusStealingPreventionLevel: 1
legacyFullscreenSupport: false
operationTitlebarDblClick: 5000
operationMaxButtonLeftClick: 5000
operationMaxButtonMiddleClick: 5015
operationMaxButtonRightClick: 5014
commandActiveTitlebar1: 0
commandActiveTitlebar2: 30
commandActiveTitlebar3: 2
commandInactiveTitlebar1: 4
commandInactiveTitlebar2: 30
commandInactiveTitlebar3: 2
commandWindow1: 7
commandWindow2: 8
commandWindow3: 8
commandWindowWheel: 31
commandAll1: 10
commandAll2: 3
commandAll3: 14
keyCmdAllModKey: 16777251
showGeometryTip: false
condensedTitle: false
electricBorderMaximize: true
electricBorderTiling: true
electricBorderCornerRatio: 0.25
borderlessMaximizedWindows: false
killPingTimeout: 5000
hideUtilityWindowsForInactive: true
inactiveTabsSkipTaskbar: false
autogroupSimilarWindows: false
autogroupInForeground: true
compositingMode: 1
useCompositing: true
compositingInitialized: true
hiddenPreviews: 1
unredirectFullscreen: false
glSmoothScale: 2
colorCorrected: false
xrenderSmoothScale: false
maxFpsInterval: 16666666
refreshRate: 0
vBlankTime: 6000000
glStrictBinding: true
glStrictBindingFollowsDriver: true
glCoreProfile: false
glPreferBufferSwap: 101
glPlatformInterface: 1

Screen Edges
============
desktopSwitching: false
desktopSwitchingMovingClients: false
cursorPushBackDistance: 1x1
timeThreshold: 150
reActivateThreshold: 350
actionTopLeft: 0
actionTop: 0
actionTopRight: 0
actionRight: 0
actionBottomRight: 0
actionBottom: 0
actionBottomLeft: 0
actionLeft: 0

Screens
=======
Multi-Head: no
Active screen follows mouse:  no
Number of Screens: 1
Screen 0 Geometry: 0,0,1366x768

Compositing
===========
Compositing is active
Compositing Type: OpenGL
OpenGL vendor string: Intel Open Source Technology Center
OpenGL renderer string: Mesa DRI Intel(R) Sandybridge Mobile 
OpenGL version string: 3.0 Mesa 10.3.0
OpenGL platform interface: GLX
OpenGL shading language version string: 1.30
Driver: Intel
GPU class: SandyBridge
OpenGL version: 3.0
GLSL version: 1.30
Mesa version: 10.3
X server version: 1.16
Linux kernel version: 3.16
Direct rendering: Requires strict binding: yes
GLSL shaders:  yes
Texture NPOT support:  yes
Virtual Machine:  no
OpenGL 2 Shaders are used
Painting blocks for vertical retrace:  no

Loaded Effects:
---------------
zoom
slidingpopups
kwin4_effect_login
slide
screenshot
minimizeanimation
kwin4_effect_translucency
desktopgrid
kwin4_effect_fade
kwin4_effect_maximize
presentwindows
kwin4_effect_dialogparent
highlightwindow
blur
contrast
logout
dashboard
startupfeedback
screenedge
kscreen

Currently Active Effects:
-------------------------
blur
contrast

Effect Settings:
----------------
zoom:
zoomFactor: 1.2
mousePointer: 0
mouseTracking: 0
enableFocusTracking: false
followFocus: true
focusDelay: 350
moveFactor: 20
targetZoom: 1

slidingpopups:
fadeInTime: 150
fadeOutTime: 250

kwin4_effect_login:

slide:

screenshot:

minimizeanimation:

kwin4_effect_translucency:

desktopgrid:
zoomDuration: 300
border: 10
desktopNameAlignment: 0
layoutMode: 0
customLayoutRows: 2
usePresentWindows: true

kwin4_effect_fade:

kwin4_effect_maximize:

presentwindows:
layoutMode: 0
showCaptions: true
showIcons: true
doNotCloseWindows: false
ignoreMinimized: false
accuracy: 20
fillGaps: true
fadeDuration: 150
showPanel: false
leftButtonWindow: 1
rightButtonWindow: 2
middleButtonWindow: 0
leftButtonDesktop: 2
middleButtonDesktop: 0
rightButtonDesktop: 0

kwin4_effect_dialogparent:

highlightwindow:

blur:
blurRadius: 12
cacheTexture: true

contrast:

logout:
useBlur: true

dashboard:
brightness: 0.5
saturation: 0.5
blur: false

startupfeedback:
type: 1

screenedge:

kscreen:
Comment 9 Martin Flöser 2015-01-07 15:54:43 UTC
I'm wondering whether 38f1945c6c437cad14e9c22929ab7947009de8e5 could be the cause.
Comment 10 Kakadu.hafanana 2015-01-07 16:26:21 UTC
The same to me: c) and d) doesn't help.
With EGL I can press A+S-F12 but it doesn't affect anything. If I look at system settings it seems that compositing _is_ enabled. Maybe I'm looking into wrong screen... http://wstaw.org/m/2015/01/07/kde1.png
Comment 11 Thomas Lübking 2015-01-07 17:08:01 UTC
(In reply to Martin Gräßlin from comment #9)
> I'm wondering whether 38f1945c6c437cad14e9c22929ab7947009de8e5 could be the
> cause.

I could assume so, turning of "tearing prevention" should then do.

(In reply to Kakadu.hafanana from comment #10)
> If I look at system settings it seems that compositing _is_ enabled.
"... on startup" ;-)

The setting just *tries* to start the compositor w/ kwin - this can still fail.
If you uncheck this, it's not even tried (eg. because you could compose, but don't want to for whatever reason)
Comment 12 David Edmundson 2015-01-07 17:34:09 UTC
Managed to reproduce on a machine

reverting 38f1945c6c437cad14e9c22929ab7947009de8e5 made no difference.
Comment 13 David Edmundson 2015-01-07 17:52:56 UTC
we're not calling bufferSwapComplete()

I then put some debug into 
SwapEventFilter::event(xcb_generic_event_t *event), 

it's failing the test:
     if (ev->drawable == m_drawable) {


if I comment this out, everything works fine and I have sexy compositing again.

Obviously I don't think this is a solution, I assume this is checking that the buffer swapped was the one we're meant to be monitoring.. but it's where the issue is.
Comment 14 David Edmundson 2015-01-07 18:34:18 UTC
Aha, and I see why this is a new bug

        // Qt 5.3 doesn't forward swap events to the native event filter
        if (version < 0x00050400)
            m_haveINTELSwapEvent = false;

so before we were just falling back to some other swap test method; no we're using this one, but it seems to be rubbish.
Comment 15 Thomas Lübking 2015-01-07 21:41:29 UTC
This looks fishy:

if (m_haveINTELSwapEvent) {
        m_swapEventFilter = std::make_unique<SwapEventFilter>(window);
        glXSelectEvent(display(), glxWindow, GLX_BUFFER_SWAP_COMPLETE_INTEL_MASK);
    }

we select events on glxWindow but compare the event window with window.

Since the events are apparently read, could you try
-        m_swapEventFilter = std::make_unique<SwapEventFilter>(window);
+        m_swapEventFilter = std::make_unique<SwapEventFilter>(glxWindow);
?
Comment 16 David Edmundson 2015-01-07 22:05:48 UTC
Yeah, that does look odd, would fit my symptoms exactly.

I can't test now, I need a specific machine which I don't have here, but I'll do so tomorrow morning.
Comment 17 Fredrik Höglund 2015-01-08 06:16:35 UTC
Created attachment 90283 [details]
glx: Fix the swap event filter for DRI3 drivers

Does this patch fix the problem?
Comment 18 David Edmundson 2015-01-08 10:16:31 UTC
Works beautifully to me, code looks sensible too.

Can we ship it?
Comment 19 David Edmundson 2015-01-08 10:18:03 UTC
Possibly related, my .xsession-errors is full of 

_xgeWireToEvent: Unknown extension 148, this should never happen.

you mentioned glXWireToEvent in your patch so this seems very important?
Comment 20 David Edmundson 2015-01-08 13:21:38 UTC
5.2 beta is being tagged imminently so I'm going to push Frederick's change as-is so it makes it into the beta.

Hope that's ok with everyone.
Comment 21 David Edmundson 2015-01-08 13:21:49 UTC
Git commit 301a9965638376a7edfb052ed8640a2f88290b81 by David Edmundson, on behalf of Fredrik Höglund.
Committed on 08/01/2015 at 06:12.
Pushed by davidedmundson into branch 'master'.

glx: Fix the swap event filter for DRI3 drivers

The drawable field is set to the X drawable ID when the swap event is
synthesized by DRI2WireToEvent(), and the GLX drawable ID when the
event is received over the wire. The latter being the case with DRI3.

__glXWireToEvent() fixes this for Xlib clients by changing the field
to the X drawable ID. This doesn't work for xcb clients however,
so we have to expect the field to be set to either the X or the GLX
drawable ID.

M  +8    -5    glxbackend.cpp
M  +3    -1    glxbackend.h

http://commits.kde.org/kwin/301a9965638376a7edfb052ed8640a2f88290b81
Comment 22 Jan Grulich 2015-01-09 15:22:34 UTC
*** Bug 341972 has been marked as a duplicate of this bug. ***
Comment 23 Martin Flöser 2015-01-12 06:49:01 UTC
Over the weekend I got a complaint that it still freezes on Haswell-ULT chips. As this is a quite severe issue I suggest that we disable the feature for 5.2, keep it enabled in master and stabilize it for 5.3. Due to the Qt 5.4 dependency it went into the release without any prior testing and we are currently not really able to debug and investigate issues.
Comment 24 Fredrik Höglund 2015-01-12 09:12:03 UTC
(In reply to Martin Gräßlin from comment #23)
> ...Due to the Qt 5.4 dependency it went into the release without any prior testing and we are
> currently not really able to debug and investigate issues.

Unless of course you count myself and every other KDE developer who have been using kwin with Mesa drivers and Qt 5.4 for the past several months.

Did the reporter specifically say that this feature is responsible? There are numerous bug reports about freezes that have never been properly investigated, and that predate the use of swap events in kwin.
Comment 25 Martin Flöser 2015-01-12 09:18:50 UTC
I upgraded my notebook to Qt 5.4 this morning and there I also get the freeze and it's clearly related to the feature. Disabling it unfreezes the system. Also on my main system I experienced heavy rendering errors lately, by disabling the feature all of them were instantly gone. So yes, I think this is heavily related and not sufficiently tested.
Comment 26 Fredrik Höglund 2015-01-12 10:00:35 UTC
(In reply to Martin Gräßlin from comment #25)
> I upgraded my notebook to Qt 5.4 this morning and there I also get the
> freeze and it's clearly related to the feature. Disabling it unfreezes the
> system. Also on my main system I experienced heavy rendering errors lately,
> by disabling the feature all of them were instantly gone. So yes, I think
> this is heavily related and not sufficiently tested.

If you are able to reproduce the problem on a computer you own and have access to, then I have to say that I really don't understand what you mean by "we are currently not really able to debug and investigate issues."
Comment 27 Martin Flöser 2015-01-12 10:17:54 UTC
that comment was written before I installed Qt 5.4 on that system.
Comment 28 Thomas Lübking 2015-01-12 12:07:55 UTC
pending issues could be related to driver (version) bugs (and actually hardware combos - i've seen an r100 notebook that did glxgears @0.5 fps - turned out it was the driver-enabled swapinterval...)

given the valid concerns about the test sample size, i'd suggest to have this feature env controlled and default the env depending on the risk one is willing to take for the particular version (eg 1 for git master and 0 for releases)
Comment 29 Martin Flöser 2015-01-12 13:31:15 UTC
Git commit fcd8cf3adaa4153c0da6e5245db8e8073fe824bf by Martin Gräßlin.
Committed on 12/01/2015 at 07:46.
Pushed by graesslin into branch 'Plasma/5.2'.

[glxbackend] Introduce env variable KWIN_USE_INTEL_SWAP_EVENT

The feature is pretty much untested as it depends on Qt 5.4 and this
was not a requirement during the development of 5.2. On the other hand
regressions in this feature are very severe as it can freeze the screen
and by that render the system unusable.

This change disables the feature by default. To enable it use the
environment variable KWIN_USE_INTEL_SWAP_EVENT=1.
REVIEW: 122008

M  +3    -1    glxbackend.cpp

http://commits.kde.org/kwin/fcd8cf3adaa4153c0da6e5245db8e8073fe824bf
Comment 30 kde 2015-01-12 17:25:16 UTC
(In reply to David Edmundson from comment #19)
> _xgeWireToEvent: Unknown extension 148, this should never happen.

this is steams fault: https://github.com/ValveSoftware/steam-for-linux/issues/3364
Comment 31 kde 2015-01-12 17:39:18 UTC
(In reply to David Edmundson from comment #21)
> Git commit 301a9965638376a7edfb052ed8640a2f88290b81 by David Edmundson, on
> behalf of Fredrik Höglund.
> Committed on 08/01/2015 at 06:12.
> Pushed by davidedmundson into branch 'master'.
> 
> glx: Fix the swap event filter for DRI3 drivers
> 
> The drawable field is set to the X drawable ID when the swap event is
> synthesized by DRI2WireToEvent(), and the GLX drawable ID when the
> event is received over the wire. The latter being the case with DRI3.
> 
> __glXWireToEvent() fixes this for Xlib clients by changing the field
> to the X drawable ID. This doesn't work for xcb clients however,
> so we have to expect the field to be set to either the X or the GLX
> drawable ID.
> 
> M  +8    -5    glxbackend.cpp
> M  +3    -1    glxbackend.h
> 
> http://commits.kde.org/kwin/301a9965638376a7edfb052ed8640a2f88290b81

Thanks, this patch fixed this issue for me.
Comment 32 Martin Flöser 2015-04-09 10:24:43 UTC
removing release_blocker and critical as the bug is worked around. Though still needs proper fixing of course.
Comment 33 Roman Gilg 2019-08-12 00:37:05 UTC
As a heads-up I maybe will enabling it again by default. On two systems I have, AMD and Intel, the extension is present and KWin works with the env var set fine.

From how I understand it we lose quite a lot of robustness by not syncing with the X present complete notify on vblank through this extension.
Comment 34 Roman Gilg 2019-12-12 00:57:28 UTC
Git commit e7da4d65ecbd7dea164a86aa355632ffe156e6c4 by Roman Gilg.
Committed on 12/12/2019 at 00:57.
Pushed by romangilg into branch 'master'.

[platforms/x11/standalone] Use intel swap events by default

Summary:
Activate intel swap events by default if available. They were hidden behind an
environmental variable because of some critical release blocking issue years
ago.

Manual testing indicates that there are no issues anymore with this extension.
Since it allows us to use swap events with MESA drivers for optimized repaints
enable swap events by default again.

For now leave a modified environment variable to switch back to using no swap
events easily.

Test Plan: i915

Reviewers: #kwin

Subscribers: zzag, broulik, kwin

Tags: #kwin

Maniphest Tasks: T11071

Differential Revision: https://phabricator.kde.org/D25300

M  +3    -2    plugins/platforms/x11/standalone/glxbackend.cpp

https://commits.kde.org/kwin/e7da4d65ecbd7dea164a86aa355632ffe156e6c4
Comment 35 David Edmundson 2023-11-11 22:43:35 UTC
This is very old and changes have been made, please confirm if this is still an issue