Author Topic: Gp2x Psone Emulator Running Realy Fast  (Read 111415 times)

sashz

  • Sr. Member
  • ****
  • Posts: 388
    • View Profile
    • http://
Gp2x Psone Emulator Running Realy Fast
« Reply #30 on: January 22, 2006, 09:08:29 am »
good datasheets on intel site

http://www.intel.com/design/embeddedpca/ap...ssors/index.htm



Quote
i have ported pcsx to the Zaurus a month ago but it was without any preformence tuning(then Sash or Laze put their own build on the feed).

i have been doing alot of research on dynamic recompilation of the R3000A to ARM9 core and i can say that i have a good direction on how to do this.

the things i need help with are:
1.examples of Arm Asm 
2.examples of Arm Asm with C
3.documention on Arm and R3000A cpu.

this emulator can go upto 15-18 fps without any dynamic recompiler in 3D games with a very very good code,but it can get to full speed easily with a modest dynamic recompiler(Gte which is the thing that do 3D calculations is part of the dynamic recompiler coz it is part of the cpu).

plz help us make this dream come true
plz post here some documention so i can start this dynamic recompiler
[div align=\"right\"][a href=\"index.php?act=findpost&pid=111913\"][{POST_SNAPBACK}][/a][/div]

urielka

  • Full Member
  • ***
  • Posts: 178
    • View Profile
Gp2x Psone Emulator Running Realy Fast
« Reply #31 on: January 22, 2006, 09:12:32 am »
misspelled you nick
thx man :0
i need some arm asm examples
and some arm-c example

sashz

  • Sr. Member
  • ****
  • Posts: 388
    • View Profile
    • http://
Gp2x Psone Emulator Running Realy Fast
« Reply #32 on: January 22, 2006, 09:17:14 am »
Quote
misspelled you nick
thx man :0
i need some arm asm examples
and some arm-c example
[div align=\"right\"][a href=\"index.php?act=findpost&pid=111915\"][{POST_SNAPBACK}][/a][/div]

kernel sources ? there alot examples :-)

urielka

  • Full Member
  • ***
  • Posts: 178
    • View Profile
Gp2x Psone Emulator Running Realy Fast
« Reply #33 on: January 22, 2006, 09:21:20 am »
hehe i will check that too but that is not on my level
i need some basic stuff and then i can go all the way.

sashz

  • Sr. Member
  • ****
  • Posts: 388
    • View Profile
    • http://
Gp2x Psone Emulator Running Realy Fast
« Reply #34 on: January 22, 2006, 09:22:51 am »
Quote
hehe i will check that too but that is not on my level
i need some basic stuff and then i can go all the way.
[div align=\"right\"][a href=\"index.php?act=findpost&pid=111917\"][{POST_SNAPBACK}][/a][/div]

look files in arch/arm/*
there you can see how mix arm-arm , arm-c code

urielka

  • Full Member
  • ***
  • Posts: 178
    • View Profile
Gp2x Psone Emulator Running Realy Fast
« Reply #35 on: January 22, 2006, 09:27:28 am »
thx

urielka

  • Full Member
  • ***
  • Posts: 178
    • View Profile
Gp2x Psone Emulator Running Realy Fast
« Reply #36 on: January 22, 2006, 10:01:38 am »
the linux kernel doesn`t help that much
i need a example of something like this:
a C function that do c = a +b in asm and return normaly like this:
Code: [Select]
int sum(int a,int b)
{
int c;
//here goes the asm code that take a and b do the math and return it on c
//asm code is  (add R1,R2,R3) or something if i am not wrong this means that //R3 = R1 + R2
return c;
}
how i do this,if someone show me how to pass data to asm and get data from asm

rmrfchik

  • Jr. Member
  • **
  • Posts: 90
    • View Profile
Gp2x Psone Emulator Running Realy Fast
« Reply #37 on: January 22, 2006, 10:46:35 am »
Quote
the linux kernel doesn`t help that much
i need a example of something like this:
a C function that do c = a +b in asm and return normaly like this:
Code: [Select]
int sum(int a,int b)
{
int c;
//here goes the asm code that take a and b do the math and return it on c
//asm code is  (add R1,R2,R3) or something if i am not wrong this means that //R3 = R1 + R2
return c;
}
how i do this,if someone show me how to pass data to asm and get data from asm
[div align=\"right\"][a href=\"index.php?act=findpost&pid=111920\"][{POST_SNAPBACK}][/a][/div]
Code: [Select]
gcc -S file.c will just compile C source into ASM, so you can examine both of ASM and how to pass data to asm and get from asm.
--
pdaXrom, SL-C860, Chronos (Billionton) BT/CF, SE Z600, SD 1Gb, Debian, brain damaged.

urielka

  • Full Member
  • ***
  • Posts: 178
    • View Profile
Gp2x Psone Emulator Running Realy Fast
« Reply #38 on: January 22, 2006, 01:07:11 pm »
kickass!
you are my god

zodttd

  • Full Member
  • ***
  • Posts: 188
    • View Profile
Gp2x Psone Emulator Running Realy Fast
« Reply #39 on: January 22, 2006, 01:18:18 pm »
Great to see people taking interest in getting the PSX running on the Zaurus.

I tried using the bvdd driver and it didn't give any speed boost over SDL. SDL on the Zaurus is much better than on the PocketPC with GAPI.

Urielka: When you compiled PCSX for the Zaurus, what needed to be changed in order for it to compile? I'm trying to track down some bugs in ZarPSX, which is based on PCSX 1.5 (though I've tried using 1.6 beta as well). If I could do a diff on your sources to mine, maybe I could fix it. Though, I don't use plugin's since the lineage of this code ran on a few other platforms that didn't support stuff like that.

I really hope we can get a PSX emu working on the Zar at good speeds. I'll do my best.
http://www.zodttd.com for all your psx4all needs (as in downloads and support). :)

CLICK HERE TO DONATE ANY AMOUNT VIA PAYPAL

Thanks for the support! I can hardly wait to get back into Zaurus development again. :)

urielka

  • Full Member
  • ***
  • Posts: 178
    • View Profile
Gp2x Psone Emulator Running Realy Fast
« Reply #40 on: January 22, 2006, 03:09:41 pm »
here is my post:
https://www.oesf.org/forums/index.php?showt...c=15552&hl=pcsx
it is basicly makefile stuff + Gte.c and softgpu
the thing is the this use Pepos SoftGPU and you use your own gpu which i think is better on speed but no that good on compatiblity

urielka

  • Full Member
  • ***
  • Posts: 178
    • View Profile
Gp2x Psone Emulator Running Realy Fast
« Reply #41 on: January 22, 2006, 04:39:40 pm »

stuffman

  • Full Member
  • ***
  • Posts: 104
    • View Profile
    • http://www.dylanpowell.net/zaurus
Gp2x Psone Emulator Running Realy Fast
« Reply #42 on: January 23, 2006, 02:35:27 am »
Hmm... just a thought. I really don't know a whole lot about the emulation field (I'm trying to learn as it seems interesting and I'd like to possibly help out on this project), but what about a static recompiler for the parts of a program that can be statically recompiled? You'd have to somehow figure out which portions of the code will never be modifed by other code, but then you do all the recompilation of this code on your desktop PC, and all the code that can't be statically recompiled will go throught the dynamic recompilier at runtime. I don't know the logistics of sorting thought code and figuring out what exactly can be statically recompiled and what can't, and quite frankly I don't even know if it's even possible (and if it is, how hard it is to do). If something like this is possible, it could provide a pretty significant increase in speed, some code wouldn't even have to be recompiled or reinterpreted at runtime.

Also, I'm still quite impressed that I can play Final Fantasy Tactics on my Zaurus, even if it is quite slow at the moment (remember, I have an C860, so it's a bit slower than you fancy Cxxxx owners   ). The little frontend thing where you select the ROM flickers like crazy for me. Also, sometimes text and stuff disappears and reappears magically, though that may have to do with HLE, as I can't find a PSX bios that works (I get an error with the ones I've tried... and my PSX is just sitting there in the closet taunting me). Thanks again for the fast progress on this awesome project!
[span style=\'font-size:8pt;line-height:100%\']SL-C860 Running pdaXrom 1.1.0beta1.
5GB Seagate ST-1 Microdrive from Rio Carbon, Asst. Other CF Cards.
512MB Sandisk SD.
AmbiCom WL1100C-CF WiFi Card.
Some GPS Card I Can't Remember...
Palm Tungsten Retractable Stylus (If You're Not Using These, You're Missing Out!).
[/font][/span]

urielka

  • Full Member
  • ***
  • Posts: 178
    • View Profile
Gp2x Psone Emulator Running Realy Fast
« Reply #43 on: January 23, 2006, 03:57:14 am »
static recompiler is not a option
you will have to create one for every program or one that can find patterns in program,it is better to write a dynamic recompiler
also there is no emulator that run with a true static recompiler so there is no way to learn how to do so.

stuffman

  • Full Member
  • ***
  • Posts: 104
    • View Profile
    • http://www.dylanpowell.net/zaurus
Gp2x Psone Emulator Running Realy Fast
« Reply #44 on: January 23, 2006, 04:46:32 am »
I admit I know very little about this stuff, so I'm probably wrong, but here's how I see it:

There will inevitibly be parts of the program that run the same subroutine over and over again, and it seems wasteful that a dynamic recompiler would have to take the time to transform the code every time it runs. If you could somehow find these parts and be sure code doesn't change, then it would make sense to go ahead and recompile them beforehand. You could just insert something that says "the following code is already transformed" and just bypass the dynarec and run that code natively, then when you reach the end of the pre-recompiled stuff, another marker would say to resume using the dynarec as normal. Admittedly, this is all moot if the performance of the dynarec is good enough to run at full speed anyways, and it wouldn't be worth the effort to do something like this. Alternatively (but probably even harder), you can make a "smart" dynarec that can recognise often-used code and cache the recompiled code and use it instead next time it's called. But heck, let's just worry about one step at a time! I'm already so happy at how fast this project is progressing.
[span style=\'font-size:8pt;line-height:100%\']SL-C860 Running pdaXrom 1.1.0beta1.
5GB Seagate ST-1 Microdrive from Rio Carbon, Asst. Other CF Cards.
512MB Sandisk SD.
AmbiCom WL1100C-CF WiFi Card.
Some GPS Card I Can't Remember...
Palm Tungsten Retractable Stylus (If You're Not Using These, You're Missing Out!).
[/font][/span]