-
Notifications
You must be signed in to change notification settings - Fork 10.5k
[stdlib] Enable sendfile on GLibc #4402
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
Conversation
Could you add a simple test to |
@gribozavr is this test good enough? GlibcTestSuite.test("sendfile") {
expectEqual(type(of: sendfile), ((Int32, Int32, off_t, size_t) -> ssize_t).self)
} |
@swift-ci smoke test |
Could you change it to this? GlibcTestSuite.test("sendfile") {
// Check that `sendfile` is available. Don't actually call it, because doing that is non-trivial.
var sendfile_ = sendfile
expectEqual(((Int32, Int32, off_t, size_t) -> ssize_t).self, &sendfile_)
} |
@gribozavr done! |
Please squash this down into one commit. |
@CodaFi I merged master into this branch, so it's incorporating all the intermediate changes. Can't squash merge from GitHub be used? |
I don't have privileges to squash-merge, and it's better if you rebase and squash yourself because you can provide a more detailed message on the commit if you want. |
So that takes care of your half, but can you also squash the |
@CodaFi Sure I can do that, but then all the file changes in the merge commit are incorporated. I'll do it then you'll see. |
@CodaFi done |
|
If that fails I have just pulled your branch and have a clean patch that I can apply to master for you. |
Bellissimo! @swift-ci please smoke test macOS platform. |
@CodaFi 😒 forgot I could rebase haha. brainfart. |
@CodaFi yeah this is for Glibc. |
Your changes already passed CI on linux, and I've verified that they work on a Linux box with GlibC locally post-patch. This CI run is to pass the merge requirements. 😉 |
@CodaFi Awesome! Thanks a lot man! (: |
GlibcTestSuite.test("sendfile") { | ||
// Check that `sendfile` is available. Don't actually call it, because doing that is non-trivial. | ||
var sendfile_ = sendfile | ||
expectEqual(((Int32, Int32, off_t, size_t) -> ssize_t).self, &sendfile_) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Sorry, I was running the wrong test suite. This should be
expectEqual(((Int32, Int32, UnsafeMutablePointer<off_t>!, ssize_t) -> ssize_t).self, type(of: sendfile))
Superseded by the merge of #4446. Thank you @paulofaria! |
[pull] swiftwasm from main
What's in this pull request?
Make sendfile work on Linux Toolchains so all the web frameworks and servers can take advantage of it. Apple Platforms packages already have it (Darwin.POSIX.sys.socket.sendfile).
@glock45 😉
Before merging this pull request to apple/swift repository:
Triggering Swift CI
The swift-ci is triggered by writing a comment on this PR addressed to the GitHub user @swift-ci. Different tests will run depending on the specific comment that you use. The currently available comments are:
Smoke Testing
A smoke test on macOS does the following:
device standard libraries are not built.
version of these tests are not run.
A smoke test on Linux does the following:
tests are not run.
Validation Testing
Lint Testing
Note: Only members of the Apple organization can trigger swift-ci.