Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

POLite software simulation #110

Merged
merged 8 commits into from
Jun 8, 2021
Merged

POLite software simulation #110

merged 8 commits into from
Jun 8, 2021

Conversation

m8pple
Copy link
Contributor

@m8pple m8pple commented May 29, 2021

This is an attempt to pick just the software simulator out of my previous mess.

I've modified it a bit to try to make it as isolated as possible:

  • I moved it into a subdir of apps/POLite/util, so that it is clear it is not an application.
  • All the simulation logic is in a namespace POLiteSWSim, which resides in PGraph.h.
  • The "fake" POLite.h just pulls a small number of types into the global namespace.
  • polite.mk is modified to add sim and sim-release targets (I think I did slightly more than that, but the diff
    is not too bad I hope).

Apart from that, I also tried to make testing a bit clearer:

Unfortunately the actual simulation code in PGraph is still a giant blob, but I hope it is clear that it is additive
and shouldn't affect other parts of the repo, and at least there is testing there to show that it works.

I'd like to add more general testing in a separate pull, but kept it out of this one to minimise
the size of the patch.

@mn416
Copy link
Collaborator

mn416 commented Jun 1, 2021

Thanks @m8pple, I've made some tweaks to the docs. I'm on holiday this week, so will aim to merge early next week after I've had chance to try it!


$(BUILD)/sim: $(RUN_CPP) $(RUN_H) $(HL)/sim/hostlink.a
g++ -O2 -I $(INC) -I $(HL) -o $(BUILD)/sim $(RUN_CPP) $(HL)/sim/hostlink.a \
-lmetis
Copy link
Collaborator

Choose a reason for hiding this comment

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

HI @m8pple, this target was/is useful for running POLite apps on top of the hardware (Bluesim) simulator. Would be nice if this still works. I don't mind this target is renamed (as it clashes with the new sim target for software simulation), but we probably don't want to remove it.

@mn416
Copy link
Collaborator

mn416 commented Jun 6, 2021

@m8pple Very nice, it works for me, but please see the above comment about the hardware simulation target in the POLite Makefile before we can merge.

@mn416
Copy link
Collaborator

mn416 commented Jun 6, 2021

@m8pple, I've added back the POLite target for hardware simulation, renamed from sim to hwsim to avoid the clash. Will merge soon, unless you have any final comments.

@mn416 mn416 merged commit 297bbb9 into master Jun 8, 2021
@m8pple
Copy link
Contributor Author

m8pple commented Jun 9, 2021

Thanks.

I think I just deleted the sim target as a side-effect without thinking about it.

coralmw pushed a commit that referenced this pull request Apr 26, 2022
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.

3 participants