[Mesa-dev] [PATCH 24/25] gallium/softpipe/llvmpipe: handle query_renderer caps

Alexander von Gluck IV kallisti5 at unixzen.com
Sat Feb 22 11:17:58 PST 2014


On Sat, 2014-02-22 at 15:33 +0000, Emil Velikov wrote:
> On 22/02/14 13:52, Brian Paul wrote:
> > On Fri, Feb 21, 2014 at 8:04 PM, Emil Velikov <emil.l.velikov at gmail.com>wrote:
> >> +   case PIPE_CAP_ACCELERATED:
> >> +      return 0;
> >> +   case PIPE_CAP_VIDEO_MEMORY: {
> >> +      /* XXX: Do we want to return the full amount fo system memory ? */
> >> +      const long system_memory_pages = sysconf(_SC_PHYS_PAGES);
> >> +      const long system_page_size = sysconf(_SC_PAGE_SIZE);
> >>
> > 
> > I'd bet sysconf() won't work on Windows or other non-Linux systems.
> > 
> > We should probably have a gallium utility function for doing memory size
> > queries.  It would wrap whatever OS calls are needed.
> > 
> Is there any other platforms to consider apart from Windows, Linux, *BSD
> and Haiku ?

Once the stubs are in for Haiku I'll fill em' out :-) (I have a few
other small fixes as well I need to push in)

I should note that it has been a little while since I've commited for
Haiku, this is mostly because the new swrast driver is working well, and
that swpipe compiles and works somewhat.  I plan on doing additional
work once real life(tm) calms down... so don't anyone go removing Haiku
support :-P

 -- Alex



More information about the mesa-dev mailing list