Skip to content

Ability to act as a server using a socket communication link, handle critical path list requests, and highlight certain critical path requests #2483

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

Closed
wants to merge 257 commits into from

Conversation

w0lek
Copy link
Contributor

@w0lek w0lek commented Feb 1, 2024

vpr_it1_pullrequest.pdf

Description

Related Issue

Motivation and Context

How Has This Been Tested?

Types of changes

  • Bug fix (change which fixes an issue)
  • New feature (change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to change)

Checklist:

  • My change requires a change to the documentation
  • I have updated the documentation accordingly
  • I have added tests to cover my changes
  • All new and existing tests passed

Yitian4Debug and others added 30 commits August 2, 2022 18:05
w0lek added 19 commits December 5, 2023 13:31
… Analysis tool. ServerContext now is a pointer and instantiated only when --server mode is activated. cleanup
…hich are applicable for iteration 1(basic implementation)
@vaughnbetz
Copy link
Contributor

Thanks for developing what looks like a great new feature.

  1. Please remove the OpenFPGA tilable rr-graph files from the PR; we should focus on the GUI here.
  2. Add end user documentation (document the command line option, and this feature in the graphics section (probably a new tab).
  3. We should have Doxygen comments on the server etc. code (which I think you already have) and add the resulting hyperlinked documentation to read the docs, probably under VPR API. There is guidance on how to do that in the VTR Developer Guide (it's a short amount of code to write once you have the Doxygen comments, and the Guide tells you where to write it).

Copy link
Contributor

@soheilshahrouz soheilshahrouz 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 this interesting PR. I suggested a few changes to improve readablity.

Some methods write to standard output and error. It would nice to add a verbosity parameter to control how much detail is printed. I am also not sure accessing std::cout and std::cerr from the network thread is thread-safe.

Since this PR includes some chagnes from OpenFPGA project, I might have missed some files.

if (iss >> intValue) {
// Check if there are no any characters left in the stream
char remaining;
if (!(iss >> remaining)) {
Copy link
Contributor

Choose a reason for hiding this comment

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

Doesn't eof() method provide the same functionality?

#include <optional>
#include <string>

std::optional<int> tryConvertToInt(const std::string&);
Copy link
Contributor

Choose a reason for hiding this comment

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

vtr_util.cpp has an atoi() funtion implementing the same conversion.

for (auto& t : m_tasks) {
if (t.cmd() == task.cmd()) {
if (t.options() == task.options()) {
std::string msg = "similar task is already in execution, reject new task: " + t.info() + " and waiting for old task: " + task.info() + " execution";
Copy link
Contributor

Choose a reason for hiding this comment

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

Is "task' the old task and "t' the new one?


void TaskResolver::takeFinished(std::vector<Task>& result) {
for (auto it = m_tasks.begin(); it != m_tasks.end();) {
Task task = *it;
Copy link
Contributor

Choose a reason for hiding this comment

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

All tasks are copied, even if they are not finished.

} else {
++it;
}
}
Copy link
Contributor

Choose a reason for hiding this comment

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

I guess you could use std::partition

public:
TelegramBuffer(std::size_t sizeHint = DEFAULT_SIZE_HINT)
: m_rawBuffer(sizeHint) {}
~TelegramBuffer() = default;
Copy link
Contributor

Choose a reason for hiding this comment

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

Please add the default constructor as well.

m_rawBuffer.append(bytes);
}

std::vector<ByteArray> TelegramBuffer::takeFrames() {
Copy link
Contributor

Choose a reason for hiding this comment

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

Please add a comment explaining the logic

Copy link
Contributor

Choose a reason for hiding this comment

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

Some lines are too long. Please break them into multiple lines

Copy link
Contributor

Choose a reason for hiding this comment

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

Cover cases where extraction fails

Copy link
Contributor

Choose a reason for hiding this comment

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

Add cases where getting values fail

ravikiranchollangi added a commit to os-fpga/Raptor that referenced this pull request Mar 28, 2024
We want to build this only at foedag and foedag_rs for code.
This feature is not available on Raptor so better to leave it disabled until VPR has the relevant updates.
verilog-to-routing/vtr-verilog-to-routing#2483
alaindargelas pushed a commit to os-fpga/Raptor that referenced this pull request Mar 28, 2024
We want to build this only at foedag and foedag_rs for code.
This feature is not available on Raptor so better to leave it disabled until VPR has the relevant updates.
verilog-to-routing/vtr-verilog-to-routing#2483
@soheilshahrouz
Copy link
Contributor

Superseded by #2526.

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.

10 participants