Live data from Hacker News

Viewing profile — mwsherman

mwsherman

HN member
Joined
Tue, Jul 21, 2009, 12:39 AM UTC
HN karma
3,607
Public activity
667 items

About mwsherman

https://clipperhouse.com/

Recent public activity

  1. comment
    Comment #49022708

    I recommend starting with SWAR [1] before SIMD. Our registers are typically 64 bits, and one can try out SIMD patterns without taking a dependency on particular hardware. This will…

  2. comment
    Comment #46504238

    While this article is about perf — and trading off semantic precision by design — there is a Unicode standard for sentence boundaries, may be interesting: https://www.unicode.org/r…

  3. comment
    Comment #46232489

    Shameless plug, if one wishes to track down allocations in Go, an allocations explorer for VS Code: https://marketplace.visualstudio.com/items?itemName=Clipperh...

  4. comment
    Comment #46231657

    I’ve found C#’s frozen dictionary to be useful: https://learn.microsoft.com/en-us/dotnet/api/system.collecti... It’s optimized for fast reads in exchange for expensive creation.

  5. comment
    Comment #45670870

    That’s true, converting in either direction will typically allocate. Which it must, semantically. One can use unsafe for a zero-copy conversion, but now you are breaking the semant…

  6. comment
    Comment #45670197

    There is mention of how len() is bytes, not “characters”. A further subtlety: a rune (codepoint) is still not necessarily a “character” in terms of what is displayed for users — th…

  7. comment
    Comment #45670075

    In Go, string effectively serves as a read-only slice, if we are talking about bytes. ReadOnlySpan in C# is great! In my opinion, Go essentially designed in “span” from the start.

  8. story
  9. comment
    Comment #45563029

    A Go allocations explorer for VS Code. Extension: https://marketplace.visualstudio.com/items?itemName=Clipperh... Source: https://github.com/clipperhouse/go-allocations-vsix

  10. comment
    Comment #45533460

    Shameless plug, you may wish to do Lucene-style tokenizing using the Unicode standard: https://github.com/clipperhouse/uax29/tree/master/words

  11. comment
    Comment #45426021

    I move between Go and C#. I wrote a zero-allocation package in Go [1] and then ported to C# — and the allocations exploded! I had forgotten, or perhaps never realized, that substri…

  12. story
    Show HN: Go Allocations Explorer for VS Code

    I’ve learned that my intuitions about where an allocation is coming from aren’t always correct. One tracks it down by creating a -memprofile then go tool pprof, and then some searc…

  13. story
  14. story
  15. story
  16. comment
    Comment #45040493

    Putting on eng manager hat, the problem to solve is that this regression went undetected, not that Safari is slow. The solution is a test that fails when Chrome and Safari have sub…

  17. story
    Show HN: A more composable rate limiter for Go

    Having seen how complex rate limiting becomes in production, I thought layering should be more expressible.

  18. story
  19. story
  20. story
  21. comment
    Comment #44277625

    C# has implemented some SIMD for IndexOf: https://github.com/dotnet/runtime/pull/63285

  22. story
  23. story
  24. story
  25. comment
    Comment #41883692

    Here’s a way to write tests next to the code: https://clipperhouse.com/go-test-csharp/ (Whether I recommend it, not sure! I did it and then undid it, with suspicion that tests were…