Skip to content

refactor(geometry): embed C++ METIS implementation - #492

Merged
KemengHuang merged 3 commits into
mainfrom
refactor-main
Sep 3, 2026
Merged

refactor(geometry): embed C++ METIS implementation#492
KemengHuang merged 3 commits into
mainfrom
refactor-main

Conversation

@KemengHuang

Copy link
Copy Markdown
Member

Summary

  • build the private C++ METIS/GKlib subset as uipc_metis in both CMake and XMake
  • remove the legacy external/METIS and external/GKlib source trees and targets
  • replace the unused LGPL/BSD compatibility pieces with license-clean C++/runtime facilities while preserving legacy equal-key ordering
  • harden mesh_partition against zero size, 32-bit capacity overflow, invalid IDs, and retry underflow
  • preserve METIS/GKlib Apache-2.0 attribution and document the architecture decision

Validation

  • clean CMake configure and independent CMake/XMake uipc_metis builds
  • CMake and XMake geometry suites: 38 cases / 270 assertions each
  • repository script tests: 49/49; CTest fast: 3/3
  • full Doxygen/MkDoxy/MkDocs build
  • Linux ASan + UBSan on the 13,328-part fluffy_ball case
  • old C vs new C++ byte-for-byte and per-vertex parity on Windows/MSVC and Linux/GCC:
    • fluffy_ball.msh: maximum sizes 256, 16, 8, and 4
    • animal_well.msh: maximum sizes 8 and 4
    • zero differing vertex partition IDs in every comparison
  • all ten retained sort wrappers: 1,440 adversarial/boundary calls, identical 11,374,128-byte output on MSVC and GCC

@KemengHuang
KemengHuang merged commit 4d1f3f3 into main Sep 3, 2026
6 of 18 checks passed
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.

1 participant