Skip to content

[JAX] WAR for CuDNN MXFP8 norm incorrect result - #1696

Closed
jberchtold-nvidia wants to merge 1 commit into
mainfrom
dev/jberchtold/mxfp8-norm-cudnn-version-check
Closed

jberchtold-nvidia wants to merge 1 commit into
mainfrom
dev/jberchtold/mxfp8-norm-cudnn-version-check

Conversation

@jberchtold-nvidia

Copy link
Copy Markdown
Collaborator

Description

Checks CuDNN version and if below the fixed version does unfused norm and MXFP8 quantize to prevent producing incorrect results.

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

  • Check CuDNN version and perform unfused layernorm in JAX if it is below the fixed version
  • If below the fixed CuDNN version, lessen the strictness of the tolerances for MXFP8 norm tests as unfused layernorm loses some precision with the intermediate cast into the input dtype if that is less than fp32

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

@jberchtold-nvidia
jberchtold-nvidia force-pushed the dev/jberchtold/mxfp8-norm-cudnn-version-check branch 2 times, most recently from f509931 to eecfdbd Compare April 17, 2025 20:51
@jberchtold-nvidia

Copy link
Copy Markdown
Collaborator Author

/te-ci L0

@phu0ngng phu0ngng added the 2.3.0 label Apr 17, 2025
@jberchtold-nvidia

Copy link
Copy Markdown
Collaborator Author

/te-ci L0

@jberchtold-nvidia
jberchtold-nvidia force-pushed the dev/jberchtold/mxfp8-norm-cudnn-version-check branch from f282416 to b720fde Compare April 18, 2025 18:10
Check CuDNN version and apply unfused norm if
below a version with the fix

Signed-off-by: Jeremy Berchtold <jberchtold@nvidia.com>
@jberchtold-nvidia
jberchtold-nvidia force-pushed the dev/jberchtold/mxfp8-norm-cudnn-version-check branch from b720fde to fb6e5cd Compare April 18, 2025 18:11
@jberchtold-nvidia

Copy link
Copy Markdown
Collaborator Author

/te-ci L0

@jberchtold-nvidia

Copy link
Copy Markdown
Collaborator Author

Pushed branch to main repo instead of fork by mistake. Closing to replace with #1700

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

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants