Added support for 'uniform' global atomics.

Issue #93.
This commit is contained in:
Matt Pharr
2011-09-28 16:06:07 -07:00
parent d45c536c47
commit aad269fdf4
17 changed files with 264 additions and 57 deletions

View File

@@ -6,8 +6,9 @@ uniform unsigned int32 s = 0;
export void f_f(uniform float RET[], uniform float aFOO[]) {
float a = aFOO[programIndex];
float b = 0;
float delta = 1;
if (programIndex < 2)
b = atomic_add_global(s, 1);
b = atomic_add_global(s, delta);
RET[programIndex] = s;
}