Skip to content

Improve Alert parsing perf#866

Merged
xoofx merged 2 commits intoxoofx:masterfrom
MihaZupan:alert-perf
Apr 15, 2025
Merged

Improve Alert parsing perf#866
xoofx merged 2 commits intoxoofx:masterfrom
MihaZupan:alert-perf

Conversation

@MihaZupan
Copy link
Collaborator

  • Do the fast-path check for ! first since that's likely to fail to lower the overhead on text with lots of regular links.
  • Avoid the string allocations for $"markdown-alert-{alertType.ToString().ToLowerInvariant()}"
    • alertType substring + lowercase + concat result

@xoofx xoofx merged commit 1e17dcd into xoofx:master Apr 15, 2025
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants