8000 Ideas on code size optimization · Issue #3319 · micropython/micropython · GitHub
[go: up one dir, main page]

Skip to content

Ideas on code size optimization #3319

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

Closed
pfalcon opened this issue Sep 16, 2017 · 9 comments
Closed

Ideas on code size optimization #3319

pfalcon opened this issue Sep 16, 2017 · 9 comments
Labels
enhancement Feature requests, new feature implementations

Comments

@pfalcon
Copy link
Contributor
pfalcon commented Sep 16, 2017

This ticket is intended to collect ideas on how to optimize for code sizes, which aren't carried out immediately for some reason (e.g. they make a breaking change, required big start-up effort, or complicate maintenance).

@pfalcon pfalcon added the enhancement Feature requests, new feature implementations label Sep 16, 2017
@pfalcon
Copy link
Contributor Author
pfalcon commented Sep 16, 2017

Switch btree.open() to accept cache size in pages, with removal of bytes-to-pages conversion from BerkeleyDB fork: #3257 (comment) . Saves 54 bytes on Xtensa (esp8266).

@pfalcon
8000
Copy link
Contributor Author
pfalcon commented Oct 30, 2017

Remove uio.open(), nobody uses it anyway.

@pfalcon
Copy link
Contributor Author
pfalcon commented Oct 30, 2017

Remove ure.DEBUG flag from ure (and assocaited re1.5 compiled re dump code).

@pfalcon
Copy link
Contributor Author
pfalcon commented Oct 30, 2017

Remove module-level ure.match() and ure.search().

@dpgeorge
Copy link
Member

Remove module-level ure.match() and ure.search().

-1, they are very useful.

@robert-hh
Copy link
Contributor
robert-hh commented Oct 31, 2017

-1, as this is present since long and may break existing code.

Remove ure.DEBUG flag from ure (and assocaited re1.5 compiled re dump code).

ok: This should not break existing code, and it's output is anyhow hard to understand

Remove uio.open(), nobody uses it anyway.

True for me, but how do you know? Is there a trigger in it and nobody yet hit it?

@pfalcon
Copy link
Contributor Author
pfalcon commented Oct 31, 2017

-1, they are very useful.

And yet that's the way to get smaller binary code size without losing functionality. This ticket is a raw dump of ideas of different "levels", ideally, all of them implemented, definitely, all implemented in a configurable way, and values for configuration shipped in mainline are different of course.

@stinos
Copy link
Contributor
stinos commented Oct 31, 2017

Remove module-level ure.match() and ure.search().

also -1 unless they get added in micropython-lib or so: these are like the go-to functions for easy working with regexes

@dpgeorge
Copy link
Member

ure.DEBUG was made optional in 7d851a2

Otherwise, I'll close this issue because it's quite stale.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement Feature requests, new feature implementations
Projects
None yet
Development

No branches or pull requests

4 participants
0