-
Notifications
You must be signed in to change notification settings - Fork 28
Open
Labels
Description
The ideas from #8 and #9 can also help to reduce binary size.
Ideas:
- Use
-ffunction-sections -fdata-sections
in CFLAGS, and-Wl,--gc-sections
in LDFLAGS to allow stronger dead code elimination across language boundaries- Proposal: Improve dead code ilimination when using CGO golang/go#38135
This causes each function to have segment alignment. If a large proportion of the Miqt C ABI functions are used, all the extra padding in the binary could create a net negative effect.Only section alignment, not segment alignment.
- Attempt to build with gccgo
- Some reports online that this can produce a significant size reduction (although with adding external dynamic dependencies)
- Refactor marshaling code to call helper functions instead of inlining it in every function wrapper
- Ability to disable unwanted Qt classes at compile time?
- Maybe with a build tag
- Similar idea to
qtminimal
- Ability to disable subclassing support for unneeded classes?
- The comment in Support subclassing #42 (comment) shows that subclassing support did increase the binary size noticably
foresto and greeneg