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

[libc,cmds] Add arena numbers to meminfo -m, prohibit fprintf to fputs conversions #2109

Merged
merged 3 commits into from
Nov 19, 2024

Conversation

ghaerr
Copy link
Owner

@ghaerr ghaerr commented Nov 19, 2024

While cleaning up meminfo -m blank lines and adding arena numbers instead (see screenshot) it was noticed that meminfo was ~30 bytes over 4K. Trying to save those bytes involved another couple of changes; sharing some strings, and using fd as a global, rather than being passed around to most all the internal functions. Discussed with @Mellvik in Mellvik/TLVC#105 (comment). Sorry about all the new changes to reduce size, just after you ported the previous version, with all its changes!!

It was also noticed that while the -fno-builtin-printf option had already been added, prohibiting GCC compilation conversion of printf to fputs, this did not apply to fprintf being converted to fputs! After reading everywhere for a solution to no avail, I guessed at -fno-builtin-fprintf which was accepted. Recompiling all applications resulted in saving 4K floppy space, apparently from not dragging in the extra fputs code into a number of applications.

Here's meminfo -m without blank lines:
Screen Shot 2024-11-19 at 11 28 02 AM

@ghaerr ghaerr merged commit 5f5effd into master Nov 19, 2024
1 check passed
@ghaerr ghaerr deleted the meminfo branch November 19, 2024 21:26
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.

1 participant