-
Notifications
You must be signed in to change notification settings - Fork 29
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: Activate mmap
for malloc
#46
base: vita
Are you sure you want to change the base?
Conversation
Thanks to @frangarcj for testing it.
MrNetrix changes and user-defined heap size
Implement _gettimeofday_r
Allows building the manuals using recent versions of TexInfo.
* Added INADDR_LOOPBACK and INADDR_NONE defines. * Fix sockaddr_in tabulation.
Add sys/errno.h
* Add `vita/lcltime_r.c` to provide localtime_r using SceRtc functions * Use hardtabs instead of spaces in `sys/vita/lcltime_r.c` * Use `rid` as `errno` in `lcltime_r.c`
copy from `newlib/libc/sys/phoenix/net/*`
vita newlib has sa_len and doesn't have arpa/inet.h
copy from `newlib/libc/sys/phoenix/net/*`
Add more network functions
Add more socket defines
@Rinnegatamante I checked the vita-quake case. imo main problem is vitaGL code set.
I don't agree that this hack approach is safe, but it's out of subject. main problem is this action is only designed every memchunk allow from gpu, but some new chunk (made by mmap) wouldn't allow it until calling actually this hack is brilliant and it could make the easy code. but sadly i don't know good solution to support it. also imo, only tl;dr
|
vitaQuake case? every single vitaGL made will be compliant with it. Btw do whatever u want. I'm not going to update newlib regardless and i'm not in Henkaku discord server so i won't have to deal with people coming cause vita2d apparently stopped allocating textures for no reasons. Maybe reading my comment was too much of a request to understand where the problem resides in allocating shittons of memblocks for no reason. |
yeah. i know event vitagl application will get the same problem after merge it. and i was misunderstanding your comment, i thought comment is vita2d will break after merge. my opinions
|
You can revert vitaGL to when it used to alloc a single memblock everytime a texture is allocated (the way vita2d works) and experience some juicy crash with whatever homebrew in existence using vitaGL due to running out of memblocks (which is what allocating memblocks randomly with malloc would cause.
|
ah sorry. @frangarcj suggested to me two application for testing. one of them is vita-quake. (another one is retroarch) if we wanted testing this pr, we have to remove overriding |
I can give you a simple test case of the faultiness of this thing. Take the code you put at the first comment of this PR. Outside of the while try to alloc a memblock of USER_RW. |
5aff4aa
to
190169b
Compare
this patch needs user level testing.
at least we got the more than 90MB heap after the patch without overriding
_newlib_heap_size_user
variables.I got 96MBs heap with this test code.
pr requires #44