Build failure on i386 on Ubuntu cosmic. Builds fine on amd64 and also on i386 Ubuntu bionic. Full build log: https://launchpadlibrarian.net/412075109/buildlog_ubuntu-cosmic-i386.xserver-xorg-video-intel_2%3A2.99.917+git1902201253.33ee0c~oibaf~c_BUILDING.txt.gz Error: In file included from ../../../src/sna/gen4_vertex.c:34: ../../../src/sna/gen4_vertex.c: In function ‘emit_vertex’: ../../../src/sna/sna_render_inline.h:40:26: error: inlining failed in call to always_inline ‘vertex_emit_2s’: target specific option mismatch static force_inline void vertex_emit_2s(struct sna *sna, int16_t x, int16_t y) ^~~~~~~~~~~~~~ ../../../src/sna/gen4_vertex.c:308:25: note: called from here #define OUT_VERTEX(x,y) vertex_emit_2s(sna, x,y) /* XXX assert(!too_large(x, y)); */ ^~~~~~~~~~~~~~~~~~~~~~~~ ../../../src/sna/gen4_vertex.c:360:2: note: in expansion of macro ‘OUT_VERTEX’ OUT_VERTEX(dstX, dstY); ^~~~~~~~~~ make[5]: *** [Makefile:695: gen4_vertex.lo] Error 1
Is it not the same old compiler bug for not handling target attributes across translation units?
Yes, actually it is an old bug, distros added patch to workaroud this: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=909860 https://bugzilla.suse.com/show_bug.cgi?id=1092541 https://src.fedoraproject.org/rpms/xorg-x11-drv-intel/c/f2e86334f3a168b04afddb57d4bc4f630e59a5e9 Can it be addressed in -intel?
commit 9e6e003e3468dca674ac848e2669af973da02fd4 (origin/master, origin/HEAD) Author: Adam Jackson <ajax@redhat.com> Date: Tue Mar 6 12:07:46 2018 -0500 Fix build on i686 Presumably this only matters for i686 because amd64 implies sse2, but: BUILDSTDERR: In file included from gen4_vertex.c:34: BUILDSTDERR: gen4_vertex.c: In function 'emit_vertex': BUILDSTDERR: sna_render_inline.h:40:26: error: inlining failed in call to al ways_inline 'vertex_emit_2s': target specific option mismatch BUILDSTDERR: static force_inline void vertex_emit_2s(struct sna *sna, int16 _t x, int16_t y) BUILDSTDERR: ^~~~~~~~~~~~~~ BUILDSTDERR: gen4_vertex.c:308:25: note: called from here BUILDSTDERR: #define OUT_VERTEX(x,y) vertex_emit_2s(sna, x,y) /* XXX assert (!too_large(x, y)); */ BUILDSTDERR: ^~~~~~~~~~~~~~~~~~~~~~~~ BUILDSTDERR: gen4_vertex.c:360:2: note: in expansion of macro 'OUT_VERTEX' BUILDSTDERR: OUT_VERTEX(dstX, dstY); BUILDSTDERR: ^~~~~~~~~~ The bug here appears to be that emit_vertex() is declared 'sse2' but vertex_emit_2s is merely always_inline. gcc8 decides that since you said always_inline you need to have explicitly cloned it for every permutation of targets. Merely saying inline seems to do the job of cloning vertex_emit_2s as much as necessary. So to reiterate: if you say always-inline, it won't, but if you just say maybe inline, it will. Thanks gcc, that's helpful.
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.