Skip to content
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

ContikiMoteType: speed up variable parsing on Linux #1343

Merged
merged 2 commits into from
Oct 4, 2023

Conversation

pjonsson
Copy link
Contributor

@pjonsson pjonsson commented Oct 3, 2023

No description provided.

Remove the interface and just parse the two
variants differently.
The Scanner is slow and allocates a lot of memory,
so only scan the lines that we are interested in.
@nfi nfi merged commit 7f8327e into contiki-ng:master Oct 4, 2023
2 checks passed
@pjonsson pjonsson deleted the contikimote-simpliify-2 branch October 4, 2023 18:04
@kkrentz
Copy link
Contributor

kkrentz commented Oct 5, 2023

I had just rebased and have gotten this error:
Screenshot from 2023-10-05 18-13-22

When I revert #1344 d68d973 , the problem disappears again.

@pjonsson
Copy link
Contributor Author

pjonsson commented Oct 6, 2023

@kkrentz what version of readelf is used? Can you paste the output from readelf -W --symbols build/cooja/mtype<numbers>.cooja for the example that gives the exception shown?

@kkrentz
Copy link
Contributor

kkrentz commented Oct 6, 2023

GNU readelf (GNU Binutils for Ubuntu) 2.39

readelf.txt

@pjonsson
Copy link
Contributor Author

pjonsson commented Oct 6, 2023

Does it work if you change line 286 in ContikiMoteType.java from if (s.contains("OBJECT")) { to if (s.contains("OBJECT") && !s.contains("UND")) {?

@kkrentz
Copy link
Contributor

kkrentz commented Oct 6, 2023

Yes, the error disappears. Thanks.

pjonsson added a commit to pjonsson/cooja that referenced this pull request Oct 6, 2023
kkrentz pushed a commit to kkrentz/cooja that referenced this pull request Oct 20, 2023
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.

3 participants