-
Notifications
You must be signed in to change notification settings - Fork 84
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
GIR XML is architecture-dependent, perhaps unnecessarily? #211
Comments
smcv
added a commit
to smcv/graphene
that referenced
this issue
Feb 12, 2021
Exposing the various #mesondefine'd constants results in the GIR XML unnecessarily varying between architectures. Conversely, GObject-Introspection's rather simplistic cpp parser thinks GRAPHENE_SIMD_S is always defined to "sse", even on architectures where it should not be. Introspected code is not going to be able to use SIMD anyway, so this doesn't seem to have any value. Resolves: ebassi#211 Signed-off-by: Simon McVittie <[email protected]>
smcv
added a commit
to smcv/graphene
that referenced
this issue
Feb 12, 2021
Exposing the various #mesondefine'd constants results in the GIR XML unnecessarily varying between architectures. Conversely, GObject-Introspection's rather simplistic cpp parser thinks GRAPHENE_SIMD_S is always defined to "sse", even on architectures where it should not be. Introspected code is not going to be able to use SIMD anyway, so this doesn't seem to have any value. Resolves: ebassi#211 Signed-off-by: Simon McVittie <[email protected]>
ebassi
pushed a commit
that referenced
this issue
Feb 12, 2021
Exposing the various #mesondefine'd constants results in the GIR XML unnecessarily varying between architectures. Conversely, GObject-Introspection's rather simplistic cpp parser thinks GRAPHENE_SIMD_S is always defined to "sse", even on architectures where it should not be. Introspected code is not going to be able to use SIMD anyway, so this doesn't seem to have any value. Resolves: #211 Signed-off-by: Simon McVittie <[email protected]>
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Experienced behavior
Graphene-1.0.gir conditionally defines
Graphene.HAS_GCC
,Graphene.HAS_SCALAR
,Graphene.HAS_SSE
constants fromgraphene-config.h
.On multiarch/multilib systems, this makes it one of the few GIR XML files that varies between architectures. Since GIR XML usually goes in /usr/share, this means it will either conflict between architectures, or give the wrong answer when asked about one of the architectures on a multiarch/multilib system.
(I know that the GIR XML for GLib also varies between architectures, but that one is easier to special-case since it comes from the gobject-introspection package.)
It looks as though
Graphene.SIMD_S
is also defined, and that one seems to be unconditionallysse
even on non-x86, due to gobject-introspection's parser being fairly limited:Expected behavior
These constants don't seem very useful to introspected code, so perhaps they should be omitted from the GIR XML.
Steps to reproduce
diff
Operating system in use
Debian unstable (rolling release / Debian 11 alpha)
SIMD implementation in use
Various - that's the problem :-)
The text was updated successfully, but these errors were encountered: