Coverage for src/flag_gems/runtime/backend/_kunlunxin/ops/logical_or.py: 0%

12 statements  

« prev     ^ index     » next       coverage.py v7.6.9, created at 2026-03-17 02:35 +0800

1import logging 

2 

3import triton 

4import triton.language as tl 

5 

6from ..utils.pointwise_dynamic import pointwise_dynamic 

7 

8logger = logging.getLogger("flag_gems").getChild(__name__.lstrip(".")) 

9 

10 

11@pointwise_dynamic(promotion_methods=[(0, 1, "ALWAYS_BOOL")]) 

12@triton.jit 

13def logical_or_func(x, y): 

14 return x.to(tl.int1).logical_or(y.to(tl.int1)) 

15 

16 

17def logical_or(A, B): 

18 logger.debug("GEMS LOGICAL_OR") 

19 return logical_or_func(A, B)