OVER 800x IMPROVEMENT?! Benchmarking Regular Expressions in C#

Dev Leader
Dev Leader
437 بار بازدید - 6 ماه پیش - If you check out these
If you check out these benchmarks, you'll see a scenario that you might be doing in your very own code and you could be getting an 800x performance boost. And if you think there's no way you have a Regex in C# that will speed up by 800x, then you might see another benchmark where you could get a 100x gain!

In this video, I walk through the various ways that you can construct a regular expression in C# and the different performance characteristics of each. While this isn't an exhaustive benchmarking collection over a wide variety of C# regexes, hopefully, this serves as some inspiration to benchmark your code!

PLEASE NOTE: There is a critical flaw in the benchmark code as pointed out by a viewer (and THANK YOU for doing so in a very constructive and helpful way). You can read about the correction here:
https://www.devleader.ca/2024/04/12/c...

----
🔑 Membership & Subscriptions:
- 📨 Weekly Newsletter: https://subscribe.devleader.ca
- 🏘️ Private Discord Community: Discord: discord
- 📽️ YouTube Membership: @devleader

🧠 Courses:
- All Courses: https://www.devleader.ca/courses
- Getting Started with C#: https://dometrain.com/course/getting-...
- Deep dive C#: https://dometrain.com/course/deep-div...
- Refactoring For C# Devs: https://dometrain.com/course/from-zer...
- [FREE] Intro to Software Development: [FREE MINI COURSE] - Introduction To ...

🗣️ Social Media & Links:
- All My Links: https://linktr.ee/devleader
- Blog: https://www.devleader.ca/
- TikTok: TikTok: devleader
- LinkedIn: LinkedIn: nickcosentino
- Threads: https://threads.net/@dev.leader
- Twitter: Twitter: DevLeaderCa
- Facebook: Facebook: DevLeaderCa
- Instagram: Instagram: dev.leader
- GitHub: https://github.com/ncosentino/
- Twitch: Twitch: ncosentino
- YouTube: @devleader

❤️ Affiliations & Products/Services That I Love:
- VPS hosting from RackNerd: https://my.racknerd.com/aff.php?aff=9013
- VPS hosting from Contabo: https://www.jdoqocy.com/click-1010286...
- My newsletter platform ConverKit: https://convertkit.com/?lmref=c5X7KQ
- My newsletter referral system SparkLoop: https://dash.sparkloop.app/signup?aff...
- My AI shorts helper Opus Clip: https://opus.pro/?via=2f9e97
- I try to help answer questions at Quora: https://www.quora.com/quoraplus?ch=10...
- My favorite computer parts store Newegg: https://click.linksynergy.com/fs-bin/...
- My favorite supplement store Bulk Supplements: https://glnk.io/63qn/devleader
----

#dotnet #csharp #regex #regularexpressions #benchmark
6 ماه پیش در تاریخ 1403/01/24 منتشر شده است.
437 بـار بازدید شده
... بیشتر