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

proposal: Go 2: Better C FFI performance! (Discussion) #39115

Closed
phtdacosta opened this issue May 17, 2020 · 1 comment
Closed

proposal: Go 2: Better C FFI performance! (Discussion) #39115

phtdacosta opened this issue May 17, 2020 · 1 comment
Labels
Milestone

Comments

@phtdacosta
Copy link

@phtdacosta phtdacosta commented May 17, 2020

I just started learning Go as my job requires to, but as a quite seasoned C programmer, I've checked lots of articles pointing out Go's C FFI poorer performance when compared with Rust's C FFI for example.

Maybe it is due the fact that Go has GC? Would disabling Go's GC help this inter-operation with C?

I am afraid I did not find any proposal related to that, so I would like to leave this point here, and at least, I can learn myself something I forgot to mention in my observation. Thank y'all, in overall, Go is awesome.

@gopherbot gopherbot added this to the Proposal milestone May 17, 2020
@gopherbot gopherbot added the Proposal label May 17, 2020
@martisch
Copy link
Contributor

@martisch martisch commented May 17, 2020

I dont think anybody is opposed to having better C calling performance. For a proposal however this need to explain concretely how this would be achieved. Disabling Go GC is not an option as this would run programs out of memory.

To discuss ideas please use the forums: https://golang.org/wiki/Questions
Once there is a more concrete proposal how to improve performance feel free to open a new issue. The proposal as currently stated has no actionable content.

A proposal not only need to state a problem but also suggest a workable solution.
Consider writing an experience report: https://github.com/golang/go/wiki/ExperienceReports to
point out areas that need improvement drawn from experience working with Go.

There are some existing issues about Cgo call performance:
#19574
#28454

@martisch martisch closed this May 17, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Linked pull requests

Successfully merging a pull request may close this issue.

None yet
3 participants
You can’t perform that action at this time.