Skip to content

[Optimization] merge matmul and add#7191

Open
BingooYang wants to merge 11 commits intoPaddlePaddle:release/2.6from
BingooYang:linear_opt
Open

[Optimization] merge matmul and add#7191
BingooYang wants to merge 11 commits intoPaddlePaddle:release/2.6from
BingooYang:linear_opt

Conversation

@BingooYang
Copy link
Copy Markdown
Contributor

Motivation

性能优化

Modifications

将UnquantizedLinearMethod中的matmul和add用linear替换。
带bias情况基本上有加速,不带bias情况小shape下性能有下降(主要是python层if等调度开销,linear内部实现也是matmul)。
810cbda4d14af8f770c231d04dbe1090

Usage or Command

Accuracy Tests

精度保持一致

Checklist

  • [ x ] Add at least a tag in the PR title.
    • Tag list: [[FDConfig],[APIServer],[Engine], [Scheduler], [PD Disaggregation], [Executor], [Graph Optimization], [Speculative Decoding], [RL], [Models], [Quantization], [Loader], [OP], [KVCache], [DataProcessor], [BugFix], [Docs], [CI], [Optimization], [Feature], [Benchmark], [Others], [XPU], [HPU], [GCU], [DCU], [Iluvatar], [Metax]]
    • You can add new tags based on the PR content, but the semantics must be clear.
  • [ x ] Format your code, run pre-commit before commit.
  • [ x ] Add unit tests. Please write the reason in this PR if no unit tests.
  • [ x ] Provide accuracy results.
  • [ x ] If the current PR is submitting to the release branch, make sure the PR has been submitted to the develop branch, then cherry-pick it to the release branch with the [Cherry-Pick] PR tag.

@paddle-bot
Copy link
Copy Markdown

paddle-bot bot commented Apr 3, 2026

Thanks for your contribution!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant