mirror of
https://github.com/matrix-construct/construct
synced 2024-11-16 15:00:51 +01:00
ircd::simt: Add intrinsic integer max.
This commit is contained in:
parent
0d8f069fbf
commit
2b30d775b9
1 changed files with 20 additions and 0 deletions
|
@ -30,3 +30,23 @@ ircd_simt_reduce_max_flldr(__local float *const buf,
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
#ifdef __OPENCL_VERSION__
|
||||||
|
inline void
|
||||||
|
ircd_simt_reduce_max_illdr(__local int *const buf,
|
||||||
|
const uint ln,
|
||||||
|
const uint li)
|
||||||
|
{
|
||||||
|
buf[li] = atomic_max(buf, buf[li]);
|
||||||
|
}
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#ifdef __OPENCL_VERSION__
|
||||||
|
inline void
|
||||||
|
ircd_simt_reduce_max_ulldr(__local uint *const buf,
|
||||||
|
const uint ln,
|
||||||
|
const uint li)
|
||||||
|
{
|
||||||
|
buf[li] = atomic_max(buf, buf[li]);
|
||||||
|
}
|
||||||
|
#endif
|
||||||
|
|
Loading…
Reference in a new issue