topology.brep_p10 green
- Layer
- 43
- Upstream lines
- 1,890
- Functions
- 4
- Rust module
topology::brep::p10
Status history
- todo 1,890 lines
- partial 1,890 lines
- green 1,890 lines
Source: crates/solidcore/src/topology/brep/p10.rs
Upstream: source/SMLib/src/SmBrep.cpp
Port-plan notes
These notes preserve historical port measurements and limitations, not current CI results.
SUBDIVIDE (2026-10-30, 6eecf04 part 1): SmBrep::SubdivideFaceAtDiscontinuities (not reached by upstream callers; the fork's variable-round split calls it) is topology::brep::p10::subdivide_face_at_discontinuities, with SmBSplineCurve::GetNullSegments (Curve::null_segments) and SmSurface::CreateLineOnSurf (Surface::create_line_on_surf); SmBrep::ReplaceCurve is topology::brep::p2::replace_curve (moved from the offset module). Runner op subdivide, 20 fixed cases in fixtures/topology.brep_p10/subdivide_cases.json; the V pass counts the V knots, WR-589 fixed on the default path (subdivide_u1v2_cinf, subdivide_u0v1_cinf, subdivide_surf_rev_cinf and subdivide_nurb_nurb_2_cinf are known mismatches, cpp_defect WR-589: the C++ v1.0.1 reference counts the U knots, the fork 6eecf04 and solidcore the V knots; the last two, on upstream test files, failed main's sweep after #1828 until parked, WR-589 addendum 2026-11-04); faces with more U knots than V knots are rejected on the C++ side (it reads past its V knots). EXACT PROJECTION SIDE VOTES (PR #1310, 2026-10-27): ARM64 native gate observed 1416 cases, 1409 value-bearing passes, 7 guarded rejections, 0 failed/deferred/vacuous, max_rel_err=0. Twelve new production ProjectAndTrim cases exercise vertex and edge-midpoint selection, both trim modes and ordinary close-knot controls; the 8 close-knot failures before the correction now pass. One exact Curve wrapper serves all classification votes. Raw-input guards preserve SMLib degrees below 32 for classification and apply NLib degree 17 only when actual projection faces exist; empty subsets and zero-face B-reps remain eligible for classification. Existing glibc UB-255 exception remains unchanged; it did not trigger on the local ARM64 run. No new projection/imprint or tie/ray-fallback coverage is claimed. Prior history: 2026-10-26 (cpp_defect outcome): the sole known mismatch read_Solids_fillet_ts is marked cpp_defect = "UB-255" (the C++ reference is verified wrong: glibc tcache reuse of a freed SmVertexProps in SmHealData::Fix_CoinVertices), so it counts as a success and the unit is green: GREEN topology.brep_p10 cases=1404 passed=1396 failed=0 deferred=0 rejected=7 cpp_defect=1. 2026-10-26 (WR-255 opt-in, #959: the runner no longer sets the removed Context::trim_uv_curves_at_corner_drops; upstream's path is the default): PARTIAL topology.brep_p10 cases=1404 passed=1396 failed=0 deferred=0 rejected=7 known_mismatch=1 (read_Solids_fillet_ts, UB-255 glibc heap reuse, unchanged). UPDATE (brep_p10 heal/notify/seam-trim fixes, 2026-10-25): 12 of 13 known mismatches resolved: PARTIAL topology.brep_p10 cases=1404 passed=1396 failed=0 deferred=0 max_rel_err=2.58e-11 rejected=7 known_mismatch=1 (--perturb 1397/1397). Fixes: bind_uv_trim_owners after heal_brep in make_topology; remove_faces_notified in remove_faces; LiveBrepObjects in faces_to_delete; with_editing_enabled + tracked_edit + move_seam_notified in heal_data::p3; opt-in Context::trim_uv_curves_at_corner_drops in fix_uv_trim_curves for healed corner-drop UV trims; bit-exact bit_audit comparator excluding healed UV trim doubles. Sole remaining known mismatch read_Solids_fillet_ts is upstream UB-255 (dangling pSurvivorProps pointer / glibc 7-slot tcache reuse in SmHealData::Fix_CoinVertices). UPDATE (MergeCurvesOnSurface world, 2026-10-25): ProjectAndTrim merges over the B-rep itself, notified through the caller's records (new notify argument), and binds the UV trim curves its face queries and edge splits leave unowned to their edge uses. difftest 1404 cases, 1384 pass, 0 failed, 0 deferred, 7 rejected, 13 known mismatches; project_t0/t1/t2_Defeature_inset_cube and project_tols_inset_cube now pass. UPDATE (heal guard after Set patches narrowed, 2026-10-23): 1404 cases, 1166 pass, 0 failed, 231 deferred, 7 rejected (was 1156/0/231/17). The runner rejects healing after Set patches only when they change the patched data and the Rust build (healing off) accepts it; no-op Sets and data the shim's build simulation refuses (-2) are compared. Still rejected: 4 IGES (UB-237), 3 Set (UB-164 healer trigger, see findings). main CI e33985411 (2026-10-23): PARTIAL topology.brep_p10 cases=1404 passed=1154 failed=0 deferred=233 rejected=17 blocked_by=intersect.curve_class_p4(150),query.face_p2(1),topology.brep_p1(3),topology.face_p2(7),topology.face_p4(72). #76 kernel-aware Surface dispatch (PR #313, 2026-10-21): 1404 cases, 922 pass, 0 failed, 482 deferred (surface.sphere 352, topology.face_p2 101, surface.surf_of_extrusion_p2 10, topology.face_p4 9, geom.tol 5, query.brep 5), max_rel_err 0; before 851 pass / 553 deferred. partial: cases=1404 passed=839 failed=0 deferred=565 max_rel_err=0 (surface.cone_p2 424: SmCone::IsNurbSurfaceCone in CopyAndAddAnalytics; topology.face_p2 63: SmFace::GetTolerance inside HealBrep; surface.cone_p1 41 / surface.surf_of_extrusion_p2 10: the Rust read of the file stops at the Surface::read_from_db dispatch gap (the cone_p1 label is a stale stub of surface/surface/p2.rs, not this unit's); topology.brep_p2 19: IsManifoldSolid, and SmBrep::Notify reached through the face use TestClosureSplitRegion of topology.brep_p6; topology.brep_p5 8: RemoveFaces / FindAndSetInfiniteRegion); --perturb SENSITIVE 839/839. Review fixes (PR #130): a non-SmBSplineCurve UV trim copy is not stored on the edge use (SM_CAST_PTR); crafted fixtures cover wire-edge/vertex shells, vertex loops, the analytic edge-curve end check and composite/B-spline UV curves (review_cases.json, 128 cases); adv_cases.json (192 review cases: manifold flags 3/-1, IGES empty shells, shared surfaces and curves with and without borrowed geometry, zone tolerance clamp limits, healer versions, pole/vertex edge uses mid-loop, relinked and overlapping loops, closure after relinking, a dropped UV curve, remove-all with editing disabled). Second review (after main merged topology.brep_p1 #145): dropped the duplicate co-ported m_bEditingEnabled (main's Brep field), new_with_infinite_region sets region_list_head (PreInsert); wired the topology.brep_p1 back-edges (sm_AddAttributes with TopologyEnv::all_attributes = rAllAttributes, HealBrep, GetRegions, GetFaces, GetWireEdges, CreateParallelProjectionCurves, sm_FindSideOfCurve) and topology.brep_p7's two UNPORTED(topology.brep_p10) sites (ReadFromFile, GlueEdgesGeneral). ProjectAndTrim and RemoveAllTopology (editing enabled) still defer at later units. 4 fns; cycle back-edges stubbed: topology.brep_p2 (IsManifoldSolid, MergeCurvesOnSurface, GetShellVertices, sm_GetPointFromSol), topology.brep_p4 (DeleteEdge, DeleteVertex), topology.brep_p5 (RemoveFaces, FindAndSetInfiniteRegion), topology.face_p4 (GetVertices, GetEdges), query.brep (CalculateBoundingBox). Harness-level deferral labels topology.brep_p10 (inexact .smb imports) remain in the topology.vertex, topology.edgeuse_p1/p2 and topology.loopuse runners (see findings) Batch integration (batch/clean-2026-10-19): RemoveFaces and FindAndSetInfiniteRegion() wired to topology::brep::p5 (remove_faces with the B-rep editing flag; find_and_set_infinite_region with the upstream defaults, which defers inside part 5). UPDATE after topology.brep_p2 (PR #149 follow-up): IsManifoldSolid (pBrepData->m_bManifold = IsManifoldSolid()), sm_GetPointFromSol and GetShellVertices are wired to topology::brep::p2; MergeCurvesOnSurface calls topology::brep::p2::merge_curves_on_surface (SmBrep.cpp:25074, header defaults) through an uninhabited MergeCurvesObjects world over the B-rep cache whose constructor is the UNPORTED(query.brep) stub: query.brep (todo) is the real blocker, as for topology.shell's shell_ray_sector (overseer ruling); test_closure_split_region takes the caller's NotifyEnv. 1404 cases, 851 pass, 0 fail, 553 deferred: 12 IsManifoldSolid deferrals now pass (201-16358 values each), 2 defer on topology.face_p2 SmFace::GetTolerance. Unit test healing_runs_and_manifold_is_computed (renamed) checks the UNSURE flag is computed (0 for a sheet). Re-run in PR #149 (review 5578349117 round, merged with main through fb58ea76; topology.brep_p2's UNPORTED stubs wired): 1404 cases, 851 pass, 0 fail, 553 deferred; 12 former topology.brep_p2 deferrals (SmBrep::IsManifoldSolid, Notify) pass (201-897 values), 2 defer on topology.face_p2 SmFace::GetTolerance, 5 Notify deferrals relabel to query.brep. UPDATE (PR #679, UpdateVertexEdgeIntervals wired in CombineCoincidentVertices): 1404 cases, 1154 pass, 0 failed, 233 deferred (unchanged); the 3 UpdateVertexEdgeIntervals deferrals (read_Fillet_open_shell, read_Solids_fillet_ts, gen0115) now defer at intersect.curve_class_p4 GetLoopCrossings. UPDATE PR #613: the difftest graph now exports the owning region-list order after ResetInfiniteRegion. The edge closure path binds lazily generated UV trim owners under the construction callback names, retaining existing owners and the native status. All 90 spine_doubled fixtures pass bit-identical locally, including both previously deferred cases that failed in CI run 39983042271; no tolerance, comparator or fixture change. Full p10 rerun remains incomplete; shared Graph::walk consumer topology.brep_p6: 595 cases, 588 pass, 0 fail, 7 deferred. UPDATE (owning-face caches for CreateParallelProjectionCurves): the 5 ProjectAndTrim cases that deferred at the surface's face now run; 4 stop at topology.brep_p2 (MergeCurvesOnSurface classification world) and project_t0_Defeature_brep1 is a known mismatch (the surviving region after every face is removed; plan/findings.md). PARTIAL topology.brep_p10 cases=1404 passed=1166 failed=0 deferred=230 known_mismatch=1.
Goldens
This is committed inventory, not a runtime result or a correctness proof. A golden records what solidcore produced when blessed. Current results require the canonical CI gate, not these counts.
- Golden records
- 1,436
- Stored error outcomes
- 0
- Stored deferrals
- 0
- Stored harness rejections
- 0
- Known-failure entries
- 0
Metadata counts describe fields in the stored records; they are not passes or live failures.
Source at f9704ee3b:
golden JSONL ·
known-failure list.
Dependencies
Depends on: curve.curve_p2 green geom.a_object green geom.extent1d green geom.extent3d green geom.object green geom.solution_array green geom.tol green geom.vector3d green surface.surface_p2 partial topology.edge green topology.edgeuse_p1 green topology.proto_topology_p1 green topology.shell green topology.topology green topology.vertex green
Soft dependencies: geom.context green geom.extent2d green geom.geom_utility_p1 green intersect.topology_solver_p2 green nurbs.b_spline_curve_p1 green surface.surface_p1 green topology.brep_data green topology.edgeuse_p2 green topology.face_p2 partial topology.face_p4 green topology.loopuse green topology.vertexuse green
Dependents: primitive.api_trim_ops partial topology.brep_cutting partial topology.brep_p7 green
Soft dependents: primitive.primitive_creation_p2 green sweep.topology_sweep green
Upstream functions
| Upstream function | Defined at | Lines | Rust (from the file header) |
|---|---|---|---|
SmBrep::MakeTopologyFromData | SmBrep.cpp:19557 | 1377 | [make_topology_from_data] |
SmBrep::ProjectAndTrim | SmBrep.cpp:25278 | 294 | [project_and_trim] |
SmBrep::RemoveAllTopology | SmBrep.cpp:26513 | 42 | [remove_all_topology] |
SmBrep::TestClosureSplitRegion | SmBrep.cpp:27927 | 177 | [test_closure_split_region] |
Module file-header table (10 rows)
| Rust | Upstream |
|---|---|
[make_topology_from_data] | SmBrep::MakeTopologyFromData |
[MakeTopologyOptions] | its bMakeUVTrimCurves .. bHealerIsEnabled arguments |
[TopologyEnv] | rAllAttributes, the objects' addresses |
[project_and_trim] | SmBrep::ProjectAndTrim |
[TrimType] | SmTrimType |
[remove_all_topology] | SmBrep::RemoveAllTopology |
[remove_all_topology_notified] | SmBrep::RemoveAllTopology (caller's records) |
[test_closure_split_region] | SmBrep::TestClosureSplitRegion(SmBoolean, SmEdge*, ...) |
[HEALER_VERSION] | SM_HEALER_VERSION |
[subdivide_face_at_discontinuities] | SmBrep::SubdivideFaceAtDiscontinuities |
Upstream tests reaching this unit
prog_test:my_test_single_periodic_vertexuse, SM_API_test:TestSmAdvancedStitch, SM_API_test:TestSmEdgeCurveOwnership, SM_API_test:TestSmGetClosestPoint, SM_API_test:TestSmGetEdges, SM_API_test:TestSmGetFaces