Skip to content

dedupe concore/concoredocker C++ headers and fix Java docker path + simtime bugs#458

Merged
pradeeban merged 1 commit intoControlCore-Project:devfrom
avinxshKD:fix/dedupe-cpp-java-456-457
Feb 23, 2026
Merged

dedupe concore/concoredocker C++ headers and fix Java docker path + simtime bugs#458
pradeeban merged 1 commit intoControlCore-Project:devfrom
avinxshKD:fix/dedupe-cpp-java-456-457

Conversation

@avinxshKD
Copy link

follow-up to #442, same idea but for C++ and Java.

concoredocker.hpp and concore.hpp both had #ifndef CONCORE_HPP, including both in a project silently drops the docker class. also mapParser() had no bounds check on its inner loop, bad iport file = UB. pulled shared utils into concore_base.hpp to stop the drift.

java side: inpath + port + "/" gives /in1/name not /in/1/name so every read/write was silently going to the wrong path. also simtime += delta in write() was supposed to be gone per #385, python and C++ already had that, java didn't.

96 tests pass
image

closes #456 closes #457

@avinxshKD
Copy link
Author

hey @pradeeban @Rahuljagwani... follow-up to #442, same drift problem but in C++ and Java (avoided touching the Verilog as you asked)

was looking at the Java path bug and noticed the hpp guard collision while at it, so fixed both in one pass. concore_base.hpp is the new shared file, mirrors what concore_base.py does. java changes are the more critical ones, wrong path bug silently breaks all file I/O in Java docker nodes with no error, just falls back to defaults.

happy to add tests for the C++ side if useful,

@avinxshKD
Copy link
Author

avinxshKD commented Feb 23, 2026

@pradeeban really wanted to know is this the right direction for the C++ side, or would you prefer keeping the implementations fully separate?

kept this minimal as i could.

@avinxshKD
Copy link
Author

@pradeeban @Rahuljagwani Also imp....been in mkconcore a bit and hard to test in current shape, everything’s top-level and there are direct exits in flow. if useful, I can take a refactor pass to split it into testable functions and add a focused test suite. happy to take it if so

if this is a right direction lmk

@pradeeban
Copy link
Member

@avinxshKD Thanks. Avoid working too much on the mkconcore, concore python classes as they are likely to give additional bugs that maybe too much for the application period. Other than that, ok to proceed on Java (which like I said, is mostly a toy) and C++ versions. Best not to bother with the Verilog version.

@pradeeban pradeeban merged commit 5d46e60 into ControlCore-Project:dev Feb 23, 2026
6 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.

2 participants