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 

difference performance BTW usermode and kernelmode

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



Joined: 17 Jul 2008
Posts: 10

PostPosted: Thu Jul 17, 2008 1:36 am    Post subject: difference performance BTW usermode and kernelmode Reply with quote

Hello everybody,

I'm new in forum and this is my first post => hi all.
Sorry for my poor english, i'm belgian french.

Do you know if it's a difference in performance between the 2 mode ?

I've 2 HB with same code but first is in kernel mode (Kmode) and second in User mode (Umode).

I'm streaming 8 MP3 in // (launched with thread and sema for sync) from memorystick.

4 is mute on and 4 other is mute off. i must be able to mute one and unmute one other, .....

In Kmode, i launch all MP3 (R) and i can press some key (L, X,O,....) to interact with MP3 (Play, pause, mute, unmute ....) or exit my HB (START). Sound is not so bad but there's some LAG, distorsion :-(

In Umode, when i'm launch MP3 (R key), i can't interact with any key , sound is totally destroy.
And I must power off my PSP to stop everything and restart it.

somebody know why ?

Tks for advance for your help
Back to top
View user's profile Send private message
adrahil



Joined: 16 Mar 2006
Posts: 277

PostPosted: Thu Jul 17, 2008 3:38 am    Post subject: Reply with quote

From what i can understand - after deciphering for a while - you're not giving enough information. You should post the relevant code instead of asking a general question...

But my guess is that 8 MP3 decodings at the same time might be a little too much for the PSP memory- and power- wise. As for the trouble exiting the kernel mode application, it is probably due to you not exiting properly at callback time.
Back to top
View user's profile Send private message
jmdetiege



Joined: 17 Jul 2008
Posts: 10

PostPosted: Thu Jul 17, 2008 8:50 pm    Post subject: Reply with quote

Hello,

Tks for your reply.

adrahil wrote:
But my guess is that 8 MP3 decodings at the same time might be a little too much for the PSP memory- and power- wise.


I think that'you right but do you know if streaming 8 WAV in // might be better than 8 MP3 in // (no decodings isn't it ?)

I would use MP3 for the little size

I explain the HB:

4 SOUND playing at the same time (1 for drums, 1 for guitar, 1 for Keyb, ...) => using thread for synchro
4 other sound with a different sound (guitar, keyb, ...)
it must be able to swith between guitar's sound or keyb' sound, ...

The 1st way (to do that) that i founded is :

- Launch all sound with thread (for playing synchro) and mute on the 4 other sound.
- Mute on and mute off each sound that i want to swith

The 2d way that i founded is

- Launch 4 sound
- when user want to change, pausing 4 sound , memories the offset of playing, stopping the sound and begin the new sound from the offset of the other sound

But for this second way i'm not found a lib which i can do that (i'm using sakya oslibmod 1_0_1) or i'm not able to use it efficiently.

Other way ? impossible result due to technical specification of PSP ?
Other idea (i'm open to everything) ?

Thanks a lot for your reply ?

jmdetiege
Back to top
View user's profile Send private message
Insert_witty_name



Joined: 10 May 2006
Posts: 376

PostPosted: Fri Jul 18, 2008 12:06 am    Post subject: Reply with quote

Why do you need kernel mode for audio?
Back to top
View user's profile Send private message
jmdetiege



Joined: 17 Jul 2008
Posts: 10

PostPosted: Fri Jul 18, 2008 12:19 am    Post subject: Reply with quote

it's my first develop and i'm use the oslibmod 1_0_1 and i don't see that it don't need kernel mode to playing MP3 (1_0_0 request kernel mode)

i think
Back to top
View user's profile Send private message
sakya



Joined: 28 Apr 2006
Posts: 190

PostPosted: Fri Jul 18, 2008 3:38 am    Post subject: Reply with quote

Hi! :)

jmdetiege wrote:
it's my first develop and i'm use the oslibmod 1_0_1 and i don't see that it don't need kernel mode to playing MP3 (1_0_0 request kernel mode)

OSLib MOD 1.0.0 needs kernel mode for mp3 playback (untouched from OSLib 2.10) while version 1.0.1 can play mp3 in user mode.

Here you can find the Super Patrick II sample from original OSLib "converted" to user mode.
http://www.sakya.it/downloads/Super_Patrick_II_3xx.rar

Note that you don't really need to create a new thread, I was just too lazy to remove it...

Ciaooo
Sakya
Back to top
View user's profile Send private message Visit poster's website
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