Skip to content
This repository has been archived by the owner on Oct 1, 2024. It is now read-only.

Generator: ByRef generator now passes the value by ref #149

Merged
merged 1 commit into from
Jul 21, 2016

Conversation

Therzok
Copy link
Contributor

@Therzok Therzok commented Jul 21, 2016

This avoid an extra heap allocation for each object passed by ref so it can be transitioned directly into native memory. Native counterparts will handle data mutation, so managed will see it anyway.

https://gist.github.com/Therzok/f0627b87a5f89c1e3e5b2aab58b59b08

Don't merge yet, as I need to test it.

This avoid an extra heap allocation for each object passed by ref so it can be transitioned directly into native memory. Native counterparts will handle data mutation, so managed will see it anyway.
@Therzok
Copy link
Contributor Author

Therzok commented Jul 21, 2016

Merging as it works for MD just fine.

@Therzok Therzok merged commit 89e266f into gtk-sharp-2-12-branch Jul 21, 2016
@Therzok Therzok deleted the by-ref-optimize branch July 21, 2016 11:44
@Therzok
Copy link
Contributor Author

Therzok commented Jul 21, 2016

@knocte something worthy of backporting to master?

@knocte
Copy link
Contributor

knocte commented Jul 21, 2016

Well, in general, I think that's the wrong question to ask. Master should have all the nice things, and only certain things should be backported (so you should have said "forward-porting" not "backporting", here ;) ). That being said, I would really would like to have a 3.0 release from master before landing these things (as that has been stable for long), however I also would prefer to have that 2.12 release before the 3.0 one...

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants