Bug 110408 - Lima cannot handle too many vertices because of limited pre-allocated buffer
Summary: Lima cannot handle too many vertices because of limited pre-allocated buffer
Status: RESOLVED MOVED
Alias: None
Product: Mesa
Classification: Unclassified
Component: Drivers/Gallium/Lima (show other bugs)
Version: git
Hardware: ARM Linux (All)
: medium normal
Assignee: mesa-dev
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2019-04-12 06:15 UTC by Icenowy Zheng
Modified: 2019-09-18 18:35 UTC (History)
0 users

See Also:
i915 platform:
i915 features:


Attachments

Description Icenowy Zheng 2019-04-12 06:15:26 UTC
When I try to run the bump:bump-render=high-poly test of glmark2-es2-drm on Lima, it crashes with a segfault.

The backtrace shows:
                #0  0x0000ffffb3ab03e0 lima_ctx_buff_va (sun4i-drm_dri.so)
                #1  0x0000ffffb3ab43b4 lima_update_varying (sun4i-drm_dri.so)
                #2  0x0000ffffb3619304 u_vbuf_draw_vbo (sun4i-drm_dri.so)
                #3  0x0000ffffb37b15e4 st_draw_vbo (sun4i-drm_dri.so)
                #4  0x0000ffffb3852938 _mesa_draw_arrays (sun4i-drm_dri.so)
                #5  0x0000aaaade1d3954 _ZN4Mesh10render_vboEv (glmark2-es2-drm)
                #6  0x0000aaaade16dce4 _ZN9SceneBump4drawEv (glmark2-es2-drm)
                #7  0x0000aaaade156d10 _ZN8MainLoop4drawEv (glmark2-es2-drm)
                #8  0x0000aaaade157540 _ZN8MainLoop4stepEv (glmark2-es2-drm)
                #9  0x0000aaaade14aca0 _Z12do_benchmarkR6Canvas (glmark2-es2-drm)
                #10 0x0000aaaade148948 main (glmark2-es2-drm)
                #11 0x0000ffffb400c638 __libc_start_main (libc.so.6)
                #12 0x0000aaaade14aaf0 $x (glmark2-es2-drm)
                #13 0x0000aaaade14aaf0 $x (glmark2-es2-drm)

From inspection, lima_ctx_buff_va seems to be refering to a context buffer that haven't been successfully allocated, and in lima_update_varying() the allocation failure seems to be because the requested memory size is too big (because the vertex count is big, 144000 for bump:bump-render=high-poly).

Should we use some better way than u_suballocator to allocate the memory for the varying storage?
Comment 1 GitLab Migration User 2019-09-18 18:35:41 UTC
-- GitLab Migration Automatic Message --

This bug has been migrated to freedesktop.org's GitLab instance and has been closed from further activity.

You can subscribe and participate further through the new bug through this link to our GitLab instance: https://gitlab.freedesktop.org/mesa/mesa/issues/257.


Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.