Skip to content

Conversation

@asn5d
Copy link
Member

@asn5d asn5d commented Dec 3, 2025

This is an optional enhancement, not the main fix for #2 / #3.

Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This pull request adds optional mimalloc allocator support for Release builds as an enhancement, along with several important bug fixes and code quality improvements across the codebase.

Key Changes:

  • Integration of mimalloc allocator as an optional external dependency for Release builds
  • Modernization of CMake build system using interface libraries for compiler flags
  • Critical bug fixes in loop boundaries and array access patterns
  • Performance improvements through const reference parameter passing

Reviewed changes

Copilot reviewed 15 out of 16 changed files in this pull request and generated 6 comments.

Show a summary per file
File Description
CMakeLists.txt Adds mimalloc ExternalProject integration, modernizes compiler flags with interface library, moves compiler detection before project()
cvutil/CMakeLists.txt Adds mimalloc linking for Release builds, updates runtime dependency handling with EXTRA_RUNTIME_DEPS support
RoiManager/CMakeLists.txt Adds mimalloc linking for Release builds, comments out legacy build output configuration
PluginManager/CMakeLists.txt Adds mimalloc linking for Release builds, comments out legacy build output configuration
CMake/find_runtime_deps.cmake Adds support for explicitly specified extra runtime dependencies via EXTRA_RUNTIME_DEPS
cvutilConfig.cmake.in Reverts from install(FILES) to file(INSTALL) for runtime dependency installation
cvutil/cvutil_matlab_interface.h Changes string parameter to const reference for find() function
cvutil/cvutil_matlab_interface.cpp Fixes off-by-one errors in loop bounds (5 instances), updates find() signature, initializes Mat val with braces
cvutil/cvutil_linesim.h Changes vector parameter to const reference for doughlas_peucker()
cvutil/cvutil_linesim.cpp Implements const reference parameter with local copy modification pattern
cvutil/cvutil_core.h Changes vector parameter to const reference for doughlas_peucker()
cvutil/cvutil_core.cpp Updates doughlas_peucker() signature, fixes matrix type references in bwthin() boundary padding
cvutil/cvutil_bwthin.cpp Adds bounds checking before array access (12 instances)
cvutil/cvutil_bwskel.cpp Corrects row offset from 2 to 3 for rectify_components(), splits long conditionals
cvutil/cvutil_bwdist.cpp Fixes off-by-one error in loop bound
.gitignore Adds [Ii]nstall/ directory to ignore list

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 5 out of 5 changed files in this pull request and generated 10 comments.


💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Copy link
Contributor

Copilot AI commented Dec 3, 2025

@asn5d I've opened a new pull request, #8, to work on those changes. Once the pull request is ready, I'll request review from you.

Copy link
Contributor

Copilot AI commented Dec 3, 2025

@asn5d I've opened a new pull request, #9, to work on those changes. Once the pull request is ready, I'll request review from you.

asn5d and others added 2 commits December 4, 2025 10:38
…re linking.

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
…efore linking.

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Copy link
Contributor

Copilot AI commented Dec 4, 2025

@asn5d I've opened a new pull request, #10, to work on those changes. Once the pull request is ready, I'll request review from you.

asn5d and others added 3 commits December 4, 2025 10:55
…r Release only.

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
…or MSVC

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Copy link
Contributor

Copilot AI commented Dec 4, 2025

@asn5d I've opened a new pull request, #11, to work on those changes. Once the pull request is ready, I'll request review from you.

Copilot AI and others added 3 commits December 4, 2025 12:27
* Initial plan

* Replace $<CONFIG> with ${CMAKE_BUILD_TYPE} in ExternalProject_Add

Co-authored-by: asn5d <16312669+asn5d@users.noreply.github.com>

* Use hardcoded Release build type for mimalloc ExternalProject

Co-authored-by: asn5d <16312669+asn5d@users.noreply.github.com>

---------

Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com>
Co-authored-by: asn5d <16312669+asn5d@users.noreply.github.com>
* Initial plan

* Remove undefined ASAN_RUNTIME_DEP from EXTRA_RUNTIME_DEPS

Co-authored-by: asn5d <16312669+asn5d@users.noreply.github.com>

---------

Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com>
Co-authored-by: asn5d <16312669+asn5d@users.noreply.github.com>
* Initial plan

* Remove undefined ASAN_RUNTIME_DEP from EXTRA_RUNTIME_DEPS expression

Co-authored-by: asn5d <16312669+asn5d@users.noreply.github.com>

* Use $<IF> syntax for EXTRA_RUNTIME_DEPS generator expression

Co-authored-by: asn5d <16312669+asn5d@users.noreply.github.com>

---------

Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com>
Co-authored-by: asn5d <16312669+asn5d@users.noreply.github.com>
@asn5d asn5d merged commit 443d04a into main Dec 4, 2025
@asn5d asn5d deleted the feature/mimalloc branch December 4, 2025 19:13
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants