Skip to content

Increase the control message size#19516

Merged
yashykt merged 7 commits intogrpc:masterfrom
yashykt:inqcmsgsize
Jul 1, 2019
Merged

Increase the control message size#19516
yashykt merged 7 commits intogrpc:masterfrom
yashykt:inqcmsgsize

Conversation

@yashykt
Copy link
Copy Markdown
Member

@yashykt yashykt commented Jul 1, 2019

No description provided.

@yashykt yashykt added the release notes: no Indicates if PR should not be in release notes label Jul 1, 2019
@yashykt yashykt force-pushed the inqcmsgsize branch 2 times, most recently from 4bddc55 to 8db4b2e Compare July 1, 2019 17:30
@yashykt yashykt requested a review from soheilhy July 1, 2019 17:30
Copy link
Copy Markdown
Contributor

@soheilhy soheilhy left a comment

Choose a reason for hiding this comment

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

Thank you for doing this. I have a few small nits.

struct iovec iov[MAX_READ_IOVEC];
char cmsgbuf[24 /*CMSG_SPACE(sizeof(int))*/];
char cmsgbuf
[128 /*CMSG_SPACE(sizeof(grpc_core::scm_timestamping)) + CMSG_SPACE(sizeof(int))*/
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

The sum in front of it should end up being 88 right? Should we use 88 instead?

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

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

let me try it out

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

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

done

char cmsgbuf
[128 /*CMSG_SPACE(sizeof(grpc_core::scm_timestamping)) + CMSG_SPACE(sizeof(int))*/
];
ssize_t read_bytes;
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

can you please pull read_bytes, total_read_bytes, and iov_len before cmsgbuf so that we don't have to skip a few cache lines on the stack to reach them?

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

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

done

];
ssize_t read_bytes;
size_t total_read_bytes = 0;

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

github doesn't let me add comments below. Would you be able to add a break right after line 528 so that we don't waste cycles on receive timestamps at least for now?

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

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

done

Copy link
Copy Markdown
Contributor

@soheilhy soheilhy left a comment

Choose a reason for hiding this comment

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

Thanks! one tiny nit :-)

struct msghdr msg;
struct iovec iov[MAX_READ_IOVEC];
char cmsgbuf[24 /*CMSG_SPACE(sizeof(int))*/];
constexpr size_t cmsg_alloc_space =
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

nit: maybe also move this down below?

@yashykt
Copy link
Copy Markdown
Member Author

yashykt commented Jul 1, 2019

Issues : #19469, #19422, #19523, #18608

@yashykt yashykt merged commit 842a3dc into grpc:master Jul 1, 2019
@lock lock bot locked as resolved and limited conversation to collaborators Sep 29, 2019
@yashykt yashykt deleted the inqcmsgsize branch May 18, 2023 20:31
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

release notes: no Indicates if PR should not be in release notes

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants