Skip to content

Katherine: Implement sleep, timeouts, and concept of timescale#3

Open
UnknownEclipse wants to merge 8 commits intomainfrom
time
Open

Katherine: Implement sleep, timeouts, and concept of timescale#3
UnknownEclipse wants to merge 8 commits intomainfrom
time

Conversation

@UnknownEclipse
Copy link
Collaborator

No description provided.

Copy link
Collaborator Author

@UnknownEclipse UnknownEclipse left a comment

Choose a reason for hiding this comment

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

Looks great! Have a few comments (and need review from the others) but looks good!

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

We may need to do some conflict resolution on the CMake when merging these PR's. It seems like you're adding gtest and the tests executable right? Anything else that should be handled?

Copy link
Collaborator

Choose a reason for hiding this comment

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

Yeah gtest is the only one but it was mostly so I could test my code, I could remove it if it's causing issues

void sleep(std::chrono::milliseconds sim_ms);

// Get the current time in simulation time
std::chrono::time_point<std::chrono::system_clock> clock_gettime();
Copy link
Collaborator Author

Choose a reason for hiding this comment

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

clock_gettime can work with multiple clock id's. We should log the ones that get used by the simulation target rather than using the same for everything in the future (no changes right now though)

Copy link
Collaborator

Choose a reason for hiding this comment

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

Ok let me know when/whether I should make changes for this

Copy link
Collaborator

@MatthewMattei MatthewMattei left a comment

Choose a reason for hiding this comment

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

I second Ben's comments; my only addition is that it would be nice to add a one-line comment or so for each test explaining what they're intended to cover so that it's easy to understand test coverage at a glance

Copy link
Collaborator

@CutieOwl CutieOwl left a comment

Choose a reason for hiding this comment

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

Thanks for the comments guys! Let me know if there's anything else I need to do before the end of the class :)

void sleep(std::chrono::milliseconds sim_ms);

// Get the current time in simulation time
std::chrono::time_point<std::chrono::system_clock> clock_gettime();
Copy link
Collaborator

Choose a reason for hiding this comment

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

Ok let me know when/whether I should make changes for this

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