Coverage for src/flag_gems/ops/ge.py: 89%
19 statements
« prev ^ index » next coverage.py v7.6.9, created at 2026-03-22 16:54 +0800
« prev ^ index » next coverage.py v7.6.9, created at 2026-03-22 16:54 +0800
1import logging
3import triton
4import triton.language as tl
6from flag_gems.utils import pointwise_dynamic
8logger = logging.getLogger(__name__)
11@pointwise_dynamic(promotion_methods=[(0, 1, "ALWAYS_BOOL")])
12@triton.jit
13def ge_func(x, y):
14 return x.to(tl.float32) >= y
17def ge(A, B):
18 logger.debug("GEMS GE")
19 return ge_func(A, B)
22@pointwise_dynamic(is_tensor=[True, False], promotion_methods=[(0, 1, "ALWAYS_BOOL")])
23@triton.jit
24def ge_func_scalar(x, y):
25 return x.to(tl.float32) >= y
28def ge_scalar(A, B):
29 logger.debug("GEMS GE SCALAR")
30 return ge_func_scalar(A, B)