Compare commits
44 Commits
main
...
mesa-11.2.
Author | SHA1 | Date | |
---|---|---|---|
|
9f21fdd8e6 | ||
|
3d32af2d59 | ||
|
c9da4f8966 | ||
|
a07e84278c | ||
|
feb1972a80 | ||
|
caa10464ab | ||
|
50c678c706 | ||
|
ae4a7a5962 | ||
|
d956cfebd5 | ||
|
d29f41e1ba | ||
|
eda0880f77 | ||
|
ac909bf6f7 | ||
|
7073248f2f | ||
|
33b045688d | ||
|
7d056d2ec9 | ||
|
188e698e1a | ||
|
6f561c535d | ||
|
5fb53ff66a | ||
|
aeacc86336 | ||
|
06bc8e2515 | ||
|
c1e82fcf96 | ||
|
c00a89eb16 | ||
|
579b22ac66 | ||
|
43834d463d | ||
|
bb83ce0664 | ||
|
1fa66f0d03 | ||
|
8238432c1f | ||
|
da4c0efcc9 | ||
|
e90098a9cf | ||
|
ebe784f884 | ||
|
68759f1da9 | ||
|
f074c40ba8 | ||
|
93f1e7f1b0 | ||
|
b405582f81 | ||
|
2b24f0bce3 | ||
|
dda76b8703 | ||
|
88931cd044 | ||
|
472b46dc14 | ||
|
abf09d1764 | ||
|
1cb2108d9b | ||
|
3610f677db | ||
|
2eaca4a4d8 | ||
|
96babdd7f3 | ||
|
35b7adb937 |
@@ -33,6 +33,7 @@ MESA_VERSION := $(shell cat $(MESA_TOP)/VERSION)
|
|||||||
# define ANDROID_VERSION (e.g., 4.0.x => 0x0400)
|
# define ANDROID_VERSION (e.g., 4.0.x => 0x0400)
|
||||||
LOCAL_CFLAGS += \
|
LOCAL_CFLAGS += \
|
||||||
-Wno-unused-parameter \
|
-Wno-unused-parameter \
|
||||||
|
-Wno-date-time \
|
||||||
-DPACKAGE_VERSION=\"$(MESA_VERSION)\" \
|
-DPACKAGE_VERSION=\"$(MESA_VERSION)\" \
|
||||||
-DPACKAGE_BUGREPORT=\"https://bugs.freedesktop.org/enter_bug.cgi?product=Mesa\" \
|
-DPACKAGE_BUGREPORT=\"https://bugs.freedesktop.org/enter_bug.cgi?product=Mesa\" \
|
||||||
-DANDROID_VERSION=0x0$(MESA_ANDROID_MAJOR_VERSION)0$(MESA_ANDROID_MINOR_VERSION)
|
-DANDROID_VERSION=0x0$(MESA_ANDROID_MAJOR_VERSION)0$(MESA_ANDROID_MINOR_VERSION)
|
||||||
@@ -88,3 +89,6 @@ LOCAL_CPPFLAGS += \
|
|||||||
ifeq ($(strip $(LOCAL_MODULE_TAGS)),)
|
ifeq ($(strip $(LOCAL_MODULE_TAGS)),)
|
||||||
LOCAL_MODULE_TAGS := optional
|
LOCAL_MODULE_TAGS := optional
|
||||||
endif
|
endif
|
||||||
|
|
||||||
|
# Quiet down the build system and remove any .h files from the sources
|
||||||
|
LOCAL_SRC_FILES := $(patsubst %.h, , $(LOCAL_SRC_FILES))
|
||||||
|
@@ -42,6 +42,10 @@ $(call local-intermediates-dir)
|
|||||||
endef
|
endef
|
||||||
endif
|
endif
|
||||||
|
|
||||||
|
MESA_DRI_MODULE_REL_PATH := dri
|
||||||
|
MESA_DRI_MODULE_PATH := $(TARGET_OUT_SHARED_LIBRARIES)/$(MESA_DRI_MODULE_REL_PATH)
|
||||||
|
MESA_DRI_MODULE_UNSTRIPPED_PATH := $(TARGET_OUT_SHARED_LIBRARIES_UNSTRIPPED)/$(MESA_DRI_MODULE_REL_PATH)
|
||||||
|
|
||||||
MESA_COMMON_MK := $(MESA_TOP)/Android.common.mk
|
MESA_COMMON_MK := $(MESA_TOP)/Android.common.mk
|
||||||
MESA_PYTHON2 := python
|
MESA_PYTHON2 := python
|
||||||
|
|
||||||
@@ -87,7 +91,7 @@ SUBDIRS := \
|
|||||||
src/loader \
|
src/loader \
|
||||||
src/mapi \
|
src/mapi \
|
||||||
src/compiler \
|
src/compiler \
|
||||||
src/glsl \
|
src/compiler/glsl \
|
||||||
src/mesa \
|
src/mesa \
|
||||||
src/util \
|
src/util \
|
||||||
src/egl \
|
src/egl \
|
||||||
|
@@ -24,18 +24,21 @@ SUBDIRS = src
|
|||||||
AM_DISTCHECK_CONFIGURE_FLAGS = \
|
AM_DISTCHECK_CONFIGURE_FLAGS = \
|
||||||
--enable-dri3 \
|
--enable-dri3 \
|
||||||
--enable-gallium-tests \
|
--enable-gallium-tests \
|
||||||
|
--enable-gallium-osmesa \
|
||||||
--enable-gbm \
|
--enable-gbm \
|
||||||
--enable-gles1 \
|
--enable-gles1 \
|
||||||
--enable-gles2 \
|
--enable-gles2 \
|
||||||
--enable-glx-tls \
|
--enable-glx-tls \
|
||||||
|
--enable-nine \
|
||||||
|
--enable-opencl \
|
||||||
--enable-va \
|
--enable-va \
|
||||||
--enable-vdpau \
|
--enable-vdpau \
|
||||||
--enable-xa \
|
--enable-xa \
|
||||||
--enable-xvmc \
|
--enable-xvmc \
|
||||||
--disable-llvm-shared-libs \
|
--disable-llvm-shared-libs \
|
||||||
--with-egl-platforms=x11,wayland,drm \
|
--with-egl-platforms=x11,wayland,drm,surfaceless \
|
||||||
--with-dri-drivers=i915,i965,nouveau,radeon,r200,swrast \
|
--with-dri-drivers=i915,i965,nouveau,radeon,r200,swrast \
|
||||||
--with-gallium-drivers=i915,ilo,nouveau,r300,r600,radeonsi,freedreno,svga,swrast
|
--with-gallium-drivers=i915,ilo,nouveau,r300,r600,radeonsi,freedreno,svga,swrast,vc4,virgl
|
||||||
|
|
||||||
ACLOCAL_AMFLAGS = -I m4
|
ACLOCAL_AMFLAGS = -I m4
|
||||||
|
|
||||||
|
35
bin/get-extra-pick-list.sh
Executable file
35
bin/get-extra-pick-list.sh
Executable file
@@ -0,0 +1,35 @@
|
|||||||
|
#!/bin/sh
|
||||||
|
|
||||||
|
# Script for generating a list of candidates which fix commits that have been
|
||||||
|
# previously cherry-picked to a stable branch.
|
||||||
|
#
|
||||||
|
# Usage examples:
|
||||||
|
#
|
||||||
|
# $ bin/get-extra-pick-list.sh
|
||||||
|
# $ bin/get-extra-pick-list.sh > picklist
|
||||||
|
# $ bin/get-extra-pick-list.sh | tee picklist
|
||||||
|
|
||||||
|
# Use the last branchpoint as our limit for the search
|
||||||
|
# XXX: there should be a better way for this
|
||||||
|
latest_branchpoint=`git branch | grep \* | cut -c 3-`-branchpoint
|
||||||
|
|
||||||
|
# Grep for commits with "cherry picked from commit" in the commit message.
|
||||||
|
git log --reverse --grep="cherry picked from commit" $latest_branchpoint..HEAD |\
|
||||||
|
grep "cherry picked from commit" |\
|
||||||
|
sed -e 's/^[[:space:]]*(cherry picked from commit[[:space:]]*//' -e 's/)//' |\
|
||||||
|
cut -c -8 |\
|
||||||
|
while read sha
|
||||||
|
do
|
||||||
|
# Check if the original commit is referenced in master
|
||||||
|
git log -n1 --pretty=oneline --grep=$sha $latest_branchpoint..origin/master |\
|
||||||
|
cut -c -8 |\
|
||||||
|
while read candidate
|
||||||
|
do
|
||||||
|
# Check if the potential fix, hasn't landed in branch yet.
|
||||||
|
found=`git log -n1 --pretty=oneline --reverse --grep=$candidate $latest_branchpoint..HEAD |wc -l`
|
||||||
|
if test $found = 0
|
||||||
|
then
|
||||||
|
echo Commit $candidate might need to be picked, as it references $sha
|
||||||
|
fi
|
||||||
|
done
|
||||||
|
done
|
@@ -1 +1,2 @@
|
|||||||
CHIPSET(0x0010, VIRTGL, VIRTGL)
|
CHIPSET(0x0010, VIRTGL, VIRTGL)
|
||||||
|
CHIPSET(0x1050, VIRTGL, VIRTGL)
|
||||||
|
@@ -3,9 +3,9 @@
|
|||||||
|
|
||||||
if BUILD_SHARED
|
if BUILD_SHARED
|
||||||
if HAVE_COMPAT_SYMLINKS
|
if HAVE_COMPAT_SYMLINKS
|
||||||
all-local : .libs/install-gallium-links
|
all-local : .install-gallium-links
|
||||||
|
|
||||||
.libs/install-gallium-links : $(dri_LTLIBRARIES) $(egl_LTLIBRARIES) $(lib_LTLIBRARIES)
|
.install-gallium-links : $(dri_LTLIBRARIES) $(egl_LTLIBRARIES) $(lib_LTLIBRARIES)
|
||||||
$(AM_V_GEN)$(MKDIR_P) $(top_builddir)/$(LIB_DIR); \
|
$(AM_V_GEN)$(MKDIR_P) $(top_builddir)/$(LIB_DIR); \
|
||||||
link_dir=$(top_builddir)/$(LIB_DIR)/gallium; \
|
link_dir=$(top_builddir)/$(LIB_DIR)/gallium; \
|
||||||
if test x$(egl_LTLIBRARIES) != x; then \
|
if test x$(egl_LTLIBRARIES) != x; then \
|
||||||
@@ -23,4 +23,15 @@ all-local : .libs/install-gallium-links
|
|||||||
fi; \
|
fi; \
|
||||||
done && touch $@
|
done && touch $@
|
||||||
endif
|
endif
|
||||||
|
|
||||||
|
clean-local:
|
||||||
|
for f in $(notdir $(dri_LTLIBRARIES:%.la=.libs/%.$(LIB_EXT)*)) \
|
||||||
|
$(notdir $(egl_LTLIBRARIES:%.la=.libs/%.$(LIB_EXT)*)) \
|
||||||
|
$(notdir $(lib_LTLIBRARIES:%.la=.libs/%.$(LIB_EXT)*)); do \
|
||||||
|
echo $$f; \
|
||||||
|
$(RM) $(top_builddir)/$(LIB_DIR)/gallium/$$f; \
|
||||||
|
done;
|
||||||
|
rmdir $(top_builddir)/$(LIB_DIR)/gallium || true
|
||||||
|
$(RM) .install-gallium-links
|
||||||
|
|
||||||
endif
|
endif
|
||||||
|
@@ -42,6 +42,10 @@ LOCAL_EXPORT_C_INCLUDE_DIRS += \
|
|||||||
LOCAL_GENERATED_SOURCES += $(addprefix $(intermediates)/, \
|
LOCAL_GENERATED_SOURCES += $(addprefix $(intermediates)/, \
|
||||||
$(NIR_GENERATED_FILES))
|
$(NIR_GENERATED_FILES))
|
||||||
|
|
||||||
|
# Modules using libmesa_nir must set LOCAL_GENERATED_SOURCES to this
|
||||||
|
MESA_GEN_NIR_H := $(addprefix $(call local-generated-sources-dir)/, \
|
||||||
|
nir/nir_opcodes.h \
|
||||||
|
nir/nir_builder_opcodes.h)
|
||||||
|
|
||||||
nir_builder_opcodes_gen := $(LOCAL_PATH)/nir/nir_builder_opcodes_h.py
|
nir_builder_opcodes_gen := $(LOCAL_PATH)/nir/nir_builder_opcodes_h.py
|
||||||
nir_builder_opcodes_deps := \
|
nir_builder_opcodes_deps := \
|
||||||
|
@@ -33,7 +33,7 @@ LOCAL_SRC_FILES := $(LOCAL_SRC_FILES)
|
|||||||
|
|
||||||
LOCAL_C_INCLUDES += \
|
LOCAL_C_INCLUDES += \
|
||||||
$(intermediates)/glcpp \
|
$(intermediates)/glcpp \
|
||||||
$(MESA_TOP)/src/glsl/glcpp \
|
$(LOCAL_PATH)/glcpp \
|
||||||
|
|
||||||
LOCAL_GENERATED_SOURCES += $(addprefix $(intermediates)/, \
|
LOCAL_GENERATED_SOURCES += $(addprefix $(intermediates)/, \
|
||||||
$(LIBGLCPP_GENERATED_FILES) \
|
$(LIBGLCPP_GENERATED_FILES) \
|
||||||
@@ -51,6 +51,8 @@ define glsl_local-y-to-c-and-h
|
|||||||
$(hide) $(YACC) -o $@ -p "glcpp_parser_" $<
|
$(hide) $(YACC) -o $@ -p "glcpp_parser_" $<
|
||||||
endef
|
endef
|
||||||
|
|
||||||
|
YACC_HEADER_SUFFIX := .hpp
|
||||||
|
|
||||||
define local-yy-to-cpp-and-h
|
define local-yy-to-cpp-and-h
|
||||||
@mkdir -p $(dir $@)
|
@mkdir -p $(dir $@)
|
||||||
@echo "Mesa Yacc: $(PRIVATE_MODULE) <= $<"
|
@echo "Mesa Yacc: $(PRIVATE_MODULE) <= $<"
|
||||||
|
@@ -36,7 +36,6 @@ include $(CLEAR_VARS)
|
|||||||
LOCAL_SRC_FILES := \
|
LOCAL_SRC_FILES := \
|
||||||
$(LIBGLCPP_FILES) \
|
$(LIBGLCPP_FILES) \
|
||||||
$(LIBGLSL_FILES) \
|
$(LIBGLSL_FILES) \
|
||||||
$(NIR_FILES)
|
|
||||||
|
|
||||||
LOCAL_C_INCLUDES := \
|
LOCAL_C_INCLUDES := \
|
||||||
$(MESA_TOP)/src/mapi \
|
$(MESA_TOP)/src/mapi \
|
||||||
@@ -67,7 +66,7 @@ LOCAL_C_INCLUDES := \
|
|||||||
$(MESA_TOP)/src/gallium/include \
|
$(MESA_TOP)/src/gallium/include \
|
||||||
$(MESA_TOP)/src/gallium/auxiliary
|
$(MESA_TOP)/src/gallium/auxiliary
|
||||||
|
|
||||||
LOCAL_STATIC_LIBRARIES := libmesa_glsl libmesa_glsl_utils libmesa_util
|
LOCAL_STATIC_LIBRARIES := libmesa_glsl libmesa_glsl_utils libmesa_util libmesa_compiler
|
||||||
|
|
||||||
LOCAL_MODULE_TAGS := eng
|
LOCAL_MODULE_TAGS := eng
|
||||||
LOCAL_MODULE := glsl_compiler
|
LOCAL_MODULE := glsl_compiler
|
||||||
|
@@ -1686,6 +1686,7 @@ public:
|
|||||||
operation == ir_binop_dot ||
|
operation == ir_binop_dot ||
|
||||||
operation == ir_binop_vector_extract ||
|
operation == ir_binop_vector_extract ||
|
||||||
operation == ir_triop_vector_insert ||
|
operation == ir_triop_vector_insert ||
|
||||||
|
operation == ir_binop_ubo_load ||
|
||||||
operation == ir_quadop_vector;
|
operation == ir_quadop_vector;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@@ -3180,7 +3180,6 @@ check_explicit_uniform_locations(struct gl_context *ctx,
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
exec_list_make_empty(&prog->EmptyUniformLocations);
|
|
||||||
struct empty_uniform_block *current_block = NULL;
|
struct empty_uniform_block *current_block = NULL;
|
||||||
|
|
||||||
for (unsigned i = 0; i < prog->NumUniformRemapTable; i++) {
|
for (unsigned i = 0; i < prog->NumUniformRemapTable; i++) {
|
||||||
|
@@ -44,10 +44,10 @@ LOCAL_CFLAGS := \
|
|||||||
-DHAVE_ANDROID_PLATFORM
|
-DHAVE_ANDROID_PLATFORM
|
||||||
|
|
||||||
ifeq ($(MESA_LOLLIPOP_BUILD),true)
|
ifeq ($(MESA_LOLLIPOP_BUILD),true)
|
||||||
LOCAL_CFLAGS_32 := -DDEFAULT_DRIVER_DIR=\"/system/lib/dri\"
|
LOCAL_CFLAGS_32 := -DDEFAULT_DRIVER_DIR=\"/system/lib/$(MESA_DRI_MODULE_REL_PATH)\"
|
||||||
LOCAL_CFLAGS_64 := -DDEFAULT_DRIVER_DIR=\"/system/lib64/dri\"
|
LOCAL_CFLAGS_64 := -DDEFAULT_DRIVER_DIR=\"/system/lib64/$(MESA_DRI_MODULE_REL_PATH)\"
|
||||||
else
|
else
|
||||||
LOCAL_CFLAGS += -DDEFAULT_DRIVER_DIR=\"/system/lib/dri\"
|
LOCAL_CFLAGS += -DDEFAULT_DRIVER_DIR=\"/system/lib/$(MESA_DRI_MODULE_REL_PATH)\"
|
||||||
endif
|
endif
|
||||||
|
|
||||||
LOCAL_C_INCLUDES := \
|
LOCAL_C_INCLUDES := \
|
||||||
|
@@ -653,6 +653,37 @@ create_wl_buffer(struct dri2_egl_surface *dri2_surf)
|
|||||||
&wl_buffer_listener, dri2_surf);
|
&wl_buffer_listener, dri2_surf);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
static EGLBoolean
|
||||||
|
try_damage_buffer(struct dri2_egl_surface *dri2_surf,
|
||||||
|
const EGLint *rects,
|
||||||
|
EGLint n_rects)
|
||||||
|
{
|
||||||
|
/* The WL_SURFACE_DAMAGE_BUFFER_SINCE_VERSION macro and
|
||||||
|
* wl_proxy_get_version() were both introduced in wayland 1.10.
|
||||||
|
* Instead of bumping our wayland dependency we just make this
|
||||||
|
* function conditional on the required 1.10 features, falling
|
||||||
|
* back to old (correct but suboptimal) behaviour for older
|
||||||
|
* wayland.
|
||||||
|
*/
|
||||||
|
#ifdef WL_SURFACE_DAMAGE_BUFFER_SINCE_VERSION
|
||||||
|
int i;
|
||||||
|
|
||||||
|
if (wl_proxy_get_version((struct wl_proxy *) dri2_surf->wl_win->surface)
|
||||||
|
< WL_SURFACE_DAMAGE_BUFFER_SINCE_VERSION)
|
||||||
|
return EGL_FALSE;
|
||||||
|
|
||||||
|
for (i = 0; i < n_rects; i++) {
|
||||||
|
const int *rect = &rects[i * 4];
|
||||||
|
|
||||||
|
wl_surface_damage_buffer(dri2_surf->wl_win->surface,
|
||||||
|
rect[0],
|
||||||
|
dri2_surf->base.Height - rect[1] - rect[3],
|
||||||
|
rect[2], rect[3]);
|
||||||
|
}
|
||||||
|
return EGL_TRUE;
|
||||||
|
#endif
|
||||||
|
return EGL_FALSE;
|
||||||
|
}
|
||||||
/**
|
/**
|
||||||
* Called via eglSwapBuffers(), drv->API.SwapBuffers().
|
* Called via eglSwapBuffers(), drv->API.SwapBuffers().
|
||||||
*/
|
*/
|
||||||
@@ -703,10 +734,12 @@ dri2_wl_swap_buffers_with_damage(_EGLDriver *drv,
|
|||||||
dri2_surf->dx = 0;
|
dri2_surf->dx = 0;
|
||||||
dri2_surf->dy = 0;
|
dri2_surf->dy = 0;
|
||||||
|
|
||||||
/* We deliberately ignore the damage region and post maximum damage, due to
|
/* If the compositor doesn't support damage_buffer, we deliberately
|
||||||
|
* ignore the damage region and post maximum damage, due to
|
||||||
* https://bugs.freedesktop.org/78190 */
|
* https://bugs.freedesktop.org/78190 */
|
||||||
wl_surface_damage(dri2_surf->wl_win->surface,
|
if (!n_rects || !try_damage_buffer(dri2_surf, rects, n_rects))
|
||||||
0, 0, INT32_MAX, INT32_MAX);
|
wl_surface_damage(dri2_surf->wl_win->surface,
|
||||||
|
0, 0, INT32_MAX, INT32_MAX);
|
||||||
|
|
||||||
if (dri2_dpy->is_different_gpu) {
|
if (dri2_dpy->is_different_gpu) {
|
||||||
_EGLContext *ctx = _eglGetCurrentContext();
|
_EGLContext *ctx = _eglGetCurrentContext();
|
||||||
|
@@ -44,9 +44,9 @@ LOCAL_SRC_FILES += \
|
|||||||
LOCAL_CPPFLAGS := -std=c++11
|
LOCAL_CPPFLAGS := -std=c++11
|
||||||
endif
|
endif
|
||||||
|
|
||||||
# We need libmesa_glsl to get NIR's generated include directories.
|
# We need libmesa_nir to get NIR's generated include directories.
|
||||||
LOCAL_MODULE := libmesa_gallium
|
LOCAL_MODULE := libmesa_gallium
|
||||||
LOCAL_STATIC_LIBRARIES += libmesa_glsl
|
LOCAL_STATIC_LIBRARIES += libmesa_nir
|
||||||
|
|
||||||
# generate sources
|
# generate sources
|
||||||
LOCAL_MODULE_CLASS := STATIC_LIBRARIES
|
LOCAL_MODULE_CLASS := STATIC_LIBRARIES
|
||||||
@@ -64,5 +64,7 @@ $(intermediates)/util/u_format_srgb.c: $(intermediates)/%.c: $(LOCAL_PATH)/%.py
|
|||||||
$(intermediates)/util/u_format_table.c: $(intermediates)/%.c: $(LOCAL_PATH)/%.py $(LOCAL_PATH)/util/u_format.csv
|
$(intermediates)/util/u_format_table.c: $(intermediates)/%.c: $(LOCAL_PATH)/%.py $(LOCAL_PATH)/util/u_format.csv
|
||||||
$(transform-generated-source)
|
$(transform-generated-source)
|
||||||
|
|
||||||
|
LOCAL_GENERATED_SOURCES += $(MESA_GEN_NIR_H)
|
||||||
|
|
||||||
include $(GALLIUM_COMMON_MK)
|
include $(GALLIUM_COMMON_MK)
|
||||||
include $(BUILD_STATIC_LIBRARY)
|
include $(BUILD_STATIC_LIBRARY)
|
||||||
|
@@ -247,7 +247,14 @@ scan_declaration(struct tgsi_shader_info *info,
|
|||||||
info->input_interpolate[reg] = (ubyte)fulldecl->Interp.Interpolate;
|
info->input_interpolate[reg] = (ubyte)fulldecl->Interp.Interpolate;
|
||||||
info->input_interpolate_loc[reg] = (ubyte)fulldecl->Interp.Location;
|
info->input_interpolate_loc[reg] = (ubyte)fulldecl->Interp.Location;
|
||||||
info->input_cylindrical_wrap[reg] = (ubyte)fulldecl->Interp.CylindricalWrap;
|
info->input_cylindrical_wrap[reg] = (ubyte)fulldecl->Interp.CylindricalWrap;
|
||||||
info->num_inputs++;
|
|
||||||
|
/* Vertex shaders can have inputs with holes between them. */
|
||||||
|
if (info->processor == TGSI_PROCESSOR_VERTEX)
|
||||||
|
info->num_inputs = MAX2(info->num_inputs, reg + 1);
|
||||||
|
else {
|
||||||
|
info->num_inputs++;
|
||||||
|
assert(reg < info->num_inputs);
|
||||||
|
}
|
||||||
|
|
||||||
/* Only interpolated varyings. Don't include POSITION.
|
/* Only interpolated varyings. Don't include POSITION.
|
||||||
* Don't include integer varyings, because they are not
|
* Don't include integer varyings, because they are not
|
||||||
@@ -341,6 +348,7 @@ scan_declaration(struct tgsi_shader_info *info,
|
|||||||
info->output_semantic_name[reg] = (ubyte) semName;
|
info->output_semantic_name[reg] = (ubyte) semName;
|
||||||
info->output_semantic_index[reg] = (ubyte) semIndex;
|
info->output_semantic_index[reg] = (ubyte) semIndex;
|
||||||
info->num_outputs++;
|
info->num_outputs++;
|
||||||
|
assert(reg < info->num_outputs);
|
||||||
|
|
||||||
if (semName == TGSI_SEMANTIC_COLOR)
|
if (semName == TGSI_SEMANTIC_COLOR)
|
||||||
info->colors_written |= 1 << semIndex;
|
info->colors_written |= 1 << semIndex;
|
||||||
|
@@ -32,14 +32,16 @@ LOCAL_SRC_FILES := \
|
|||||||
$(a4xx_SOURCES) \
|
$(a4xx_SOURCES) \
|
||||||
$(ir3_SOURCES)
|
$(ir3_SOURCES)
|
||||||
|
|
||||||
LOCAL_CFLAGS := \
|
#LOCAL_CFLAGS := \
|
||||||
-Wno-packed-bitfield-compat
|
# -Wno-packed-bitfield-compat
|
||||||
|
|
||||||
LOCAL_C_INCLUDES := \
|
LOCAL_C_INCLUDES := \
|
||||||
$(LOCAL_PATH)/ir3
|
$(LOCAL_PATH)/ir3
|
||||||
|
|
||||||
|
LOCAL_GENERATED_SOURCES := $(MESA_GEN_NIR_H)
|
||||||
|
|
||||||
LOCAL_SHARED_LIBRARIES := libdrm libdrm_freedreno
|
LOCAL_SHARED_LIBRARIES := libdrm libdrm_freedreno
|
||||||
LOCAL_STATIC_LIBRARIES := libmesa_glsl
|
LOCAL_STATIC_LIBRARIES := libmesa_glsl libmesa_nir
|
||||||
LOCAL_MODULE := libmesa_pipe_freedreno
|
LOCAL_MODULE := libmesa_pipe_freedreno
|
||||||
|
|
||||||
include $(GALLIUM_COMMON_MK)
|
include $(GALLIUM_COMMON_MK)
|
||||||
|
@@ -1837,6 +1837,13 @@ CodeEmitterNVC0::emitLOAD(const Instruction *i)
|
|||||||
}
|
}
|
||||||
code[1] = opc;
|
code[1] = opc;
|
||||||
|
|
||||||
|
if (i->src(0).getFile() == FILE_MEMORY_SHARED) {
|
||||||
|
if (i->subOp == NV50_IR_SUBOP_LOAD_LOCKED) {
|
||||||
|
assert(i->defExists(1));
|
||||||
|
defId(i->def(1), 32 + 18);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
defId(i->def(0), 14);
|
defId(i->def(0), 14);
|
||||||
|
|
||||||
setAddressByFile(i->src(0));
|
setAddressByFile(i->src(0));
|
||||||
|
@@ -121,7 +121,7 @@ nv50_screen_get_param(struct pipe_screen *pscreen, enum pipe_cap param)
|
|||||||
case PIPE_CAP_CONSTANT_BUFFER_OFFSET_ALIGNMENT:
|
case PIPE_CAP_CONSTANT_BUFFER_OFFSET_ALIGNMENT:
|
||||||
return 256;
|
return 256;
|
||||||
case PIPE_CAP_TEXTURE_BUFFER_OFFSET_ALIGNMENT:
|
case PIPE_CAP_TEXTURE_BUFFER_OFFSET_ALIGNMENT:
|
||||||
return 1; /* 256 for binding as RT, but that's not possible in GL */
|
return 16; /* 256 for binding as RT, but that's not possible in GL */
|
||||||
case PIPE_CAP_MIN_MAP_BUFFER_ALIGNMENT:
|
case PIPE_CAP_MIN_MAP_BUFFER_ALIGNMENT:
|
||||||
return NOUVEAU_MIN_BUFFER_MAP_ALIGN;
|
return NOUVEAU_MIN_BUFFER_MAP_ALIGN;
|
||||||
case PIPE_CAP_MAX_VIEWPORTS:
|
case PIPE_CAP_MAX_VIEWPORTS:
|
||||||
|
@@ -112,7 +112,7 @@ nvc0_screen_get_param(struct pipe_screen *pscreen, enum pipe_cap param)
|
|||||||
case PIPE_CAP_CONSTANT_BUFFER_OFFSET_ALIGNMENT:
|
case PIPE_CAP_CONSTANT_BUFFER_OFFSET_ALIGNMENT:
|
||||||
return 256;
|
return 256;
|
||||||
case PIPE_CAP_TEXTURE_BUFFER_OFFSET_ALIGNMENT:
|
case PIPE_CAP_TEXTURE_BUFFER_OFFSET_ALIGNMENT:
|
||||||
return 1; /* 256 for binding as RT, but that's not possible in GL */
|
return 16; /* 256 for binding as RT, but that's not possible in GL */
|
||||||
case PIPE_CAP_SHADER_BUFFER_OFFSET_ALIGNMENT:
|
case PIPE_CAP_SHADER_BUFFER_OFFSET_ALIGNMENT:
|
||||||
return 16;
|
return 16;
|
||||||
case PIPE_CAP_MIN_MAP_BUFFER_ALIGNMENT:
|
case PIPE_CAP_MIN_MAP_BUFFER_ALIGNMENT:
|
||||||
|
@@ -32,7 +32,6 @@ LOCAL_SRC_FILES := $(C_SOURCES)
|
|||||||
|
|
||||||
LOCAL_C_INCLUDES := \
|
LOCAL_C_INCLUDES := \
|
||||||
$(MESA_TOP)/src/mapi \
|
$(MESA_TOP)/src/mapi \
|
||||||
$(MESA_TOP)/src/glsl \
|
|
||||||
$(MESA_TOP)/src/mesa
|
$(MESA_TOP)/src/mesa
|
||||||
|
|
||||||
|
|
||||||
|
@@ -989,13 +989,6 @@ void evergreen_init_color_surface_rat(struct r600_context *rctx,
|
|||||||
MAX2(64, rctx->screen->b.info.pipe_interleave_bytes / block_size);
|
MAX2(64, rctx->screen->b.info.pipe_interleave_bytes / block_size);
|
||||||
unsigned pitch = align(pipe_buffer->width0, pitch_alignment);
|
unsigned pitch = align(pipe_buffer->width0, pitch_alignment);
|
||||||
|
|
||||||
/* XXX: This is copied from evergreen_init_color_surface(). I don't
|
|
||||||
* know why this is necessary.
|
|
||||||
*/
|
|
||||||
if (pipe_buffer->usage == PIPE_USAGE_STAGING) {
|
|
||||||
endian = ENDIAN_NONE;
|
|
||||||
}
|
|
||||||
|
|
||||||
surf->cb_color_base = r600_resource(pipe_buffer)->gpu_address >> 8;
|
surf->cb_color_base = r600_resource(pipe_buffer)->gpu_address >> 8;
|
||||||
|
|
||||||
surf->cb_color_pitch = (pitch / 8) - 1;
|
surf->cb_color_pitch = (pitch / 8) - 1;
|
||||||
@@ -1146,11 +1139,7 @@ void evergreen_init_color_surface(struct r600_context *rctx,
|
|||||||
swap = r600_translate_colorswap(surf->base.format);
|
swap = r600_translate_colorswap(surf->base.format);
|
||||||
assert(swap != ~0);
|
assert(swap != ~0);
|
||||||
|
|
||||||
if (rtex->resource.b.b.usage == PIPE_USAGE_STAGING) {
|
endian = r600_colorformat_endian_swap(format);
|
||||||
endian = ENDIAN_NONE;
|
|
||||||
} else {
|
|
||||||
endian = r600_colorformat_endian_swap(format);
|
|
||||||
}
|
|
||||||
|
|
||||||
/* blend clamp should be set for all NORM/SRGB types */
|
/* blend clamp should be set for all NORM/SRGB types */
|
||||||
if (ntype == V_028C70_NUMBER_UNORM || ntype == V_028C70_NUMBER_SNORM ||
|
if (ntype == V_028C70_NUMBER_UNORM || ntype == V_028C70_NUMBER_SNORM ||
|
||||||
|
@@ -102,13 +102,13 @@ enum alu_op_flags
|
|||||||
|
|
||||||
/* condition codes - 3 bits */
|
/* condition codes - 3 bits */
|
||||||
AF_CC_SHIFT = 29,
|
AF_CC_SHIFT = 29,
|
||||||
AF_CC_MASK = (7 << AF_CC_SHIFT),
|
AF_CC_MASK = (7U << AF_CC_SHIFT),
|
||||||
AF_CC_E = (0 << AF_CC_SHIFT),
|
AF_CC_E = (0U << AF_CC_SHIFT),
|
||||||
AF_CC_GT = (1 << AF_CC_SHIFT),
|
AF_CC_GT = (1U << AF_CC_SHIFT),
|
||||||
AF_CC_GE = (2 << AF_CC_SHIFT),
|
AF_CC_GE = (2U << AF_CC_SHIFT),
|
||||||
AF_CC_NE = (3 << AF_CC_SHIFT),
|
AF_CC_NE = (3U << AF_CC_SHIFT),
|
||||||
AF_CC_LT = (4 << AF_CC_SHIFT),
|
AF_CC_LT = (4U << AF_CC_SHIFT),
|
||||||
AF_CC_LE = (5 << AF_CC_SHIFT),
|
AF_CC_LE = (5U << AF_CC_SHIFT),
|
||||||
};
|
};
|
||||||
|
|
||||||
/* flags for FETCH instructions (TEX/VTX) */
|
/* flags for FETCH instructions (TEX/VTX) */
|
||||||
@@ -165,7 +165,7 @@ struct alu_op_info
|
|||||||
* (0 if instruction doesn't exist for chip class) */
|
* (0 if instruction doesn't exist for chip class) */
|
||||||
int slots[4];
|
int slots[4];
|
||||||
/* flags (mostly autogenerated from instruction name) */
|
/* flags (mostly autogenerated from instruction name) */
|
||||||
int flags;
|
unsigned int flags;
|
||||||
};
|
};
|
||||||
|
|
||||||
/* FETCH instruction info */
|
/* FETCH instruction info */
|
||||||
|
@@ -930,11 +930,7 @@ static void r600_init_color_surface(struct r600_context *rctx,
|
|||||||
swap = r600_translate_colorswap(surf->base.format);
|
swap = r600_translate_colorswap(surf->base.format);
|
||||||
assert(swap != ~0);
|
assert(swap != ~0);
|
||||||
|
|
||||||
if (rtex->resource.b.b.usage == PIPE_USAGE_STAGING) {
|
endian = r600_colorformat_endian_swap(format);
|
||||||
endian = ENDIAN_NONE;
|
|
||||||
} else {
|
|
||||||
endian = r600_colorformat_endian_swap(format);
|
|
||||||
}
|
|
||||||
|
|
||||||
/* set blend bypass according to docs if SINT/UINT or
|
/* set blend bypass according to docs if SINT/UINT or
|
||||||
8/24 COLOR variants */
|
8/24 COLOR variants */
|
||||||
|
@@ -2721,6 +2721,13 @@ uint32_t r600_colorformat_endian_swap(uint32_t colorformat)
|
|||||||
|
|
||||||
/* 32-bit buffers. */
|
/* 32-bit buffers. */
|
||||||
case V_0280A0_COLOR_8_8_8_8:
|
case V_0280A0_COLOR_8_8_8_8:
|
||||||
|
/*
|
||||||
|
* No need to do endian swaps on four 8-bits components,
|
||||||
|
* as mesa<-->pipe formats conversion take into account
|
||||||
|
* the endianess
|
||||||
|
*/
|
||||||
|
return ENDIAN_NONE;
|
||||||
|
|
||||||
case V_0280A0_COLOR_2_10_10_10:
|
case V_0280A0_COLOR_2_10_10_10:
|
||||||
case V_0280A0_COLOR_8_24:
|
case V_0280A0_COLOR_8_24:
|
||||||
case V_0280A0_COLOR_24_8:
|
case V_0280A0_COLOR_24_8:
|
||||||
|
@@ -659,7 +659,7 @@ r600_get_sampler_view_priority(struct r600_resource *res)
|
|||||||
} while (0);
|
} while (0);
|
||||||
|
|
||||||
#define R600_ERR(fmt, args...) \
|
#define R600_ERR(fmt, args...) \
|
||||||
fprintf(stderr, "EE %s:%d %s - "fmt, __FILE__, __LINE__, __func__, ##args)
|
fprintf(stderr, "EE %s:%d %s - " fmt, __FILE__, __LINE__, __func__, ##args)
|
||||||
|
|
||||||
/* For MSAA sample positions. */
|
/* For MSAA sample positions. */
|
||||||
#define FILL_SREG(s0x, s0y, s1x, s1y, s2x, s2y, s3x, s3y) \
|
#define FILL_SREG(s0x, s0y, s1x, s1y, s2x, s2y, s3x, s3y) \
|
||||||
|
@@ -1299,8 +1299,8 @@ unsigned r600_translate_colorswap(enum pipe_format format)
|
|||||||
return V_0280A0_SWAP_STD_REV; /* WZYX */
|
return V_0280A0_SWAP_STD_REV; /* WZYX */
|
||||||
else if (HAS_SWIZZLE(1,Y) && HAS_SWIZZLE(2,X))
|
else if (HAS_SWIZZLE(1,Y) && HAS_SWIZZLE(2,X))
|
||||||
return V_0280A0_SWAP_ALT; /* ZYXW */
|
return V_0280A0_SWAP_ALT; /* ZYXW */
|
||||||
else if (HAS_SWIZZLE(1,X) && HAS_SWIZZLE(2,Y))
|
else if (HAS_SWIZZLE(1,Z) && HAS_SWIZZLE(2,W))
|
||||||
return V_0280A0_SWAP_ALT_REV; /* WXYZ */
|
return V_0280A0_SWAP_ALT_REV; /* YZWX */
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
return ~0U;
|
return ~0U;
|
||||||
@@ -1408,6 +1408,11 @@ void evergreen_do_fast_color_clear(struct r600_common_context *rctx,
|
|||||||
{
|
{
|
||||||
int i;
|
int i;
|
||||||
|
|
||||||
|
/* This function is broken in BE, so just disable this path for now */
|
||||||
|
#ifdef PIPE_ARCH_BIG_ENDIAN
|
||||||
|
return;
|
||||||
|
#endif
|
||||||
|
|
||||||
if (rctx->render_cond)
|
if (rctx->render_cond)
|
||||||
return;
|
return;
|
||||||
|
|
||||||
|
@@ -2250,11 +2250,7 @@ static void si_initialize_color_surface(struct si_context *sctx,
|
|||||||
}
|
}
|
||||||
assert(format != V_028C70_COLOR_INVALID);
|
assert(format != V_028C70_COLOR_INVALID);
|
||||||
swap = r600_translate_colorswap(surf->base.format);
|
swap = r600_translate_colorswap(surf->base.format);
|
||||||
if (rtex->resource.b.b.usage == PIPE_USAGE_STAGING) {
|
endian = si_colorformat_endian_swap(format);
|
||||||
endian = V_028C70_ENDIAN_NONE;
|
|
||||||
} else {
|
|
||||||
endian = si_colorformat_endian_swap(format);
|
|
||||||
}
|
|
||||||
|
|
||||||
/* blend clamp should be set for all NORM/SRGB types */
|
/* blend clamp should be set for all NORM/SRGB types */
|
||||||
if (ntype == V_028C70_NUMBER_UNORM ||
|
if (ntype == V_028C70_NUMBER_UNORM ||
|
||||||
|
@@ -28,9 +28,11 @@ include $(CLEAR_VARS)
|
|||||||
LOCAL_SRC_FILES := \
|
LOCAL_SRC_FILES := \
|
||||||
$(C_SOURCES)
|
$(C_SOURCES)
|
||||||
|
|
||||||
|
LOCAL_GENERATED_SOURCES := $(MESA_GEN_NIR_H)
|
||||||
|
|
||||||
LOCAL_SHARED_LIBRARIES := libdrm
|
LOCAL_SHARED_LIBRARIES := libdrm
|
||||||
# We need libmesa_glsl to get NIR's generated include directories.
|
# We need libmesa_nir to get NIR's generated include directories.
|
||||||
LOCAL_STATIC_LIBRARIES := libmesa_glsl
|
LOCAL_STATIC_LIBRARIES := libmesa_nir
|
||||||
LOCAL_MODULE := libmesa_pipe_vc4
|
LOCAL_MODULE := libmesa_pipe_vc4
|
||||||
|
|
||||||
include $(GALLIUM_COMMON_MK)
|
include $(GALLIUM_COMMON_MK)
|
||||||
|
@@ -741,7 +741,9 @@ int virgl_encode_blit(struct virgl_context *ctx,
|
|||||||
virgl_encoder_write_cmd_dword(ctx, VIRGL_CMD0(VIRGL_CCMD_BLIT, 0, VIRGL_CMD_BLIT_SIZE));
|
virgl_encoder_write_cmd_dword(ctx, VIRGL_CMD0(VIRGL_CCMD_BLIT, 0, VIRGL_CMD_BLIT_SIZE));
|
||||||
tmp = VIRGL_CMD_BLIT_S0_MASK(blit->mask) |
|
tmp = VIRGL_CMD_BLIT_S0_MASK(blit->mask) |
|
||||||
VIRGL_CMD_BLIT_S0_FILTER(blit->filter) |
|
VIRGL_CMD_BLIT_S0_FILTER(blit->filter) |
|
||||||
VIRGL_CMD_BLIT_S0_SCISSOR_ENABLE(blit->scissor_enable);
|
VIRGL_CMD_BLIT_S0_SCISSOR_ENABLE(blit->scissor_enable) |
|
||||||
|
VIRGL_CMD_BLIT_S0_RENDER_CONDITION_ENABLE(blit->render_condition_enable) |
|
||||||
|
VIRGL_CMD_BLIT_S0_ALPHA_BLEND(blit->alpha_blend);
|
||||||
virgl_encoder_write_dword(ctx->cbuf, tmp);
|
virgl_encoder_write_dword(ctx->cbuf, tmp);
|
||||||
virgl_encoder_write_dword(ctx->cbuf, (blit->scissor.minx | blit->scissor.miny << 16));
|
virgl_encoder_write_dword(ctx->cbuf, (blit->scissor.minx | blit->scissor.miny << 16));
|
||||||
virgl_encoder_write_dword(ctx->cbuf, (blit->scissor.maxx | blit->scissor.maxy << 16));
|
virgl_encoder_write_dword(ctx->cbuf, (blit->scissor.maxx | blit->scissor.maxy << 16));
|
||||||
|
@@ -388,6 +388,8 @@ enum virgl_context_cmd {
|
|||||||
#define VIRGL_CMD_BLIT_S0_MASK(x) (((x) & 0xff) << 0)
|
#define VIRGL_CMD_BLIT_S0_MASK(x) (((x) & 0xff) << 0)
|
||||||
#define VIRGL_CMD_BLIT_S0_FILTER(x) (((x) & 0x3) << 8)
|
#define VIRGL_CMD_BLIT_S0_FILTER(x) (((x) & 0x3) << 8)
|
||||||
#define VIRGL_CMD_BLIT_S0_SCISSOR_ENABLE(x) (((x) & 0x1) << 10)
|
#define VIRGL_CMD_BLIT_S0_SCISSOR_ENABLE(x) (((x) & 0x1) << 10)
|
||||||
|
#define VIRGL_CMD_BLIT_S0_RENDER_CONDITION_ENABLE(x) (((x) & 0x1) << 11)
|
||||||
|
#define VIRGL_CMD_BLIT_S0_ALPHA_BLEND(x) (((x) & 0x1) << 12)
|
||||||
#define VIRGL_CMD_BLIT_SCISSOR_MINX_MINY 2
|
#define VIRGL_CMD_BLIT_SCISSOR_MINX_MINY 2
|
||||||
#define VIRGL_CMD_BLIT_SCISSOR_MAXX_MAXY 3
|
#define VIRGL_CMD_BLIT_SCISSOR_MAXX_MAXY 3
|
||||||
#define VIRGL_CMD_BLIT_DST_RES_HANDLE 4
|
#define VIRGL_CMD_BLIT_DST_RES_HANDLE 4
|
||||||
|
@@ -41,6 +41,7 @@ libclllvm_la_CXXFLAGS = \
|
|||||||
$(VISIBILITY_CXXFLAGS) \
|
$(VISIBILITY_CXXFLAGS) \
|
||||||
$(LLVM_CXXFLAGS) \
|
$(LLVM_CXXFLAGS) \
|
||||||
$(DEFINES) \
|
$(DEFINES) \
|
||||||
|
$(LIBELF_CFLAGS) \
|
||||||
-DLIBCLC_INCLUDEDIR=\"$(LIBCLC_INCLUDEDIR)/\" \
|
-DLIBCLC_INCLUDEDIR=\"$(LIBCLC_INCLUDEDIR)/\" \
|
||||||
-DLIBCLC_LIBEXECDIR=\"$(LIBCLC_LIBEXECDIR)/\" \
|
-DLIBCLC_LIBEXECDIR=\"$(LIBCLC_LIBEXECDIR)/\" \
|
||||||
-DCLANG_RESOURCE_DIR=\"$(CLANG_RESOURCE_DIR)\"
|
-DCLANG_RESOURCE_DIR=\"$(CLANG_RESOURCE_DIR)\"
|
||||||
|
@@ -35,6 +35,7 @@ C_SOURCES := \
|
|||||||
nine_flags.h \
|
nine_flags.h \
|
||||||
nine_helpers.c \
|
nine_helpers.c \
|
||||||
nine_helpers.h \
|
nine_helpers.h \
|
||||||
|
nine_limits.h \
|
||||||
nine_lock.c \
|
nine_lock.c \
|
||||||
nine_lock.h \
|
nine_lock.h \
|
||||||
nine_pdata.h \
|
nine_pdata.h \
|
||||||
|
@@ -174,13 +174,18 @@ NineBuffer9_Lock( struct NineBuffer9 *This,
|
|||||||
u_box_1d(OffsetToLock, SizeToLock, &box);
|
u_box_1d(OffsetToLock, SizeToLock, &box);
|
||||||
|
|
||||||
if (This->base.pool == D3DPOOL_MANAGED) {
|
if (This->base.pool == D3DPOOL_MANAGED) {
|
||||||
if (!This->managed.dirty) {
|
/* READONLY doesn't dirty the buffer */
|
||||||
assert(LIST_IS_EMPTY(&This->managed.list));
|
if (!(Flags & D3DLOCK_READONLY)) {
|
||||||
list_add(&This->managed.list, &This->base.base.device->update_buffers);
|
if (!This->managed.dirty) {
|
||||||
This->managed.dirty = TRUE;
|
assert(LIST_IS_EMPTY(&This->managed.list));
|
||||||
This->managed.dirty_box = box;
|
This->managed.dirty = TRUE;
|
||||||
} else {
|
This->managed.dirty_box = box;
|
||||||
u_box_union_2d(&This->managed.dirty_box, &This->managed.dirty_box, &box);
|
} else {
|
||||||
|
u_box_union_2d(&This->managed.dirty_box, &This->managed.dirty_box, &box);
|
||||||
|
/* Do not upload while we are locking, we'll add it back later */
|
||||||
|
if (!LIST_IS_EMPTY(&This->managed.list))
|
||||||
|
list_delinit(&This->managed.list);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
*ppbData = (char *)This->managed.data + OffsetToLock;
|
*ppbData = (char *)This->managed.data + OffsetToLock;
|
||||||
DBG("returning pointer %p\n", *ppbData);
|
DBG("returning pointer %p\n", *ppbData);
|
||||||
@@ -229,8 +234,13 @@ NineBuffer9_Unlock( struct NineBuffer9 *This )
|
|||||||
user_assert(This->nmaps > 0, D3DERR_INVALIDCALL);
|
user_assert(This->nmaps > 0, D3DERR_INVALIDCALL);
|
||||||
if (This->base.pool != D3DPOOL_MANAGED)
|
if (This->base.pool != D3DPOOL_MANAGED)
|
||||||
This->pipe->transfer_unmap(This->pipe, This->maps[--(This->nmaps)]);
|
This->pipe->transfer_unmap(This->pipe, This->maps[--(This->nmaps)]);
|
||||||
else
|
else {
|
||||||
This->nmaps--;
|
This->nmaps--;
|
||||||
|
/* TODO: Fix this to upload at the first draw call needing the data,
|
||||||
|
* instead of at the next draw call */
|
||||||
|
if (!This->nmaps && This->managed.dirty && LIST_IS_EMPTY(&This->managed.list))
|
||||||
|
list_add(&This->managed.list, &This->base.base.device->update_buffers);
|
||||||
|
}
|
||||||
return D3D_OK;
|
return D3D_OK;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@@ -830,6 +830,18 @@ nine_ureg_dst_register(unsigned file, int index)
|
|||||||
return ureg_dst(ureg_src_register(file, index));
|
return ureg_dst(ureg_src_register(file, index));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
static inline struct ureg_src
|
||||||
|
nine_get_position_input(struct shader_translator *tx)
|
||||||
|
{
|
||||||
|
struct ureg_program *ureg = tx->ureg;
|
||||||
|
|
||||||
|
if (tx->wpos_is_sysval)
|
||||||
|
return ureg_DECL_system_value(ureg, TGSI_SEMANTIC_POSITION, 0);
|
||||||
|
else
|
||||||
|
return ureg_DECL_fs_input(ureg, TGSI_SEMANTIC_POSITION,
|
||||||
|
0, TGSI_INTERPOLATE_LINEAR);
|
||||||
|
}
|
||||||
|
|
||||||
static struct ureg_src
|
static struct ureg_src
|
||||||
tx_src_param(struct shader_translator *tx, const struct sm1_src_param *param)
|
tx_src_param(struct shader_translator *tx, const struct sm1_src_param *param)
|
||||||
{
|
{
|
||||||
@@ -955,16 +967,8 @@ tx_src_param(struct shader_translator *tx, const struct sm1_src_param *param)
|
|||||||
case D3DSPR_MISCTYPE:
|
case D3DSPR_MISCTYPE:
|
||||||
switch (param->idx) {
|
switch (param->idx) {
|
||||||
case D3DSMO_POSITION:
|
case D3DSMO_POSITION:
|
||||||
if (ureg_src_is_undef(tx->regs.vPos)) {
|
if (ureg_src_is_undef(tx->regs.vPos))
|
||||||
if (tx->wpos_is_sysval) {
|
tx->regs.vPos = nine_get_position_input(tx);
|
||||||
tx->regs.vPos =
|
|
||||||
ureg_DECL_system_value(ureg, TGSI_SEMANTIC_POSITION, 0);
|
|
||||||
} else {
|
|
||||||
tx->regs.vPos =
|
|
||||||
ureg_DECL_fs_input(ureg, TGSI_SEMANTIC_POSITION, 0,
|
|
||||||
TGSI_INTERPOLATE_LINEAR);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
if (tx->shift_wpos) {
|
if (tx->shift_wpos) {
|
||||||
/* TODO: do this only once */
|
/* TODO: do this only once */
|
||||||
struct ureg_dst wpos = tx_scratch(tx);
|
struct ureg_dst wpos = tx_scratch(tx);
|
||||||
@@ -2048,9 +2052,16 @@ DECL_SPECIAL(DCL)
|
|||||||
unsigned interp_location = 0;
|
unsigned interp_location = 0;
|
||||||
/* SM3 only, SM2 input semantic determined by file */
|
/* SM3 only, SM2 input semantic determined by file */
|
||||||
assert(sem.reg.idx < Elements(tx->regs.v));
|
assert(sem.reg.idx < Elements(tx->regs.v));
|
||||||
|
|
||||||
|
if (tgsi.Name == TGSI_SEMANTIC_POSITION) {
|
||||||
|
tx->regs.v[sem.reg.idx] = nine_get_position_input(tx);
|
||||||
|
return D3D_OK;
|
||||||
|
}
|
||||||
|
|
||||||
if (sem.reg.mod & NINED3DSPDM_CENTROID ||
|
if (sem.reg.mod & NINED3DSPDM_CENTROID ||
|
||||||
(tgsi.Name == TGSI_SEMANTIC_COLOR && tx->info->force_color_in_centroid))
|
(tgsi.Name == TGSI_SEMANTIC_COLOR && tx->info->force_color_in_centroid))
|
||||||
interp_location = TGSI_INTERPOLATE_LOC_CENTROID;
|
interp_location = TGSI_INTERPOLATE_LOC_CENTROID;
|
||||||
|
|
||||||
tx->regs.v[sem.reg.idx] = ureg_DECL_fs_input_cyl_centroid(
|
tx->regs.v[sem.reg.idx] = ureg_DECL_fs_input_cyl_centroid(
|
||||||
ureg, tgsi.Name, tgsi.Index,
|
ureg, tgsi.Name, tgsi.Index,
|
||||||
nine_tgsi_to_interp_mode(&tgsi),
|
nine_tgsi_to_interp_mode(&tgsi),
|
||||||
@@ -3269,12 +3280,7 @@ shader_add_ps_fog_stage(struct shader_translator *tx, struct ureg_src src_col)
|
|||||||
}
|
}
|
||||||
|
|
||||||
if (tx->info->fog_mode != D3DFOG_NONE) {
|
if (tx->info->fog_mode != D3DFOG_NONE) {
|
||||||
if (tx->wpos_is_sysval) {
|
depth = nine_get_position_input(tx);
|
||||||
depth = ureg_DECL_system_value(ureg, TGSI_SEMANTIC_POSITION, 0);
|
|
||||||
} else {
|
|
||||||
depth = ureg_DECL_fs_input(ureg, TGSI_SEMANTIC_POSITION, 0,
|
|
||||||
TGSI_INTERPOLATE_LINEAR);
|
|
||||||
}
|
|
||||||
depth = ureg_scalar(depth, TGSI_SWIZZLE_Z);
|
depth = ureg_scalar(depth, TGSI_SWIZZLE_Z);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@@ -28,9 +28,10 @@ include $(CLEAR_VARS)
|
|||||||
LOCAL_MODULE := gallium_dri
|
LOCAL_MODULE := gallium_dri
|
||||||
|
|
||||||
ifeq ($(MESA_LOLLIPOP_BUILD),true)
|
ifeq ($(MESA_LOLLIPOP_BUILD),true)
|
||||||
LOCAL_MODULE_RELATIVE_PATH := $(notdir $(MESA_DRI_MODULE_PATH))
|
LOCAL_MODULE_RELATIVE_PATH := $(MESA_DRI_MODULE_REL_PATH)
|
||||||
else
|
else
|
||||||
LOCAL_MODULE_PATH := $(MESA_DRI_MODULE_PATH)
|
LOCAL_MODULE_PATH := $(MESA_DRI_MODULE_PATH)
|
||||||
|
LOCAL_UNSTRIPPED_PATH := $(MESA_DRI_MODULE_UNSTRIPPED_PATH)
|
||||||
endif
|
endif
|
||||||
|
|
||||||
LOCAL_SRC_FILES := target.c
|
LOCAL_SRC_FILES := target.c
|
||||||
@@ -109,6 +110,8 @@ LOCAL_WHOLE_STATIC_LIBRARIES := \
|
|||||||
libmesa_st_dri \
|
libmesa_st_dri \
|
||||||
libmesa_st_mesa \
|
libmesa_st_mesa \
|
||||||
libmesa_glsl \
|
libmesa_glsl \
|
||||||
|
libmesa_compiler \
|
||||||
|
libmesa_nir \
|
||||||
libmesa_dri_common \
|
libmesa_dri_common \
|
||||||
libmesa_megadriver_stub \
|
libmesa_megadriver_stub \
|
||||||
libmesa_gallium \
|
libmesa_gallium \
|
||||||
|
@@ -2,9 +2,6 @@ include $(top_srcdir)/src/gallium/Automake.inc
|
|||||||
|
|
||||||
lib_LTLIBRARIES = lib@OPENCL_LIBNAME@.la
|
lib_LTLIBRARIES = lib@OPENCL_LIBNAME@.la
|
||||||
|
|
||||||
AM_CPPFLAGS = \
|
|
||||||
$(LIBELF_CFLAGS)
|
|
||||||
|
|
||||||
lib@OPENCL_LIBNAME@_la_LDFLAGS = \
|
lib@OPENCL_LIBNAME@_la_LDFLAGS = \
|
||||||
$(LLVM_LDFLAGS) \
|
$(LLVM_LDFLAGS) \
|
||||||
-no-undefined \
|
-no-undefined \
|
||||||
|
@@ -59,7 +59,6 @@ endif
|
|||||||
LOCAL_C_INCLUDES := \
|
LOCAL_C_INCLUDES := \
|
||||||
$(MESA_TOP)/src/mapi \
|
$(MESA_TOP)/src/mapi \
|
||||||
$(MESA_TOP)/src/mesa/main \
|
$(MESA_TOP)/src/mesa/main \
|
||||||
$(MESA_TOP)/src/glsl \
|
|
||||||
$(MESA_TOP)/src/compiler/nir \
|
$(MESA_TOP)/src/compiler/nir \
|
||||||
$(MESA_TOP)/src/gallium/include \
|
$(MESA_TOP)/src/gallium/include \
|
||||||
$(MESA_TOP)/src/gallium/auxiliary
|
$(MESA_TOP)/src/gallium/auxiliary
|
||||||
|
@@ -36,7 +36,6 @@ include $(CLEAR_VARS)
|
|||||||
LOCAL_MODULE := libmesa_glsl_utils
|
LOCAL_MODULE := libmesa_glsl_utils
|
||||||
|
|
||||||
LOCAL_C_INCLUDES := \
|
LOCAL_C_INCLUDES := \
|
||||||
$(MESA_TOP)/src/glsl \
|
|
||||||
$(MESA_TOP)/src/compiler/nir \
|
$(MESA_TOP)/src/compiler/nir \
|
||||||
$(MESA_TOP)/src/mapi \
|
$(MESA_TOP)/src/mapi \
|
||||||
$(MESA_TOP)/src/gallium/include \
|
$(MESA_TOP)/src/gallium/include \
|
||||||
@@ -62,7 +61,6 @@ LOCAL_IS_HOST_MODULE := true
|
|||||||
LOCAL_CFLAGS := -D_POSIX_C_SOURCE=199309L
|
LOCAL_CFLAGS := -D_POSIX_C_SOURCE=199309L
|
||||||
|
|
||||||
LOCAL_C_INCLUDES := \
|
LOCAL_C_INCLUDES := \
|
||||||
$(MESA_TOP)/src/glsl \
|
|
||||||
$(MESA_TOP)/src/compiler/nir \
|
$(MESA_TOP)/src/compiler/nir \
|
||||||
$(MESA_TOP)/src/mapi \
|
$(MESA_TOP)/src/mapi \
|
||||||
$(MESA_TOP)/src/gallium/include \
|
$(MESA_TOP)/src/gallium/include \
|
||||||
|
@@ -54,7 +54,6 @@ endif
|
|||||||
LOCAL_C_INCLUDES := \
|
LOCAL_C_INCLUDES := \
|
||||||
$(MESA_TOP)/src/mapi \
|
$(MESA_TOP)/src/mapi \
|
||||||
$(MESA_TOP)/src/mesa/main \
|
$(MESA_TOP)/src/mesa/main \
|
||||||
$(MESA_TOP)/src/glsl \
|
|
||||||
$(MESA_TOP)/src/compiler/nir \
|
$(MESA_TOP)/src/compiler/nir \
|
||||||
$(MESA_TOP)/src/gallium/auxiliary \
|
$(MESA_TOP)/src/gallium/auxiliary \
|
||||||
$(MESA_TOP)/src/gallium/include
|
$(MESA_TOP)/src/gallium/include
|
||||||
|
@@ -35,8 +35,7 @@ LOCAL_MODULE := mesa_gen_matypes
|
|||||||
LOCAL_IS_HOST_MODULE := true
|
LOCAL_IS_HOST_MODULE := true
|
||||||
|
|
||||||
LOCAL_C_INCLUDES := \
|
LOCAL_C_INCLUDES := \
|
||||||
$(MESA_TOP)/src/mapi \
|
$(MESA_TOP)/src/mapi
|
||||||
$(MESA_TOP)/src/glsl
|
|
||||||
|
|
||||||
LOCAL_SRC_FILES := \
|
LOCAL_SRC_FILES := \
|
||||||
x86/gen_matypes.c
|
x86/gen_matypes.c
|
||||||
|
@@ -28,9 +28,6 @@ include $(LOCAL_PATH)/common/Makefile.sources
|
|||||||
#-----------------------------------------------
|
#-----------------------------------------------
|
||||||
# Variables common to all DRI drivers
|
# Variables common to all DRI drivers
|
||||||
|
|
||||||
MESA_DRI_MODULE_PATH := $(TARGET_OUT_SHARED_LIBRARIES)/dri
|
|
||||||
MESA_DRI_MODULE_UNSTRIPPED_PATH := $(TARGET_OUT_SHARED_LIBRARIES_UNSTRIPPED)/dri
|
|
||||||
|
|
||||||
MESA_DRI_CFLAGS := \
|
MESA_DRI_CFLAGS := \
|
||||||
-DHAVE_ANDROID_PLATFORM
|
-DHAVE_ANDROID_PLATFORM
|
||||||
|
|
||||||
@@ -42,6 +39,8 @@ MESA_DRI_C_INCLUDES := \
|
|||||||
|
|
||||||
MESA_DRI_WHOLE_STATIC_LIBRARIES := \
|
MESA_DRI_WHOLE_STATIC_LIBRARIES := \
|
||||||
libmesa_glsl \
|
libmesa_glsl \
|
||||||
|
libmesa_compiler \
|
||||||
|
libmesa_nir \
|
||||||
libmesa_megadriver_stub \
|
libmesa_megadriver_stub \
|
||||||
libmesa_dri_common \
|
libmesa_dri_common \
|
||||||
libmesa_dricore \
|
libmesa_dricore \
|
||||||
|
@@ -74,20 +74,24 @@ $(intermediates)/xmlpool/%.po: $(LOCAL_PATH)/xmlpool/%.po $(POT)
|
|||||||
sed -i -e 's/charset=.*\\n/charset=UTF-8\\n/' $@; \
|
sed -i -e 's/charset=.*\\n/charset=UTF-8\\n/' $@; \
|
||||||
fi
|
fi
|
||||||
|
|
||||||
$(intermediates)/xmlpool/%/LC_MESSAGES/options.mo: $(intermediates)/xmlpool/%.po
|
PRIVATE_SCRIPT := $(LOCAL_PATH)/xmlpool/gen_xmlpool.py
|
||||||
|
PRIVATE_LOCALEDIR := $(intermediates)/xmlpool
|
||||||
|
PRIVATE_TEMPLATE_HEADER := $(LOCAL_PATH)/xmlpool/t_options.h
|
||||||
|
PRIVATE_MO_FILES := $(MESA_DRI_OPTIONS_LANGS:%=$(intermediates)/xmlpool/%/LC_MESSAGES/options.mo)
|
||||||
|
|
||||||
|
LOCAL_GENERATED_SOURCES += $(PRIVATE_MO_FILES)
|
||||||
|
|
||||||
|
$(PRIVATE_MO_FILES): $(intermediates)/xmlpool/%/LC_MESSAGES/options.mo: $(intermediates)/xmlpool/%.po
|
||||||
mkdir -p $(dir $@)
|
mkdir -p $(dir $@)
|
||||||
msgfmt -o $@ $<
|
msgfmt -o $@ $<
|
||||||
|
|
||||||
$(MESA_DRI_OPTIONS_H): PRIVATE_SCRIPT := $(LOCAL_PATH)/xmlpool/gen_xmlpool.py
|
$(LOCAL_GENERATED_SOURCES): PRIVATE_PYTHON := $(MESA_PYTHON2)
|
||||||
$(MESA_DRI_OPTIONS_H): PRIVATE_LOCALEDIR := $(intermediates)/xmlpool
|
$(LOCAL_GENERATED_SOURCES): PRIVATE_CUSTOM_TOOL = $(PRIVATE_PYTHON) $^ $(PRIVATE_TEMPLATE_HEADER) \
|
||||||
$(MESA_DRI_OPTIONS_H): PRIVATE_TEMPLATE_HEADER := $(LOCAL_PATH)/xmlpool/t_options.h
|
|
||||||
$(MESA_DRI_OPTIONS_H): PRIVATE_MO_FILES := $(MESA_DRI_OPTIONS_LANGS:%=$(intermediates)/xmlpool/%/LC_MESSAGES/options.mo)
|
|
||||||
.SECONDEXPANSION:
|
|
||||||
$(MESA_DRI_OPTIONS_H): $$(PRIVATE_SCRIPT) $$(PRIVATE_TEMPLATE_HEADER) $$(PRIVATE_MO_FILES)
|
|
||||||
@mkdir -p $(dir $@)
|
|
||||||
$(hide) $(MESA_PYTHON2) $(PRIVATE_SCRIPT) $(PRIVATE_TEMPLATE_HEADER) \
|
|
||||||
$(PRIVATE_LOCALEDIR) $(MESA_DRI_OPTIONS_LANGS) > $@
|
$(PRIVATE_LOCALEDIR) $(MESA_DRI_OPTIONS_LANGS) > $@
|
||||||
|
|
||||||
|
$(MESA_DRI_OPTIONS_H): $(PRIVATE_SCRIPT) $(PRIVATE_TEMPLATE_HEADER) $(PRIVATE_MO_FILES)
|
||||||
|
$(transform-generated-source)
|
||||||
|
|
||||||
include $(MESA_COMMON_MK)
|
include $(MESA_COMMON_MK)
|
||||||
include $(BUILD_STATIC_LIBRARY)
|
include $(BUILD_STATIC_LIBRARY)
|
||||||
|
|
||||||
|
@@ -27,7 +27,7 @@ include $(CLEAR_VARS)
|
|||||||
|
|
||||||
LOCAL_MODULE := i915_dri
|
LOCAL_MODULE := i915_dri
|
||||||
ifeq ($(MESA_LOLLIPOP_BUILD),true)
|
ifeq ($(MESA_LOLLIPOP_BUILD),true)
|
||||||
LOCAL_MODULE_RELATIVE_PATH := $(notdir $(MESA_DRI_MODULE_PATH))
|
LOCAL_MODULE_RELATIVE_PATH := $(MESA_DRI_MODULE_REL_PATH)
|
||||||
else
|
else
|
||||||
LOCAL_MODULE_PATH := $(MESA_DRI_MODULE_PATH)
|
LOCAL_MODULE_PATH := $(MESA_DRI_MODULE_PATH)
|
||||||
LOCAL_UNSTRIPPED_PATH := $(MESA_DRI_MODULE_UNSTRIPPED_PATH)
|
LOCAL_UNSTRIPPED_PATH := $(MESA_DRI_MODULE_UNSTRIPPED_PATH)
|
||||||
@@ -54,7 +54,8 @@ LOCAL_SHARED_LIBRARIES := \
|
|||||||
libdrm_intel
|
libdrm_intel
|
||||||
|
|
||||||
LOCAL_GENERATED_SOURCES := \
|
LOCAL_GENERATED_SOURCES := \
|
||||||
$(MESA_DRI_OPTIONS_H)
|
$(MESA_DRI_OPTIONS_H) \
|
||||||
|
$(MESA_GEN_NIR_H)
|
||||||
|
|
||||||
include $(MESA_COMMON_MK)
|
include $(MESA_COMMON_MK)
|
||||||
include $(BUILD_SHARED_LIBRARY)
|
include $(BUILD_SHARED_LIBRARY)
|
||||||
|
@@ -27,7 +27,7 @@ include $(CLEAR_VARS)
|
|||||||
|
|
||||||
LOCAL_MODULE := i965_dri
|
LOCAL_MODULE := i965_dri
|
||||||
ifeq ($(MESA_LOLLIPOP_BUILD),true)
|
ifeq ($(MESA_LOLLIPOP_BUILD),true)
|
||||||
LOCAL_MODULE_RELATIVE_PATH := $(notdir $(MESA_DRI_MODULE_PATH))
|
LOCAL_MODULE_RELATIVE_PATH := $(MESA_DRI_MODULE_REL_PATH)
|
||||||
else
|
else
|
||||||
LOCAL_MODULE_PATH := $(MESA_DRI_MODULE_PATH)
|
LOCAL_MODULE_PATH := $(MESA_DRI_MODULE_PATH)
|
||||||
LOCAL_UNSTRIPPED_PATH := $(MESA_DRI_MODULE_UNSTRIPPED_PATH)
|
LOCAL_UNSTRIPPED_PATH := $(MESA_DRI_MODULE_UNSTRIPPED_PATH)
|
||||||
@@ -59,7 +59,8 @@ LOCAL_SHARED_LIBRARIES := \
|
|||||||
libdrm_intel
|
libdrm_intel
|
||||||
|
|
||||||
LOCAL_GENERATED_SOURCES := \
|
LOCAL_GENERATED_SOURCES := \
|
||||||
$(MESA_DRI_OPTIONS_H)
|
$(MESA_DRI_OPTIONS_H) \
|
||||||
|
$(MESA_GEN_NIR_H)
|
||||||
|
|
||||||
include $(MESA_COMMON_MK)
|
include $(MESA_COMMON_MK)
|
||||||
include $(BUILD_SHARED_LIBRARY)
|
include $(BUILD_SHARED_LIBRARY)
|
||||||
|
@@ -139,6 +139,8 @@ operands_match(const fs_inst *a, const fs_inst *b, bool *negate)
|
|||||||
ys[1].f = ys1_imm;
|
ys[1].f = ys1_imm;
|
||||||
|
|
||||||
*negate = (xs0_negate != xs1_negate) != (ys0_negate != ys1_negate);
|
*negate = (xs0_negate != xs1_negate) != (ys0_negate != ys1_negate);
|
||||||
|
if (*negate && (a->saturate || b->saturate))
|
||||||
|
return false;
|
||||||
return ret;
|
return ret;
|
||||||
} else if (!a->is_commutative()) {
|
} else if (!a->is_commutative()) {
|
||||||
bool match = true;
|
bool match = true;
|
||||||
|
@@ -761,15 +761,11 @@ _mesa_set_debug_state_int(struct gl_context *ctx, GLenum pname, GLint val)
|
|||||||
GLint
|
GLint
|
||||||
_mesa_get_debug_state_int(struct gl_context *ctx, GLenum pname)
|
_mesa_get_debug_state_int(struct gl_context *ctx, GLenum pname)
|
||||||
{
|
{
|
||||||
struct gl_debug_state *debug;
|
|
||||||
GLint val;
|
GLint val;
|
||||||
|
|
||||||
mtx_lock(&ctx->DebugMutex);
|
struct gl_debug_state *debug = _mesa_lock_debug_state(ctx);
|
||||||
debug = ctx->Debug;
|
if (!debug)
|
||||||
if (!debug) {
|
|
||||||
mtx_unlock(&ctx->DebugMutex);
|
|
||||||
return 0;
|
return 0;
|
||||||
}
|
|
||||||
|
|
||||||
switch (pname) {
|
switch (pname) {
|
||||||
case GL_DEBUG_OUTPUT:
|
case GL_DEBUG_OUTPUT:
|
||||||
@@ -794,7 +790,7 @@ _mesa_get_debug_state_int(struct gl_context *ctx, GLenum pname)
|
|||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
||||||
mtx_unlock(&ctx->DebugMutex);
|
_mesa_unlock_debug_state(ctx);
|
||||||
|
|
||||||
return val;
|
return val;
|
||||||
}
|
}
|
||||||
@@ -806,15 +802,11 @@ _mesa_get_debug_state_int(struct gl_context *ctx, GLenum pname)
|
|||||||
void *
|
void *
|
||||||
_mesa_get_debug_state_ptr(struct gl_context *ctx, GLenum pname)
|
_mesa_get_debug_state_ptr(struct gl_context *ctx, GLenum pname)
|
||||||
{
|
{
|
||||||
struct gl_debug_state *debug;
|
|
||||||
void *val;
|
void *val;
|
||||||
|
struct gl_debug_state *debug = _mesa_lock_debug_state(ctx);
|
||||||
|
|
||||||
mtx_lock(&ctx->DebugMutex);
|
if (!debug)
|
||||||
debug = ctx->Debug;
|
|
||||||
if (!debug) {
|
|
||||||
mtx_unlock(&ctx->DebugMutex);
|
|
||||||
return NULL;
|
return NULL;
|
||||||
}
|
|
||||||
|
|
||||||
switch (pname) {
|
switch (pname) {
|
||||||
case GL_DEBUG_CALLBACK_FUNCTION_ARB:
|
case GL_DEBUG_CALLBACK_FUNCTION_ARB:
|
||||||
@@ -829,7 +821,7 @@ _mesa_get_debug_state_ptr(struct gl_context *ctx, GLenum pname)
|
|||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
||||||
mtx_unlock(&ctx->DebugMutex);
|
_mesa_unlock_debug_state(ctx);
|
||||||
|
|
||||||
return val;
|
return val;
|
||||||
}
|
}
|
||||||
|
@@ -2815,6 +2815,7 @@ reuse_framebuffer_texture_attachment(struct gl_framebuffer *fb,
|
|||||||
dst_att->Complete = src_att->Complete;
|
dst_att->Complete = src_att->Complete;
|
||||||
dst_att->TextureLevel = src_att->TextureLevel;
|
dst_att->TextureLevel = src_att->TextureLevel;
|
||||||
dst_att->Zoffset = src_att->Zoffset;
|
dst_att->Zoffset = src_att->Zoffset;
|
||||||
|
dst_att->Layered = src_att->Layered;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
@@ -1055,6 +1055,8 @@ find_custom_value(struct gl_context *ctx, const struct value_desc *d, union valu
|
|||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
/* GL_KHR_DEBUG */
|
/* GL_KHR_DEBUG */
|
||||||
|
case GL_DEBUG_OUTPUT:
|
||||||
|
case GL_DEBUG_OUTPUT_SYNCHRONOUS:
|
||||||
case GL_DEBUG_LOGGED_MESSAGES:
|
case GL_DEBUG_LOGGED_MESSAGES:
|
||||||
case GL_DEBUG_NEXT_LOGGED_MESSAGE_LENGTH:
|
case GL_DEBUG_NEXT_LOGGED_MESSAGE_LENGTH:
|
||||||
case GL_DEBUG_GROUP_STACK_DEPTH:
|
case GL_DEBUG_GROUP_STACK_DEPTH:
|
||||||
|
@@ -126,6 +126,8 @@ descriptor=[
|
|||||||
[ "MAX_TEXTURE_MAX_ANISOTROPY_EXT", "CONTEXT_FLOAT(Const.MaxTextureMaxAnisotropy), extra_EXT_texture_filter_anisotropic" ],
|
[ "MAX_TEXTURE_MAX_ANISOTROPY_EXT", "CONTEXT_FLOAT(Const.MaxTextureMaxAnisotropy), extra_EXT_texture_filter_anisotropic" ],
|
||||||
|
|
||||||
# GL_KHR_debug (GL 4.3)/ GL_ARB_debug_output
|
# GL_KHR_debug (GL 4.3)/ GL_ARB_debug_output
|
||||||
|
[ "DEBUG_OUTPUT", "LOC_CUSTOM, TYPE_BOOLEAN, 0, NO_EXTRA" ],
|
||||||
|
[ "DEBUG_OUTPUT_SYNCHRONOUS", "LOC_CUSTOM, TYPE_BOOLEAN, 0, NO_EXTRA" ],
|
||||||
[ "DEBUG_LOGGED_MESSAGES", "LOC_CUSTOM, TYPE_INT, 0, NO_EXTRA" ],
|
[ "DEBUG_LOGGED_MESSAGES", "LOC_CUSTOM, TYPE_INT, 0, NO_EXTRA" ],
|
||||||
[ "DEBUG_NEXT_LOGGED_MESSAGE_LENGTH", "LOC_CUSTOM, TYPE_INT, 0, NO_EXTRA" ],
|
[ "DEBUG_NEXT_LOGGED_MESSAGE_LENGTH", "LOC_CUSTOM, TYPE_INT, 0, NO_EXTRA" ],
|
||||||
[ "MAX_DEBUG_LOGGED_MESSAGES", "CONST(MAX_DEBUG_LOGGED_MESSAGES), NO_EXTRA" ],
|
[ "MAX_DEBUG_LOGGED_MESSAGES", "CONST(MAX_DEBUG_LOGGED_MESSAGES), NO_EXTRA" ],
|
||||||
@@ -773,6 +775,7 @@ descriptor=[
|
|||||||
[ "DEPTH_CLAMP", "CONTEXT_BOOL(Transform.DepthClamp), extra_ARB_depth_clamp" ],
|
[ "DEPTH_CLAMP", "CONTEXT_BOOL(Transform.DepthClamp), extra_ARB_depth_clamp" ],
|
||||||
|
|
||||||
# GL_ATI_fragment_shader
|
# GL_ATI_fragment_shader
|
||||||
|
[ "FRAGMENT_SHADER_ATI", "CONTEXT_BOOL(ATIFragmentShader.Enabled), extra_ATI_fragment_shader" ],
|
||||||
[ "NUM_FRAGMENT_REGISTERS_ATI", "CONST(6), extra_ATI_fragment_shader" ],
|
[ "NUM_FRAGMENT_REGISTERS_ATI", "CONST(6), extra_ATI_fragment_shader" ],
|
||||||
[ "NUM_FRAGMENT_CONSTANTS_ATI", "CONST(8), extra_ATI_fragment_shader" ],
|
[ "NUM_FRAGMENT_CONSTANTS_ATI", "CONST(8), extra_ATI_fragment_shader" ],
|
||||||
[ "NUM_PASSES_ATI", "CONST(2), extra_ATI_fragment_shader" ],
|
[ "NUM_PASSES_ATI", "CONST(2), extra_ATI_fragment_shader" ],
|
||||||
|
@@ -582,7 +582,7 @@ read_rgba_pixels( struct gl_context *ctx,
|
|||||||
void *luminance;
|
void *luminance;
|
||||||
uint32_t luminance_format;
|
uint32_t luminance_format;
|
||||||
|
|
||||||
luminance_stride = width * sizeof(GL_FLOAT);
|
luminance_stride = width * sizeof(GLfloat);
|
||||||
if (format == GL_LUMINANCE_ALPHA)
|
if (format == GL_LUMINANCE_ALPHA)
|
||||||
luminance_stride *= 2;
|
luminance_stride *= 2;
|
||||||
luminance_bytes = height * luminance_stride;
|
luminance_bytes = height * luminance_stride;
|
||||||
|
@@ -240,6 +240,8 @@ init_shader_program(struct gl_shader_program *prog)
|
|||||||
|
|
||||||
prog->TransformFeedback.BufferMode = GL_INTERLEAVED_ATTRIBS;
|
prog->TransformFeedback.BufferMode = GL_INTERLEAVED_ATTRIBS;
|
||||||
|
|
||||||
|
exec_list_make_empty(&prog->EmptyUniformLocations);
|
||||||
|
|
||||||
prog->InfoLog = ralloc_strdup(prog, "");
|
prog->InfoLog = ralloc_strdup(prog, "");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@@ -44,7 +44,7 @@ include $(CLEAR_VARS)
|
|||||||
|
|
||||||
LOCAL_MODULE := libmesa_program
|
LOCAL_MODULE := libmesa_program
|
||||||
LOCAL_MODULE_CLASS := STATIC_LIBRARIES
|
LOCAL_MODULE_CLASS := STATIC_LIBRARIES
|
||||||
LOCAL_STATIC_LIBRARIES := libmesa_glsl
|
LOCAL_STATIC_LIBRARIES := libmesa_nir
|
||||||
|
|
||||||
intermediates := $(call local-generated-sources-dir)
|
intermediates := $(call local-generated-sources-dir)
|
||||||
|
|
||||||
@@ -74,12 +74,13 @@ $(intermediates)/program/lex.yy.c: $(LOCAL_PATH)/program_lexer.l
|
|||||||
LOCAL_C_INCLUDES := \
|
LOCAL_C_INCLUDES := \
|
||||||
$(MESA_TOP)/src/mapi \
|
$(MESA_TOP)/src/mapi \
|
||||||
$(MESA_TOP)/src/mesa \
|
$(MESA_TOP)/src/mesa \
|
||||||
$(MESA_TOP)/src/glsl \
|
|
||||||
$(MESA_TOP)/src/compiler/nir \
|
$(MESA_TOP)/src/compiler/nir \
|
||||||
$(MESA_TOP)/src/gallium/auxiliary \
|
$(MESA_TOP)/src/gallium/auxiliary \
|
||||||
$(MESA_TOP)/src/gallium/include
|
$(MESA_TOP)/src/gallium/include
|
||||||
|
|
||||||
LOCAL_EXPORT_C_INCLUDE_DIRS := $(intermediates)
|
LOCAL_EXPORT_C_INCLUDE_DIRS := $(intermediates)
|
||||||
|
|
||||||
|
LOCAL_GENERATED_SOURCES += $(MESA_GEN_NIR_H)
|
||||||
|
|
||||||
include $(MESA_COMMON_MK)
|
include $(MESA_COMMON_MK)
|
||||||
include $(BUILD_STATIC_LIBRARY)
|
include $(BUILD_STATIC_LIBRARY)
|
||||||
|
@@ -44,6 +44,7 @@
|
|||||||
#include "pipe/p_context.h"
|
#include "pipe/p_context.h"
|
||||||
#include "pipe/p_defines.h"
|
#include "pipe/p_defines.h"
|
||||||
#include "pipe/p_screen.h"
|
#include "pipe/p_screen.h"
|
||||||
|
#include "st_atom.h"
|
||||||
#include "st_context.h"
|
#include "st_context.h"
|
||||||
#include "st_cb_fbo.h"
|
#include "st_cb_fbo.h"
|
||||||
#include "st_cb_flush.h"
|
#include "st_cb_flush.h"
|
||||||
@@ -711,9 +712,17 @@ st_ReadBuffer(struct gl_context *ctx, GLenum buffer)
|
|||||||
|
|
||||||
(void) buffer;
|
(void) buffer;
|
||||||
|
|
||||||
/* add the renderbuffer on demand */
|
/* Check if we need to allocate a front color buffer.
|
||||||
if (fb->_ColorReadBufferIndex >= 0)
|
* Front buffers are often allocated on demand (other color buffers are
|
||||||
|
* always allocated in advance).
|
||||||
|
*/
|
||||||
|
if ((fb->_ColorReadBufferIndex == BUFFER_FRONT_LEFT ||
|
||||||
|
fb->_ColorReadBufferIndex == BUFFER_FRONT_RIGHT) &&
|
||||||
|
fb->Attachment[fb->_ColorReadBufferIndex].Type == GL_NONE) {
|
||||||
|
/* add the buffer */
|
||||||
st_manager_add_color_renderbuffer(st, fb, fb->_ColorReadBufferIndex);
|
st_manager_add_color_renderbuffer(st, fb, fb->_ColorReadBufferIndex);
|
||||||
|
st_validate_state(st, ST_PIPELINE_RENDER);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user