Sign in

    simdstring

    SIMD-accelerated string utilities for Moonbit native backend

    string
    utilities
    native
    simd
    fast
    Download zip
    Version
    0.1.5
    License
    MIT
    Last updated
    last year
    Downloads
    60

    #simdstring 🚀

    SIMD-accelerated string utilities for Moonbit native backend.

    #📊 Benchmarks

    #contains_char Performance

    Metriccore/stringScalarSSE4.2AVX2
    Time (μs)684.6974.8810.168.24
    Throughput0.54 GB/s4.98 GB/s36.68 GB/s45.21 GB/s

    Test environment: AMD Ryzen 7 3750H, Moonbit native backend Run benchmark:

    moon run ./bench/contains_char --release --target native

    #🛠️ Installation

    Add as dependency:

    moon add MINGtoMING/simdstring

    Then include in your moon.pkg.json:

    { "is-main": true, "import": [ "MINGtoMING/simdstring" ] }

    #📚 API Coverage

    #Current Implementation Status

    MethodAVX2SSE4.2Scalar
    contains_char✅✅✅
    contains⏳⏳⏳
    find⏳⏳⏳
    starts_with⏳⏳⏳
    ends_with⏳⏳⏳
    to_upper⏳⏳⏳
    to_lower⏳⏳⏳

    ✅(Implemented) ⏳(Planned)

    #📜 License

    MIT Licensed. See LICENSE for details.

    contains_char

    fn contains_char(str :
    StringView
    , cp : Char) -> Bool

    Source Files