Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
OpenDAS
vllm_cscc
Commits
08b1195e
Unverified
Commit
08b1195e
authored
Jan 29, 2026
by
whx
Committed by
GitHub
Jan 29, 2026
Browse files
[PluggableLayer][2/N] Apply PluggableLayer to linear layers (#33152)
Signed-off-by:
whx-sjtu
<
2952154980@qq.com
>
parent
3bba2edb
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
5 additions
and
5 deletions
+5
-5
vllm/model_executor/layers/linear.py
vllm/model_executor/layers/linear.py
+5
-5
No files found.
vllm/model_executor/layers/linear.py
View file @
08b1195e
...
...
@@ -17,7 +17,7 @@ from vllm.distributed import (
tensor_model_parallel_all_reduce
,
)
from
vllm.logger
import
init_logger
from
vllm.model_executor.custom_op
import
CustomOp
from
vllm.model_executor.custom_op
import
PluggableLayer
from
vllm.model_executor.layers.quantization.base_config
import
(
QuantizationConfig
,
QuantizeMethodBase
,
...
...
@@ -239,7 +239,7 @@ class UnquantizedLinearMethod(LinearMethodBase):
return
dispatch_unquantized_gemm
()(
layer
,
x
,
layer
.
weight
,
bias
)
class
LinearBase
(
CustomOp
):
class
LinearBase
(
PluggableLayer
):
"""Base linear layer.
Args:
...
...
@@ -294,7 +294,7 @@ class LinearBase(CustomOp):
# --8<-- [start:replicated_linear]
@
CustomOp
.
register
(
"replicated_linear"
)
@
PluggableLayer
.
register
(
"replicated_linear"
)
class
ReplicatedLinear
(
LinearBase
):
"""Replicated linear layer.
...
...
@@ -414,7 +414,7 @@ class ReplicatedLinear(LinearBase):
# --8<-- [start:column_parallel_linear]
@
CustomOp
.
register
(
"column_parallel_linear"
)
@
PluggableLayer
.
register
(
"column_parallel_linear"
)
class
ColumnParallelLinear
(
LinearBase
):
"""Linear layer with column parallelism.
...
...
@@ -1273,7 +1273,7 @@ class QKVParallelLinear(ColumnParallelLinear):
# --8<-- [start:row_parallel_linear]
@
CustomOp
.
register
(
"row_parallel_linear"
)
@
PluggableLayer
.
register
(
"row_parallel_linear"
)
class
RowParallelLinear
(
LinearBase
):
"""Linear layer with row parallelism.
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment