Skip to content

cgo: zero cost cgo calling #51380

Closed
Closed
@hiqsociety

Description

@hiqsociety

sorry for asking but is there a possibility for zero cost cgo calling in future?
140ns per call is too much.
rustlang has zero cost calling c / c++ now.
just wondering if that'll be the way in future.

Activity

added this to the Proposal milestone on Feb 27, 2022
changed the title [-]proposal: affected/package: cgo, zero cost cgo calling?[/-] [+]cgo: zero cost cgo calling[/+] on Feb 27, 2022
ALTree

ALTree commented on Feb 27, 2022

@ALTree
Member

If it were easy to have zero cost cgo calls, it would've been done by now. It wasn't one of Go design goals to have effortless and performant C integration, and it's not easy for a language with a runtime like Go's. Anyway, this is #9704 and #19574, closing here as a dup.

locked and limited conversation to collaborators on Feb 27, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Relationships

    None yet

      Development

      No branches or pull requests

        Participants

        @ALTree@gopherbot@hiqsociety

        Issue actions

          cgo: zero cost cgo calling · Issue #51380 · golang/go