[Kernel] Introduce sglang.kernels namespace and migrate scattered triton_ops kernels (RFC #29630, Phase 2) (#30044)
Co-authored-by: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
This commit is contained in:
co-authored by
Claude Opus 4.8
parent
e9493a015c
commit
6ed9843b57
@@ -6,7 +6,7 @@ import tempfile
|
||||
import unittest
|
||||
from unittest.mock import patch
|
||||
|
||||
from sglang.srt.lora.triton_ops.lora_tuning_config import (
|
||||
from sglang.kernels.ops.gemm.lora_tuning_config import (
|
||||
DEFAULT_EXPAND_CONFIG,
|
||||
DEFAULT_SHRINK_CONFIG,
|
||||
get_lora_config_file_name,
|
||||
@@ -15,7 +15,7 @@ from sglang.srt.lora.triton_ops.lora_tuning_config import (
|
||||
get_lora_shrink_config,
|
||||
)
|
||||
|
||||
_MODULE = "sglang.srt.lora.triton_ops.lora_tuning_config"
|
||||
_MODULE = "sglang.kernels.ops.gemm.lora_tuning_config"
|
||||
|
||||
# Shared fixture
|
||||
_TUNED_CONFIGS = {
|
||||
@@ -88,7 +88,7 @@ class TestConfigSelection(unittest.TestCase):
|
||||
|
||||
def setUp(self):
|
||||
get_lora_configs.cache_clear()
|
||||
from sglang.srt.lora.triton_ops import lora_tuning_config
|
||||
from sglang.kernels.ops.gemm import lora_tuning_config
|
||||
|
||||
lora_tuning_config._logged_configs.clear()
|
||||
|
||||
|
||||
@@ -3,10 +3,10 @@ import unittest
|
||||
|
||||
import torch
|
||||
|
||||
from sglang.srt.layers.attention.triton_ops.decode_attention import (
|
||||
from sglang.kernels.ops.attention.decode_attention import (
|
||||
decode_attention_fwd_grouped,
|
||||
)
|
||||
from sglang.srt.layers.attention.triton_ops.rocm_mla_decode_rope import (
|
||||
from sglang.kernels.ops.attention.rocm_mla_decode_rope import (
|
||||
decode_attention_fwd_grouped_rope,
|
||||
)
|
||||
from sglang.srt.layers.rotary_embedding import DeepseekScalingRotaryEmbedding
|
||||
|
||||
@@ -6,7 +6,7 @@ import unittest
|
||||
|
||||
import torch
|
||||
|
||||
from sglang.srt.layers.attention.triton_ops.trtllm_fp8_kv_kernel import (
|
||||
from sglang.kernels.ops.kvcache.trtllm_fp8_kv_kernel import (
|
||||
fused_fp8_set_kv_buffer,
|
||||
)
|
||||
from sglang.test.test_utils import CustomTestCase
|
||||
|
||||
Reference in New Issue
Block a user