BlazingFastDotnet README

项目的 README,来自 github.com/EgorBo/BlazingFastDotnet。合并为一个 markdown 文件:README.md。

Blazing Fast .NET

Tips & tricks to tune .NET 10.0 - 11.0 workloads for better performance (mostly targeting benchmarks), packaged as a single SKILL.md for AI coding agents. It reads fine as a regular doc too.

Usage

I don't expect it to be useful as an always-on skill. It's rather something to consult on demand when you need to optimize a .NET workload, e.g. paste this into your coding agent:

Read https://raw.githubusercontent.com/EgorBo/BlazingFastDotnet/main/SKILL.md and use it to
improve the performance of this app. Measure a baseline first, profile to find
the actual bottleneck, apply one change at a time, and keep only changes with a measurable win.

[!NOTE] This is not an official Microsoft guide or documentation. Use at your own discretion and always measure performance changes.

Bonus prompt: inspecting a library for safety issues

In order to inspect a library for safety issues / code quality, consider the following prompt:

Inspect the current codebase for issues listed in https://raw.githubusercontent.com/dotnet/docs/refs/heads/main/docs/standard/unsafe-code/best-practices.md

Do not attempt to make minimal reproductions or fixes. Focus on identifying potential safety and code quality issues.
Report two groups: 1) correctness issues, 2) anti-patterns

The link points to a raw Markdown version of this article. The Do not attempt to make minimal reproductions instruction is intended to prevent the model from creating a repro and triggering cybersecurity safeguards.

Not welcome in this doc

BlazingFastDotnet (EgorBo/BlazingFastDotnet)

正在搜索数据库…

这是什么?这是一个精选的 SKILL.md 文件,收录了调优 .NET 10.0–11.0 工作负载的技巧和窍门,适用于需要优化性能关键代码的场景,主要面向基准测试(benchmark)场景。需要优化时,可将它粘贴到 AI 编程代理中。
这是需要安装的工具,还是仅供参考的文档?它是一个单独的 Markdown 文件(SKILL.md),不是可以安装的软件,需要时查阅即可,不需要运行。单独阅读也完全可以,相当于一份常规的性能优化指南。
我该怎么使用它?无需安装。每当你想优化 .NET 工作负载时,复制 SKILL.md 的内容,粘贴到你的 AI 编程代理的上下文中即可。
它依赖某些特定工具吗?这些技巧默认你已经在使用 BenchmarkDotNet 进行基准测试,并使用 FlameGraph 生成 perf 火焰图;作者有意把第三方依赖限制在这两个工具之内。
哪些优化是刻意不包含的?它避开了需要 unsafe 上下文的优化(涉及 unsafe-v1 或 unsafe-v2 规则),也不包含手动租用和归还 ArrayPool 的建议,因为作者认为这种做法太容易出错,风险较高。
这是微软官方的性能指南吗?不是。README 明确说明,它不是微软官方的指南或文档,并建议在采纳任何技巧之前,始终先自行测量性能变化。
它针对哪些 .NET 版本?它专注于调优 .NET 10.0 至 11.0 的工作负载,主要面向基准测试风格的性能场景。
为什么要按需查阅,而不是让它一直加载在我的代理中?作者把它做成了一份内容密集、用途狭窄的文档,用于特定的性能调优环节,而不是一个持续运行、始终加载的技能。
作者
EgorBo
大小
0.2 MB
星标
315
更新
提交Nov 10
时长
26天
提交 · 90 天