v2: Fix shell handling
v3: - Use ci job template for build checks
- rename clang_fuzzer result dir
(Both suggested by Lepton Wo)
v4: - ci Unify all tests
- Fix directory (Lepton Wu)
Signed-off-by: Gert Wollny <gert.wollny@collabora.com>
Reviewed-by: Lepton Wu <lepton@chromium.org>
One bug was found when running dEQP-GLES3.functional.fragment_out.random.*.
If run them one by one, they pass. If run them all together, some cases fails.
The fix is: when independent_blend_enable changes from true to false, we should call
glColorMask, otherwise color masks for some color buffers could stay in
stale states.
Signed-off-by: Lepton Wu <lepton@chromium.org>
Reviewed-by: Gert Wollny <gert.wollny@collabora.com>
Change to use eglWaitSyncKHR which is a server side fence and it
could be sightly better.
Signed-off-by: Lepton Wu <lepton@chromium.org>
Reviewed-by: David Riley <davidriley@chromium.org>
When switching context, if we want to use shared objects from previous
context, we need to insert glWaitSync to make sure the GL commands
are executed in sequences. This fixes 8 dEQP tests on mali:
dEQP-GLES2.functional.texture.mipmap.2d.generate.a8_fastest
dEQP-GLES2.functional.texture.mipmap.2d.generate.a8_nicest
dEQP-GLES2.functional.texture.mipmap.cube.generate.a8_fastest
dEQP-GLES2.functional.texture.mipmap.cube.generate.a8_nicest
dEQP-GLES2.functional.texture.specification.basic_copyteximage2d.2d_rgb
dEQP-GLES2.functional.texture.specification.basic_copyteximage2d.cube_rgb
dEQP-GLES2.functional.texture.specification.basic_copytexsubimage2d.2d_rgb
dEQP-GLES2.functional.texture.specification.basic_copytexsubimage2d.cube_rgb
Signed-off-by: Lepton Wu <lepton@chromium.org>
Reviewed-by: Gert Wollny <gert.wollny@collabora.com>
This was hard coded as zero before and can't be changed at runtime.
Change to use the "VREND_DEBUG" environment variable to control this
behavior.
Signed-off-by: Lepton Wu <lepton@chromium.org>
Reviewed-by: Gert Wollny <gert.wollny@collabora.com>
Container objects like framebuffers are not shared between contexts
and we have to delete them in the original context. Otherwise we
could delete wrong objects which is in using by others.
Signed-off-by: Lepton Wu <lepton@chromium.org>
Reviewed-by: Gert Wollny <gert.wollny@collabora.com>
Test whether submitting command 0x25 (CS shader execution) without
submitting a CS shader before is handled well.
Related #155
Signed-off-by: Gert Wollny <gert.wollny@collabora.com>
Reviewed-by: Gurchetan Singh <gurchetansingh@chromium.org>
The structure is allocated outside this function and also deleted there
if texture creation failes or it is asserted that it doesn't fail
for intermediate blitting textures. Therefore, don't free the struct inside
this function when allocation fails.
Closes#154
Signed-off-by: Gert Wollny <gert.wollny@collabora.com>
On big endian the byte ordering is reverse, and so should be the
uint32_t test value.
Signed-off-by: Gert Wollny <gert.wollny@collabora.com>
Tested-by: Christian Ehrhardt <christian.ehrhardt@canonical.com>
When VIRGL_LOG_FILE gets set, put log into it. This is similar
with MESA_LOG_FILE. An improvement over MESA_LOG_FILE is that
it supports "%PID%" in file name and will replace it with pid
of the current process.
Signed-off-by: Lepton Wu <lepton@chromium.org>
Reviewed-by: Gert Wollny <gert.wollny@collabora.com>
Some GPU drivers (like mali from arm) doesn't like anything other than
"#version" in the first line.
Signed-off-by: Lepton Wu <lepton@chromium.org>
Reviewed-by: Gert Wollny <gert.wollny@collabora.com>
Otherwise, this error is encountered:
meson.build:89:0: ERROR: Tried to access unknown option "debug".
Reviewed-by: Gert Wollny <gert.wollny@collabora.com>
Updates meson.build so that epoxy headers are found when they are
in a non standard location specified via pkg config.
Reviewed-by: Gurchetan Singh <gurchetansingh@chromium.org>
Since vtest_server and the tests make use of private interfaces we must
mirror the autotoosl build that keeps the private interfaces in a static
library so that these functions can be called by the test code. The main
library that get installed then uses this static library and adds the
exported interface.
Closes#152
Signed-off-by: Gert Wollny <gert.wollny@collabora.com>
Reviewed-by: Gurchetan Singh <gurchetansingh@chromium.org>
The old code is buggy and set numlayers to 1 for GL_TEXTURE_2D_ARRAY
when creating the view. Just change to use array_size directly.
This fixes such tests in CtsNativeHardwareTestCases:
android.hardware.nativehardware.cts.AHardwareBufferNativeTests#MultipleLayers_ColorTest_MipmapComplete_GL_RGB10_A2
android.hardware.nativehardware.cts.AHardwareBufferNativeTests#MultipleLayers_ColorTest_MipmapComplete_GL_RGB8
android.hardware.nativehardware.cts.AHardwareBufferNativeTests#MultipleLayers_ColorTest_MipmapComplete_GL_RGBA16F
android.hardware.nativehardware.cts.AHardwareBufferNativeTests#MultipleLayers_ColorTest_MipmapComplete_GL_RGBA8
android.hardware.nativehardware.cts.AHardwareBufferNativeTests#MultipleLayers_ColorTest_MipmapComplete_GL_SRGB8_ALPHA8_sRGB
Reviewed-by: Gurchetan Singh <gurchetansingh@chromium.org>
Signed-off-by: Lepton Wu <lepton@chromium.org>
v2: - Force X11 EGL platform. The compile time platform is drm, but this
doesn't work for "spec/egl_khr_create_context/valid debug flag" and
the other piglits seem to force X11.
- Create a html summary and add it to the artifacts
Fixes piglits: spec/egl_khr_create_context/valid debug flag gles[23]
Signed-off-by: Gert Wollny <gert.wollny@collabora.com>
Reviewed-by: Lepton Wu <lepton@chromium.org>
Also fix and document the versioning with meson.
Related #149
Signed-off-by: Gert Wollny <gert.wollny@collabora.com>
Reviewed-by: Lepton Wu <lepton@chromium.org>
We only need a recent version of gbm when enable_gbm_allocation gets
set.
Close#134
Reviewed-by: Gert Wollny <gert.wollny@collabora.com>
Signed-off-by: Lepton Wu <lepton@chromium.org>
Do the same thing we do with regular textures, and swap the R and B
color channels.
TEST=Portal, HL2 have better lighting in Crostini
Reviewed-by: Gert Wollny <gert.wollny@collabora.com>
Fixes:
warning: pointer of type ‘void *’ used in arithmetic [-Wpointer-arith]
Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
Reviewed-by: Gert Wollny <gert.wollny@collabora.com>
Fixes
ISO C does not support ‘__FUNCTION__’ predefined identifier
Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
Reviewed-by: Gert Wollny <gert.wollny@collabora.com>
Fixes:
warning: ISO C forbids ‘return’ with expression, in function returning void
Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
Reviewed-by: Gert Wollny <gert.wollny@collabora.com>
With the prior patch and without this one, I get
../src/.libs/libvrend.a(vrend_renderer.o): In function `vrend_format_can_scanout':
src/vrend_renderer.c:703: undefined reference to `gbm'
src/vrend_renderer.c:703: undefined reference to `gbm
src/vrend_renderer.c:706: undefined reference to `gbm'
../src/.libs/libvrend.a(vrend_renderer.o): In function `vrend_resource_gbm_init':
/virglrenderer/src/vrend_renderer.c:6337: undefined reference to `gbm'
/virglrenderer/src/vrend_renderer.c:6337: undefined reference to `gbm'
Reviewed-by: Gert Wollny <gert.wollny@collabora.com>
It's a bit misleading currently. For example, all resources have
guest memory associated with them, and resource can be both a GL
texture and GBM buffer at the same time. Use bits to more accurately
capture this.
No functional change.
Reviewed-by: Gert Wollny <gert.wollny@collabora.com>
For random stuff not in src/util.h
util_bitmask is too heavyweight for what I was looking for.
v2: Make macros return 0 or 1 (@davidriley)
v3: static inline macros (@gerddie)
Reviewed-by: Gert Wollny <gert.wollny@collabora.com>
We don't know whether the caller cleans up the error states they are
responsible for, so do this here. This is needed to correctly query
some features, because otherwise checks that rely on correct error
reporting might give the wrong result.
v2: Log stale error codes (Gurchetan)
Closes#148
Signed-off-by: Gert Wollny <gert.wollny@collabora.com>
Reviewed-by: Gurchetan Singh <gurchetansingh@chromium.org>
Using testing will need continued updates of the basic build scripts and
sometimes packages might even not be available, so lets switch to buster
and buster-backports.
v2: Fix include directory declaration
Closes: #147
Signed-off-by: Gert Wollny <gert.wollny@collabora.com>
Reviewed-by: Gurchetan Singh <gurchetansingh@chromium.org>
When transfering from host use normal path. On sona performance jumps
from 46 mpixels/s to ~105 mpixels/s.
Signed-off-by: David Riley <davidriley@chromium.org>
Reviewed-by: Gurchetan Singh <gurchetansingh@chromium.org>
Fix cases where trying to transfer from host directly after submitting
command buffer (eg when trying to run
dEQP-GLES2.functional.read_pixels.* or crosvm gpu_renderer::simple_clear
tests) would fail non-deterministically due to the mapping occuring
prior to the rendering completing by forcing a fence.
In particular Mali platforms are highly susceptible to synchronization
issues and also require setting the context prior to fencing.
Signed-off-by: David Riley <davidriley@chromium.org>
Reviewed-by: Gurchetan Singh <gurchetansingh@chromium.org>
Add helper to complete GPU operations to allow synchronization prior to
CPU accesses like mapping buffers on platforms that require it (ie ARM
Mali).
Signed-off-by: David Riley <davidriley@chromium.org>
Reviewed-by: Gurchetan Singh <gurchetansingh@chromium.org>
Gbm-resources can be used for data blobs. These are created with a
height of 1 and the required width, which can easily exceed the maximum
supported texture width.
Signed-off-by: David Stevens <stevensd@chromium.org>
Reviewed-by: Gert Wollny <gert.wollny@collabora.com>