summaryrefslogtreecommitdiffstats
path: root/src/mesa/main/syncobj.c
Commit message (Collapse)AuthorAgeFilesLines
* mesa: check for bufSize > 0 in _mesa_GetSynciv()Brian Paul2013-10-011-1/+1
| | | | | | | | The spec doesn't say GL_INVALID_VALUE should be raised for bufSize <= 0. In any case, memcpy(len < 0) will lead to a crash, so don't allow it. CC: "9.2" <[email protected]> Reviewed-by: Ian Romanick <[email protected]>
* mesa: minor fix-ups for _mesa_validate_sync()Brian Paul2013-10-011-2/+10
| | | | | | Return bool instead of int. Const-qualify the syncObj. Add some comments. Reviewed-by: Ian Romanick <[email protected]>
* mesa: Ensure gl_sync_object is fully initialized.Vinson Lee2013-09-101-1/+1
| | | | | | | | | | | | 278372b47e4db8a022d57f60302eec74819e9341 added the uninitialized pointer field gl_sync_object:Label. A free of this pointer, added in commit 6d8dd59cf53d2f47b817d79204a52bb3a46e8c77, resulted in a crash. This patch fixes piglit ARB_sync regressions with swrast introduced by 6d8dd59cf53d2f47b817d79204a52bb3a46e8c77. Signed-off-by: Vinson Lee <[email protected]> Reviewed-by: Brian Paul <[email protected]>
* mesa: make _mesa_validate_sync() non-staticTimothy Arceri2013-09-041-1/+1
| | | | | | Signed-off-by: Timothy Arceri <[email protected]> Reviewed-by: Brian Paul <[email protected]>
* mesa: free object labels when deletingTimothy Arceri2013-09-041-0/+1
| | | | | | Signed-off-by: Timothy Arceri <[email protected]> Reviewed-by: Brian Paul <[email protected]>
* mesa: remove #include "mfeatures.h" from numerous source filesBrian Paul2013-04-171-1/+0
| | | | | | None of the remaining FEATURE_x symbols in mfeatures.h are used anymore. Reviewed-by: Jordan Justen <[email protected]>
* mesa: Initially populate the display list with the exec list.Eric Anholt2013-01-211-14/+0
| | | | | | | | This cuts out a ton of code to make functions not set to a save_ variant match. Reviewed-by: Brian Paul <[email protected]> Reviewed-by: Ian Romanick <[email protected]>
* mesa: Drop manual checks for outside begin/end.Eric Anholt2013-01-211-3/+0
| | | | | | | | | | | We now have a separate dispatch table for begin/end that prevent these functions from being entered during that time. The ASSERT_OUTSIDE_BEGIN_END_WITH_RETVALs are left because I don't want to change any return values or introduce new error-only stubs at this point. Reviewed-by: Brian Paul <[email protected]> Reviewed-by: Ian Romanick <[email protected]>
* mesa syncobj: don't store a pointer to the set_entryJordan Justen2012-12-101-4/+10
| | | | | | | | | | | | The set_entry pointer can become invalid if the set table is re-hashed. This likely will fix https://bugs.freedesktop.org/show_bug.cgi?id=58012 (Regression since 56e95d3c) Signed-off-by: Jordan Justen <[email protected]> Reviewed-by: Eric Anholt <[email protected]>
* mesa: validate that sync objects were created by mesaJordan Justen2012-12-061-8/+15
| | | | | | | | | | | | | | Previously, the user could send in a pointer that was not created by mesa. When we dereferenced that pointer, there would be an exception. Now we keep a set of pointers and verify that the pointer exists in that set before dereferencing it. Note: This fixes several crashing gles3conform tests. Signed-off-by: Jordan Justen <[email protected]> Reviewed-by: Brian Paul <[email protected]>
* main/syncobj: return GL_INVALID_VALUE for invalid sync objectsJordan Justen2012-12-061-4/+4
| | | | | | | | Note: The GL/GLES3 web man pages don't seem to properly document glWaitSync's error when the sync object is invalid. Signed-off-by: Jordan Justen <[email protected]> Reviewed-by: Brian Paul <[email protected]>
* mesa: fix uint64 printing in syncobj.cBrian Paul2012-12-031-1/+3
| | | | | | | | | To silence printf format warnings. v2: insert "0x" prefix Reviewed-by: Ian Romanick <[email protected]> Reviewed-by: Chad Versace <[email protected]>
* mesa: return INVALID_VALUE from WaitSync if timeout != GL_TIMEOUT_IGNOREDMatt Turner2012-11-151-5/+2
| | | | | | | This was added in version 22 of the GL_ARB_sync spec. Fixes gles3conform's sync_error_waitsync_timeout test. Reviewed-by: Kenneth Graunke <[email protected]>
* mesa: return INVALID_VALUE from WaitSync if flags != 0Matt Turner2012-11-151-1/+1
| | | | | | Fixes gles3conform's sync_error_waitsync_flags test. Reviewed-by: Chad Versace <[email protected]> Reviewed-by: Kenneth Graunke <[email protected]>
* mesa: return INVALID_VALUE from ClientWaitSync if flags contains an ↵Matt Turner2012-11-151-1/+1
| | | | | | | | unsupported flag Fixes gles3conform's sync_error_clientwaitsync_flags test. Reviewed-by: Chad Versace <[email protected]> Reviewed-by: Kenneth Graunke <[email protected]>
* mesa: remove FEATURE_ARB_sync define.Oliver McFadden2012-09-151-3/+0
| | | | | Signed-off-by: Oliver McFadden <[email protected]> Reviewed-by: Brian Paul <[email protected]>
* mesa: don't wait in _mesa_ClientWaitSync if timeout is 0Vadim Girlin2012-09-011-2/+6
| | | | | | | | | | | | | | From ARB_sync spec: If the value of <timeout> is zero, then ClientWaitSync does not block, but simply tests the current state of <sync>. TIMEOUT_EXPIRED will be returned in this case if <sync> is not signaled, even though no actual wait was performed. Fixes random fails of the arb_sync-timeout-zero piglit test on r600g. Signed-off-by: Vadim Girlin <[email protected]> Reviewed-by: Eric Anholt <[email protected]>
* mesa: Directly include mfeatures.h in files that perform feature tests.Vinson Lee2011-01-071-0/+1
|
* mesa: Include mtypes.h in files that use gl_context struct.Vinson Lee2011-01-051-0/+1
| | | | | | Directly include mtypes.h if a file uses a gl_context struct. This allows future removal of headers that are not strictly necessary but indirectly include mtypes.h for a file.
* Drop GLcontext typedef and use struct gl_context insteadKristian Høgsberg2010-10-131-9/+9
|
* mesa: Less FEATURE_ARB_sync tests.Chia-I Wu2010-09-141-0/+15
| | | | | Add dummy static inline definitions to syncobj.h when FEATURE_ARB_sync is 0, and remove most FEATURE_ARB_sync tests.
* Replace _mesa_malloc, _mesa_calloc and _mesa_free with plain libc versionsKristian Høgsberg2010-02-191-1/+1
|
* Remove _mesa_memcpy in favor of plain memcpy.Kenneth Graunke2010-02-191-1/+1
| | | | This may break the SUNOS4 build, but it's no longer relevant.
* mesa: Fix calling conventions of sync object api callbacks.Michal Krol2009-09-071-6/+6
|
* mesa: rename gl_sync_object::Status to StatusFlagBrian Paul2009-09-031-5/+5
| | | | | There's a symbol collision with X11/Xlib.h #define Status int in the Mesa xlib code. This seems the simpliest way to work around this.
* Don't dereference function pointers in calls.Ian Romanick2009-09-031-7/+7
| | | | | | I'm apparently alone in prefering this calling convention, so I'll be a team player. :p Based on review comments by Brian Paul and Eric Anholt.
* Whitespace and include file clean-up.Ian Romanick2009-09-031-14/+0
| | | | Based on review comments by Brian Paul.
* Use MIN2 instead of open-coded versionIan Romanick2009-09-031-1/+2
| | | | Based on review comments by Brian Paul.
* ARB sync: Fix delete behavior and context destruction behaviorIan Romanick2009-09-031-23/+73
| | | | | | | I believe this resolves the outstanding issues WRT sync object deletetion. I have also added a large comment at the top of syncobj.c describing the expected memory management behavior. I'm still a little uncertain about the locking on ctx->Shared.
* ARB sync: Add support for GL_ARB_sync to swrastIan Romanick2009-09-031-0/+372
This isn't quite right yet. The delete behavior and the context clean-up needs some work.