Skip to content

update ulab to 6.3.2 #8126

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

Merged
merged 11 commits into from
Jul 26, 2023
Merged

update ulab to 6.3.2 #8126

merged 11 commits into from
Jul 26, 2023

Conversation

jepler
Copy link

@jepler jepler commented Jun 27, 2023

No description provided.

@jepler jepler requested a review from dhalbert June 27, 2023 15:06
dhalbert
dhalbert previously approved these changes Jun 27, 2023
.. because the first test is actually accepted on python 3.10 and newer.
@jepler
Copy link
Author

jepler commented Jun 27, 2023

OK, the test failure is wild

Any change can add or remove qstrs, which also changes the numbering of qstrs. Strings used as identifiers also get added as qstrs.

The line \.\+63 is intended to check that the bytecode of the function ends with a 63 instruction, AKA RETURN_VALUE. However, with this exact set of qstrs the identifier g gets the qstr number 0x0463 which appears in the instruction bytecode as 04 63, which gets matched by the regular expression.

That causes the remainder of the parsing to all be off by one line, and the test is treated as failed.

jepler added 2 commits June 27, 2023 11:16
skip all the byecode hex data, it's adequately checked
by the disassembly just below

This was tripped up because in exactly the right conditions some qstr
could be of the form 'xx 63' and make the expression `\.\+63` match
something other than what was intended.

This test was re-worked upstream for mpy version 6 so it'll be a conflict
to resolve when we get to that. :-/
@jepler
Copy link
Author

jepler commented Jun 27, 2023

It looks like the updated version over-fills a number of boards' flash space :-/

@jepler jepler force-pushed the update-ulab-6.3.2 branch from b90d7b8 to 164fcb2 Compare July 10, 2023 18:53
jepler added 5 commits July 25, 2023 09:35
* floppyio: disable on itsybitsy m4, metro m4 express & airlift, pybadge, pygamer, wio terminal
* gifio: disable on itsybitsy m4 express
* framebufferio: disable on treills m4 express, wio terminal
* terminalio: disable on metro m4 express/airlift for ja/ko/ru
@jepler jepler requested a review from dhalbert July 25, 2023 20:05
@jepler
Copy link
Author

jepler commented Jul 25, 2023

I had to slim down a number of builds for this to fit. Are we entering the era of this for samd51 ? 😓

@dhalbert
Copy link
Collaborator

I had to slim down a number of builds for this to fit. Are we entering the era of this for samd51 ? 😓

We could also consider turning off little-used features in ulab. I think we already made the SAMx5x builds -Os, but you could check that.

@dhalbert
Copy link
Collaborator

think we already made the SAMx5x builds -Os, but you could check that.

Yes, they are already -Os.

Copy link
Collaborator

@dhalbert dhalbert left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for seeing this through.

@dhalbert dhalbert merged commit 5cc42d5 into adafruit:main Jul 26, 2023
@tannewt
Copy link
Member

tannewt commented Jul 26, 2023

I had to slim down a number of builds for this to fit. Are we entering the era of this for samd51 ? 😓

I think we need a plan for ulab since it keeps growing. Maybe we need to freeze versions for smaller MCUs. We basically do this by omitting newer python modules.

@gamblor21
Copy link
Member

I had to slim down a number of builds for this to fit. Are we entering the era of this for samd51 ? 😓

I think we need a plan for ulab since it keeps growing. Maybe we need to freeze versions for smaller MCUs. We basically do this by omitting newer python modules.

After looking at ulab for the synth filter stuff, if parts of the ulab python need to be omitted having someplace where people can find the omitted parts of the library would be helpful. I never realized that a lot of ulab is written in python and if split could be added if the author requires it.

@dhalbert
Copy link
Collaborator

I never realized that a lot of ulab is written in python

What parts are you seeing in Python? Everything in https://github.com/v923z/micropython-ulab is C except for tests.

@gamblor21
Copy link
Member

I never realized that a lot of ulab is written in python

What parts are you seeing in Python? Everything in https://github.com/v923z/micropython-ulab is C except for tests.

Ah sorry! I got confused with the CPython implementation.

@tannewt
Copy link
Member

tannewt commented Aug 1, 2023

FYI This PR needed to update .gitmodules to point to @jepler's ulab repo because of the fix commit: jepler/circuitpython-ulab@3728d22

@jepler
Copy link
Author

jepler commented Aug 1, 2023

jepler/circuitpython-ulab@3728d22 was merged to their main branch so it should be OK?

@tannewt
Copy link
Member

tannewt commented Aug 2, 2023

I wonder if something changed with GitHub. make fetch-all-submodules isn't working for me if I use the repo it was merged into.

Here is my esp32-camera failure even though I merged your PR yesterday:

fatal: transport 'file' not allowed
fatal: Fetched in submodule path 'ports/espressif/esp32-camera', but it did not contain 2cd2a6d69faaba9ebb6105814a50039d82e2f899. Direct fetching of that commit failed.

@dhalbert
Copy link
Collaborator

dhalbert commented Aug 2, 2023

Did you try make remove-all-submodules and then make fetch-all-submodules? Did .gitmodules change?

@tannewt
Copy link
Member

tannewt commented Aug 2, 2023

I didn't do remove. I manually removed the troubled one.

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

Successfully merging this pull request may close these issues.

4 participants