mirror of
https://github.com/tinygrad/tinygrad.git
synced 2026-02-13 08:05:10 -05:00
#include <tgmath.h> in ops_clang (#3927)
* different clang sqrt/log2/exp2/sin function based on dtype fixed softmax_argmax issue in #3552 for clang. * tgmath.h * revert those
This commit is contained in:
@@ -4,7 +4,7 @@ from tinygrad.helpers import cpu_time_execution
|
||||
from tinygrad.codegen.kernel import LinearizerOptions
|
||||
from tinygrad.renderer.cstyle import uops_to_cstyle, CStyleLanguage
|
||||
|
||||
CLANG_PROGRAM_HEADER = '#include <stdbool.h>\n#include <math.h>\n#define max(x,y) ((x>y)?x:y)\n#define half __fp16\n'
|
||||
CLANG_PROGRAM_HEADER = '#include <stdbool.h>\n#include <tgmath.h>\n#define max(x,y) ((x>y)?x:y)\n#define half __fp16\n'
|
||||
|
||||
class ClangCompiler(Compiler):
|
||||
linearizer_opts = LinearizerOptions("CLANG", supports_float4=False, has_local=False)
|
||||
|
||||
Reference in New Issue
Block a user