forums.ps2dev.org Forum Index forums.ps2dev.org
Homebrew PS2, PSP & PS3 Development Discussions
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

How to load ~PSP modules?

 
Post new topic   Reply to topic    forums.ps2dev.org Forum Index -> PSP Development
View previous topic :: View next topic  
Author Message
Coldbird



Joined: 08 Feb 2007
Posts: 155

PostPosted: Fri Apr 10, 2009 5:43 am    Post subject: How to load ~PSP modules? Reply with quote

I need to load the compressed modules to save RAM.
Someone got a idea how I can do this? Every method I tried only loads the decrypted unpacked modules.
_________________
Been gone for some time. Now I'm back. Someone mind getting me up-2-date?
Back to top
View user's profile Send private message MSN Messenger
J.F.



Joined: 22 Feb 2004
Posts: 2906

PostPosted: Fri Apr 10, 2009 1:10 pm    Post subject: Reply with quote

Err - how is loading compressed/encrypted modules going to save ram? To be usable, a module must be uncompressed/decrypted. The only thing a compressed module saves is space on the memstick/flash partition.
Back to top
View user's profile Send private message AIM Address
Torch



Joined: 28 May 2008
Posts: 842

PostPosted: Fri Apr 10, 2009 1:17 pm    Post subject: Reply with quote

Unless you decompress the currently required parts manually and relocate the addresses manually. Even then it wouldn't be registered with module manager. It would just be code in memory that you need to manually jump into.
Back to top
View user's profile Send private message
Coldbird



Joined: 08 Feb 2007
Posts: 155

PostPosted: Sat Apr 11, 2009 12:10 am    Post subject: Reply with quote

I see. Well that's a bit of a problem... I suppose i will have to manually cut out unneeded functions of the module.
_________________
Been gone for some time. Now I'm back. Someone mind getting me up-2-date?
Back to top
View user's profile Send private message MSN Messenger
Torch



Joined: 28 May 2008
Posts: 842

PostPosted: Sat Apr 11, 2009 12:21 am    Post subject: Reply with quote

Coldbird wrote:
I see. Well that's a bit of a problem... I suppose i will have to manually cut out unneeded functions of the module.


That would still require relocation....
Back to top
View user's profile Send private message
Coldbird



Joined: 08 Feb 2007
Posts: 155

PostPosted: Sat Apr 11, 2009 2:04 am    Post subject: Reply with quote

I know.
_________________
Been gone for some time. Now I'm back. Someone mind getting me up-2-date?
Back to top
View user's profile Send private message MSN Messenger
J.F.



Joined: 22 Feb 2004
Posts: 2906

PostPosted: Sat Apr 11, 2009 9:54 am    Post subject: Reply with quote

Which module is it that is so HUGE it doesn't fit in memory?? The majority of modules are small. You'd be much better off trimming memory from your app than trying to partially load modules. I would bet the code needed to do that would more than exceed the space saved in partially loading a module.
Back to top
View user's profile Send private message AIM Address
Coldbird



Joined: 08 Feb 2007
Posts: 155

PostPosted: Sat Apr 11, 2009 11:03 am    Post subject: Reply with quote

Uhm... I hardly doubt my module can save the memory needed to load that biggie without cutting a game of its thread-memory...

My Module <-- 20kb
My Usermodule Wrapper <-- 60kb (I think i could save like... half of that if i linked differently...)

The module I need...
pspnet_inet.prx <-- 210kb

See what I mean?

And to be more uh clear about the problem at hand, loading works fine...
I can load the module I need into memory with about every game I boot, but then I'm lacking memory to load and start the usermodule wrapper...

Or in a not so severe scenario... the usermodule wrapper loads but then the game crashes because it lacks memory for its own stuff.
_________________
Been gone for some time. Now I'm back. Someone mind getting me up-2-date?
Back to top
View user's profile Send private message MSN Messenger
Torch



Joined: 28 May 2008
Posts: 842

PostPosted: Sat Apr 11, 2009 11:36 am    Post subject: Reply with quote

You shouldn't be making user mode modules anyway. The only way you'll get them to work is on the Slim if you call the sctrlHenSetMemory or whatever in VSH mode so that when it reboots in game mode the full memory will be mapped to user memory.
Back to top
View user's profile Send private message
Coldbird



Joined: 08 Feb 2007
Posts: 155

PostPosted: Sat Apr 11, 2009 11:40 am    Post subject: Reply with quote

Torch - you know I need the usermode module, else hooking the adhoc functions is a pain in the ass.

The usermode module pretty much forwards the code via wrappers into the kernel one where I do my real stuff.

And I need the internet modules to get a connection to my server.
_________________
Been gone for some time. Now I'm back. Someone mind getting me up-2-date?
Back to top
View user's profile Send private message MSN Messenger
Torch



Joined: 28 May 2008
Posts: 842

PostPosted: Sat Apr 11, 2009 11:44 am    Post subject: Reply with quote

Why don't you get the system working first without any memory constraints? Then look at optimizing it. For that use the Slim extra memory. And like I said, to unlock the memory when the USE_LARGE_MEMORY flag is not set, you must manually call the sctrlHENSetMemory and restart kernel.
Back to top
View user's profile Send private message
Coldbird



Joined: 08 Feb 2007
Posts: 155

PostPosted: Sat Apr 11, 2009 11:56 am    Post subject: Reply with quote

Don't have a Slim. There ain't extra memory for me.
_________________
Been gone for some time. Now I'm back. Someone mind getting me up-2-date?
Back to top
View user's profile Send private message MSN Messenger
J.F.



Joined: 22 Feb 2004
Posts: 2906

PostPosted: Sat Apr 11, 2009 5:38 pm    Post subject: Reply with quote

I would be shocked to death if you could run pieces of pspnet_inet.prx without loading the whole thing. You're going to have to find some other way of making more memory available.
Back to top
View user's profile Send private message AIM Address
Display posts from previous:   
Post new topic   Reply to topic    forums.ps2dev.org Forum Index -> PSP Development All times are GMT + 10 Hours
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2005 phpBB Group