Skip to content

[Ascend] Add vendor:ascend backend#43

Closed
Sans1J wants to merge 0 commit into
flagos-ai:mainfrom
Sans1J:main
Closed

[Ascend] Add vendor:ascend backend#43
Sans1J wants to merge 0 commit into
flagos-ai:mainfrom
Sans1J:main

Conversation

@Sans1J

@Sans1J Sans1J commented Feb 27, 2026

Copy link
Copy Markdown

Description

Add vendor:ascend backend.Please review.

Fixes # (issue)

Type of change

  • Documentation change (change only to the documentation, either a fix or a new content)
  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to not work as expected)
  • Infra/Build change
  • Code refactoring

Changes

Please list the changes introduced in this PR:

  • Change A
  • Change B

Checklist:

  • I have read and followed the contributing guidelines
  • The functionality is complete
  • I have commented my code, particularly in hard-to-understand areas
  • I have made corresponding changes to the documentation
  • My changes generate no new warnings
  • I have added tests that prove my fix is effective or that my feature works
  • New and existing unit tests pass locally with my changes

@CLAassistant

CLAassistant commented Feb 27, 2026

Copy link
Copy Markdown

CLA assistant check
All committers have signed the CLA.


impls = [
# Activations - Forward
OpImpl(op_name="gelu", impl_id="vendor.ascend", kind=BackendImplKind.VENDOR, fn=_bind_is_available(backend.gelu, is_avail), vendor="ASCEND", priority=100),

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why was only one gelu function registered?
During the Qwen3 adaptation process, can all operators run successfully based on the FlagOS backend? Is there no dependency on the Vendor/ascend backend?

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Only by adding the gelu registration under vendor and other initialization modules, the In-tree test case (rmsnorm_fwd) provided in PR#4 was successfully run, and the test showed that the adaptation code of TE-FL on ascend functions normally.
During the execution of Qwen3, according to the printed log "TE-FL manager.py:417 INFO] Op 'multi_tensor_adam' using 'default.flagos' (kind=flagos, vendor=None)", it was confirmed that multi_tensor_adam was successfully replaced. There were no printed logs for other operators, indicating that vendor dependencies are not involved at this time.

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Does this mean that when training Qwen3 on ASCEND, most of the ops in transformer_engine were not used, and only multi_tensor_adam was utilized?

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Perhaps this is so.
When adapting to TE on NPU, MindSpeed replaces some implementations, which may be the reason for the impact.

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Could you provide a YAML file for training Qwen3 with FlagScale? We'd like to confirm the system configuration.

@lxd-cumt

Copy link
Copy Markdown
Collaborator

Please Review

Please complete the PR description

@Sans1J

Sans1J commented Feb 28, 2026

Copy link
Copy Markdown
Author

Please Review

Please complete the PR description

done

@lxd-cumt

lxd-cumt commented Mar 2, 2026

Copy link
Copy Markdown
Collaborator

Please pull the latest main branch, and format code, and pass CICD tests

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.

3 participants