mirror of
https://github.com/Gericom/teak-llvm.git
synced 2025-06-19 11:35:51 -04:00

AMDGPU targets don't have insturction for it, so it'll be expanded to C * log2 anyway. v2: use native_log2 instead of the more precise sw implementation v3: move to amdgpu v4: drop old AMD copyright Reviewer: Aaron Watry Signed-off-by: Jan Vesely <jan.vesely@rutgers.edu> llvm-svn: 316587
4 lines
119 B
PHP
4 lines
119 B
PHP
_CLC_OVERLOAD _CLC_DEF __CLC_GENTYPE native_log(__CLC_GENTYPE val) {
|
|
return native_log2(val) * (1.0f / M_LOG2E_F);
|
|
}
|