Skip to content

1.1

Choose a tag to compare

@luk036 luk036 released this 26 Sep 03:40
· 101 commits to master since this release

Full Changelog: 1.0.9...1.1

πŸš€ Release Notes: csd-cpp v1.1

This release introduces performance improvements, new features, and bug fixes to the Canonical Signed Digit (CSD) C++ library. Below is a summary of the key changes.


πŸ“… Release Highlights

  • Performance optimization in the longest repeated substring function (lcsre)
  • Experimental CSD multiplier for Verilog code generation
  • Android/Termux support fixes
  • Extended unit test coverage and code quality improvements
  • Build system enhancements for both CMake and xmake

πŸ”§ What’s New

1. Performance Improvements

  • Optimized longest_repeated_substring function to use a rolling 2-row DP table, reducing memory usage from (O(n^2)) to (O(n)).

2. Experimental CSD Multiplier

  • Added a new experimental module (experiments/csd_multiplier.cpp) that generates Verilog code for a CSD-based multiplier with signed arithmetic support.

3. Build System Updates

  • CMake: Added policy version enforcement and disabled developer warnings for cleaner builds.
  • xmake: Added release-mode optimizations for faster execution.

4. Code Quality & Testing

  • Expanded unit tests with additional edge cases for to_decimal, to_csd, and to_csdnnz functions.
  • Improved error handling and input validation in CSD conversion functions.

5. Documentation

  • Added a Gemini Code Assistant context file (GEMINT.md) with project overview, build instructions, and development conventions.

πŸ› Bug Fixes

  • Fixed build issues for Android Termux environments.
  • Corrected function signature consistency in to_csdnnz_i.
  • Resolved warnings and improved cross-platform compatibility.

πŸ“ Files Changed

  • 11 files modified with 243 additions and 13 deletions
  • Key files:
    • source/lcsre.cpp (performance optimization)
    • include/csd/csd.hpp (API consistency)
    • test/source/test_csd.cpp (extended test cases)
    • xmake.lua (build optimizations)
    • New: experiments/csd_multiplier.cpp

πŸ›  Build Instructions

With CMake:

cmake -S all -B build -DCMAKE_BUILD_TYPE=Release
cmake --build build

With xmake:

xmake f -m release -y
xmake

βœ… Testing

Run the updated test suite to verify functionality:

cd build/test && ctest

πŸ“¦ Compatibility

  • Supports C++11 and above
  • Compatible with Linux, Windows, and Android (Termux)
  • Dependencies: fmtlib, doctest (handled via CPM.cmake)

πŸ™Œ Contributors

Thanks to luk036 for the commits and contributions to this release.


πŸ”— Learn More

  • Visit the GitHub repository: luk036/csd-cpp
  • Refer to GEMINI.md for detailed project context and conventions.