Emil Velikov <emil.l.veli...@gmail.com> writes: > Hi Aaron, > > On 1 March 2018 at 19:44, Aaron Watry <awa...@gmail.com> wrote: >> Useful for testing API, builtin library, and device completeness of >> not-yet-supported versions. >> > Small fly-by comment: > > As-is it seems like getenv(foo) will be called multiple times. > Perhaps it isn't that 'slow' since it's not a hot path. > > Yet again, one could get different version across calls which does sound icky. > > Perhaps it's not worth bothering about?
These are far from hot paths... But if you care a trivial solution would be to mark version_string and friends as static const, so the initializer is only evaluated once. > Emil > _______________________________________________ > mesa-dev mailing list > firstname.lastname@example.org > https://lists.freedesktop.org/mailman/listinfo/mesa-dev
Description: PGP signature
_______________________________________________ mesa-dev mailing list email@example.com https://lists.freedesktop.org/mailman/listinfo/mesa-dev