|
Bugzilla – Full Text Bug Listing |
| Summary: | mesa quite big | ||
|---|---|---|---|
| Product: | [openSUSE] openSUSE 10.3 | Reporter: | Dirk Mueller <dmueller> |
| Component: | X.Org | Assignee: | Dirk Mueller <dmueller> |
| Status: | RESOLVED FIXED | QA Contact: | Stefan Dirsch <sndirsch> |
| Severity: | Normal | ||
| Priority: | P2 - High | CC: | eich, sndirsch |
| Version: | Alpha 3plus | ||
| Target Milestone: | --- | ||
| Hardware: | Other | ||
| OS: | Other | ||
| Whiteboard: | |||
| Found By: | Other | Services Priority: | |
| Business Priority: | Blocker: | --- | |
| Marketing QA Status: | --- | IT Deployment: | --- |
| Bug Depends on: | |||
| Bug Blocks: | 273170 | ||
| Attachments: |
dependency graph (rpm size)
link-shared.diff |
||
|
Description
Dirk Mueller
2007-05-09 18:08:44 UTC
This sounds strange since it's the libGL which dlopen's the DRI drivers. But you're right, each DRI driver is much bigger than libGL. But I'm afraid we can't easily change this. What we could do is disabling DRI driver, which nobody uses or cannot work at all. I need to figure out which ones these are. Currently we build: /usr/lib/dri/ffb_dri.so /usr/lib/dri/i810_dri.so /usr/lib/dri/i915_dri.so /usr/lib/dri/i915tex_dri.so /usr/lib/dri/i965_dri.so /usr/lib/dri/mach64_dri.so /usr/lib/dri/mga_dri.so /usr/lib/dri/r128_dri.so /usr/lib/dri/r200_dri.so /usr/lib/dri/r300_dri.so /usr/lib/dri/radeon_dri.so /usr/lib/dri/s3v_dri.so /usr/lib/dri/savage_dri.so /usr/lib/dri/tdfx_dri.so /usr/lib/dri/trident_dri.so /usr/lib/dri/unichrome_dri.so Each one about 2,5 MB. (In reply to comment #1) > /usr/lib/dri/ffb_dri.so Only used on SUN/Solaris AFAIk. --> Drop > /usr/lib/dri/i810_dri.so Still used by i810/i815 AFAIK (16bit only) > /usr/lib/dri/i915_dri.so > /usr/lib/dri/i915tex_dri.so 830/845/855/865/915G/915GM/945G/945GM (which of these two drivers?) > /usr/lib/dri/i965_dri.so 965G/965GM > /usr/lib/dri/mach64_dri.so ATI Mach64. No upstream DRM kernel module. Cannot work. --> Drop /usr/lib/dri/mga_dri.so Matrox. /usr/lib/dri/r128_dri.so ATI Rage 128 /usr/lib/dri/r200_dri.so ATI R200 /usr/lib/dri/r300_dri.so ATI R300 <= x < ATI R500 > /usr/lib/dri/radeon_dri.so ATI Radeon > /usr/lib/dri/s3v_dri.so S3 ViRGE. No DRM upstream kernel module. Cannot work. --> Drop > /usr/lib/dri/savage_dri.so S3 Savage. > /usr/lib/dri/tdfx_dri.so 3Dfx. > /usr/lib/dri/trident_dri.so Trident. No DRM upstream kernel module. Cannot work. --> Drop > /usr/lib/dri/unichrome_dri.so VIA. > > /usr/lib/dri/i915_dri.so
> > /usr/lib/dri/i915tex_dri.so
> 830/845/855/865/915G/915GM/945G/945GM (which of these two drivers?)
We need both.
# man intel
[...]
Option "Legacy3D" "boolean"
Enable support for the legacy i915_dri.so 3D driver. This will,
among other things, make the 2D driver tell libGL to load the 3D
driver i915_dri.so instead of the newer i915tex_dri.so. This
option is only used for chipsets in the range i830-i945.
Default for i830-i945 series: Enabled for i915 drm versions <
1.7.0. Otherwise disabled. Default for i810: The option is not
used. Default for i965: The option is always true.
given that dri 1.7 support isn't there in our kernel, I guess one of it can be dropped. from the build log:
../../../../../bin/mklib -noprefix -o i915tex_dri.so \
../../common/driverfuncs.o ../common/utils.o ../common/texmem.o ../common/vblank.o ../common/dr
i_util.o ../common/xmlconfig.o ../common/drirenderbuffer.o ../common/dri_bufmgr.o ../common/dri_drmpool.o i830_
context.o i830_metaops.o i830_state.o i830_texblend.o i830_tex.o i830_texstate.o i830_vtbl.o intel_render.o int
el_regions.o intel_buffer_objects.o intel_batchbuffer.o intel_mipmap_tree.o i915_tex_layout.o intel_tex_layout.
o intel_tex_image.o intel_tex_subimage.o intel_tex_copy.o intel_tex_validate.o intel_tex_format.o intel_tex.o i
ntel_pixel.o intel_pixel_copy.o intel_pixel_read.o intel_pixel_draw.o intel_buffers.o intel_blit.o i915_tex.o i
915_texstate.o i915_context.o i915_debug.o i915_fragprog.o i915_metaops.o i915_program.o i915_state.o i915_vtbl
.o intel_context.o intel_ioctl.o intel_rotate.o intel_screen.o intel_span.o intel_state.o intel_tris.o intel_fb
o.o intel_depthstencil.o intel_batchpool.o ../../../../../src/mesa/libmesa.a -L/usr/X11R6/lib -lm -lpthread
-lexpat -ldl `pkg-config --libs libdrm`
this is the same for all of those _dri drivers.
two things to observe:
a) all dri drivers link stuff from ../common/*.o directly
b) all of them link ../../../../../src/mesa/libmesa.a
using a shared lib for libmesa and linking it instead of including the whole archive into each dri lib should significantly reduce size, so that we don't have to drop some of the dri drivers.
(In reply to comment #4) > given that dri 1.7 support isn't there in our kernel, I guess one of it can > be dropped. Well. I still hope to get this in the kernel until openSUSE 10.3 will be released. The linking issue should be discussed upstream. Actually it looks strange. I'd like to first find out why it is done the way it is done. right now Mesa is 15% of the size of kdebase3-SuSE and its dependencies. thats quite a lot. Created attachment 138984 [details]
dependency graph (rpm size)
(In reply to comment #2) > > /usr/lib/dri/i915_dri.so > > /usr/lib/dri/i915tex_dri.so > 830/845/855/865/915G/915GM/945G/945GM (which of these two drivers?) i915tex is the new (beta) driver, using the new memory manager. > > /usr/lib/dri/tdfx_dri.so > 3Dfx. Kick it. This is truly legacy. (In reply to comment #4) > given that dri 1.7 support isn't there in our kernel, I guess one of it can be > dropped. I assume that will soon be here, then we need both. No need to nuke it for a single openSUSE version. (In reply to comment #8) > I'd like to first find out why it is done the way it is done. right now Mesa is > 15% of the size of kdebase3-SuSE and its dependencies. thats quite a lot. Agreed. I asked on the mailing list. > > > /usr/lib/dri/tdfx_dri.so
> > 3Dfx.
> Kick it. This is truly legacy.
Indeed. We no longer support 3D support with 3Dfx cards.
Dirk, just for my convenience :-). Could you attach your patch? Thanks. Created attachment 139739 [details]
link-shared.diff
15MB -> 3.7MB rpmsize. i386 tested, other platforms untested.
Patch applied. Fixed. (In reply to comment #20) > Patch applied. Fixed. Updated to this package lately and it does not seem to work for me. Xorg says DRI is enabled but glxinfo doesn't agree. Somehow, the problem seems to be related to this shared library modification. Trying to enable AIGLX or enabling LIBGL_DEBUG results in the following message (in Xorg.log and stderr respectively): libGL error: dlopen /usr/lib/dri/r200_dri.so failed (/usr/lib/dri/r200_dri.so: undefined symbol: _generic_read_RGBA_span_RGB565_MMX) After looking around, this symbol is in libmesa_private, but nm says it is local (not external): > nm /usr/lib/libmesa_private.so.1.0 | grep _generic_read_RGBA_span_RGB565_MMX 00187cf0 t _generic_read_RGBA_span_RGB565_MMX ...so the linker resolution fails. Maybe I'm missing something... But I'll dare re-open this bug just in case... Sorry if this comment had nothing to do here. *grmbl*. mesa doesn't even build modules with -Wl,--no-undefined. x86 is fixed, now testing the other platforms ->FIXED Thanks, Dirk. |