[Mesa-dev] [PATCH 5/8] android: add Android.mk for llvmpipe

Emil Velikov emil.l.velikov at gmail.com
Tue Jan 10 16:07:49 UTC 2017


On 6 January 2017 at 17:35, Wu Zhen <wuzhen at jidemail.com> wrote:
> From: WuZhen <wuzhen at jidemail.com>
>
> rename old swrast to softpipe, add a new driver llvmpipe
>
Generic comment:
Please keep mechanical changes (rename) separate from new
functionality (llvmpipe support).

Two [somewhat] open questions:
- If we rename swrast I would suggest sending patches for gralloc (drm
and gbm flavours) to respective places.
Please check with Rob H and the CrOS/Intel guys - git log will show
you the names/emails.

- If one moves MESA_ENABLE_LLVM to the device manifest there will be
no need for the extra llvmpipe.
This will make the patch much smaller and handling simpler, but one'll
need to error out if building radeonsi w/o the toggle.


> --- a/src/gallium/Android.mk
> +++ b/src/gallium/Android.mk
> @@ -34,7 +34,9 @@ SUBDIRS += auxiliary/pipe-loader
>  #
>
>  # swrast
> -ifneq ($(filter swrast,$(MESA_GPU_DRIVERS)),)
> +ifneq ($(filter llvmpipe,$(MESA_GPU_DRIVERS)),)
> +SUBDIRS += winsys/sw/dri drivers/llvmpipe drivers/softpipe
> +else ifneq ($(filter softpipe,$(MESA_GPU_DRIVERS)),)
>  SUBDIRS += winsys/sw/dri drivers/softpipe
Won't this lead to having the same SUBDIRS multiple times if one has
both softpipe and llvmpipe in MESA_GPU_DRIVERS ?



> --- a/src/gallium/targets/dri/Android.mk
> +++ b/src/gallium/targets/dri/Android.mk
> @@ -81,7 +81,11 @@ endif
>  gallium_DRIVERS += libmesa_winsys_radeon libmesa_pipe_radeon libmesa_amdgpu_addrlib
>  LOCAL_SHARED_LIBRARIES += libdrm_radeon
>  endif
> -ifneq ($(filter swrast,$(MESA_GPU_DRIVERS)),)
> +ifneq ($(filter llvmpipe,$(MESA_GPU_DRIVERS)),)
> +gallium_DRIVERS += libmesa_pipe_llvmpipe libmesa_pipe_softpipe libmesa_winsys_sw_dri
> +LOCAL_CFLAGS += -DGALLIUM_LLVMPIPE -DGALLIUM_SOFTPIPE
> +LOCAL_SHARED_LIBRARIES += libLLVM
> +else ifeq ($(filter softpipe,$(MESA_GPU_DRIVERS)),)
>  gallium_DRIVERS += libmesa_pipe_softpipe libmesa_winsys_sw_dri
>  LOCAL_CFLAGS += -DGALLIUM_SOFTPIPE
Similar to the SUBDIRS this will cause issues when both llvm and soft
-pipe are set, correct ?

Thanks
Emil


More information about the mesa-dev mailing list