Help - Search - Members - Calendar
Full Version: Gp2x Psone Emulator Running Realy Fast
OESF Forums > Distros, Development, and Model Specific Forums > Distro Support and Discussion > pdaXrom
Pages: 1, 2, 3, 4, 5
urielka
Gp32x GP2x thread
Gp2x runs linux so there is any way to get it running on Pdaxrom or port the dynamic recompiler to pcsx(i assume that it have one).

Uriel
chrisluu
QUOTE(urielka @ Jan 10 2006, 05:17 PM)
Gp32x GP2x thread
Gp2x runs linux so there is any way to get it running on Pdaxrom or port the dynamic recompiler to pcsx(i assume that it have one).

Uriel
*


I think the first thing to do would be to get the source code to see if we can get it running on PdaXrom. You'd also probably have to recode some of it to fit the scheme of the PdaXrom, but I wouldn't mind taking a look at it if you could find the code.
urielka
i am in contact with the developer.
i will post here when i will have a working/stable version for pdaxrom.
scoutme
nice! we'll wait smile.gif
anunakin
I waiting too! when u got the sources, can u send us?
urielka
it is up to the developer if it will be open-source even if i will be come a developer i willn`t realse the code if he don`t want too(my part could be opensource but not for sure).
i will keep you update with what i can say to you.
danboid
Great news!

Running Strider 2, R-Type Delta or Gran Turismo 2 at a decent framerate on my Z would blow me away- if they're getting such good framerates on a 200Mhz xscale then maybe I could get sound too on my overclocked C3000? Here's hoping!

dan
urielka
it is a ARM920T it is not a Xscale it is better than a 200MHZ Xscale
anunakin
Damn... PSOne has a 33Mhz mips processor.... I cant beleave dont work nice in a SL-Cxx00 or 6K... or 5600! but in a 5500 I think this needs frameskip? cool.gif

OK! this is a open source or not?
urielka
it is not closed if it will be open or closed source.
for emulation you need 10 times more power so it is like having a 330MHZ mips processor.a mips processor also have a FPU which make it alot faster than a Xscale on Floating point math.
basicly emulation of the PSOne with a good Dynamic recompiler is posible on 400Mhz Xscales(or 266-300 Mhz StrongARM).

you need to understand that the GP2X has two processor of 200MHZ(ARM 920T and ARM 940T).
which can be used in the same time.

by the way:a Xscale is not realy a single core processor coz it have another core to execute iWMMX code so in theory if you write code in iWMMX and in normal ARM it can run in the same time which will give some speedups.
zodttd
Hello,

I'm the developer of GP2PSX for the GP2X. I'm extremely interested in getting the PSX running on the Zaurus C1000. I had never heard of this PDA before, but I really want one now. I will gladly get the PSX running great with pdaXrom, but I need to get the system first. I have a feeling it will be pretty hard for me to find the C1000 in my "price range". I will gladly work with the community for help in getting this project up and running.

On a side note, I've been able to get the GP2PSX codebase working on my 412MHz ARM Asus A620 PPC and playable speeds with very little work. I imagine with the Zaurus in my hands, and a few good full days of work, you can see the PSX running at playable speeds. I won't promise full speed, but I think with a powerful system (in comparison to what I normally work with), such as this, I can get a full speed PSX emu up and running in a matter of weeks.

So any ideas on how I could get a C1000 for cheap? tongue.gif

Thanks,
ZodTTD
urielka
yep in ebay smile.gif or just trade your PPC for one smile.gif
i am the guy from gp32x forum smile.gif
Antikx
There are many companies that will sell you a C1000.
If you are concerned about price... conics and priejapan are some of the cheapest. There's a guy on this forum (dice... something or other) selling a few C1000's.

If you set up a paypal donation button on your web page there may be people who would wish to donate. I'm still cathing up on Christmas bills but I may donate down the road if you are still keen on this project.

I would love a psx emulator.
anunakin
Thx, zodttd!

I think you go love the Zaurus C1000.... biggrin.gif
stuffman
Damn... I really wish I would win the lottery... the first thing I'd do (ok, maybe not the first thing, but one of the first things) is buy zodttd a C1000. Having a PSX emu on my Zaurus would be the most awesome thing in the world, and for once we have a developer willing to help us out (unlike, say the FPSEce people who guard thier source like it's a national treasure- it's awesome, sure, but I don't understand why they don't want to branch out). Being a poor college student, I can't help money-wise, but if there's anything else I can do let me know.

Also, what does this mean to us with non-Cxxxx devices? I have an 860, which doesn't have all the wMMX goodies. Any chance of getting it to run a decent speed? All I care is that I'm able to play Final Fantasy VII- everything else is icing on the cake.
bam
setup paypal and I am in for 20.00(usd)
zodttd
Hi, just an update to things...

This is the first time people have offered me donations before I started a project. Very cool community! I was able to buy a new C1000 for $397 US, shipped. It shipped REALLY fast, and already arrived. So I'm working on getting the source code polished up as well as setting up a Linux development environment. Most the code for the emulator is easily ported, and getting the GPU (graphics processing unit) code to blit to the framebuffer shouldn't be hard. I'll have to change some of the input code to support the Zaurus, since GP2PSX used code specific to the GP2X. Since the GP2X runs a flavor of Linux, most this code should be able to be ported pretty quickly. I'm hoping to have something working today. I'm in the process of getting Urielka set up so he can work his magic with a dynamic recompiler.

Thing's that definitely won't work right away:
Sound/Music

Thing's that might not work right away:
- A good frameskip option. I can get something working temp at first though.
- Support for ZNX compressed ISOs. Raw BIN and Z compressed ISOs should work though. Use PocketISO 2.0 from the *cough* FPSEce *cough* homepage to compress the ISOs.
- The control layout will probably suck and not be configurable at first. Any suggestions on a button layout?

Things to expect, even though we have no idea how it'll turn out:
The emu might run really slow at first. If it turns out that way, I'll do my best to get it going nice and fast. Using direct access to the framebuffer instead of SDL, and using a different GPU will help things greatly.

I'll add a donate link to my signature once I get the emu working on my C1000 and release a build.

Thanks for introducing me to this awesome handheld!
danboid
Wow!

Sounds like THE most exciting Z project going on right now- good luck with it!

About the controls- the CXX00 series have USB host so we should be able to plug a PSX style USB pad straight in right (with the appropriate adaptor if needed)? I've got a PSX style USB joypad by Gravis but it seems to be broke sad.gif As for joypad to keyboard key mapping, may I recommend:

CURSOR KEYS - DPAD (of course biggrin.gif )
Fn - 'Cross' fire button
SHIFT - 'Square' fire button
CTRL - 'Circle' fire button
Z - 'Triangle' fire button
CANCEL (on rear) - L1
OK (on rear) - R1
SCROLL WHEEL LEFT (on rear) - L2
SCROLL WHEEL RIGHT (on rear) - R2
ENTER or . - Start button
SPACE or , - SELECT

We thought you'd be impressed with the C1000- my dads got a C3000 and I think its the most amazing computer I've seen since I first saw an Amiga- thats f$£kin COOL! biggrin.gif I'm waiting for one with integrated wifi, more RAM, 3D graphics acceleration and USB2 woulds be nice! (Super Zaurii dreaming again laugh.gif )

Are you targetting the Sharp/Cacko or pdaxrom? Could you do builds for both? That would be fantastic!

Go zodttd!!
stuffman
Wow, great news! I can't wait to see what comes of this project.

As for the control layout, here's something you may want to consider (though I'm sure not everyone will go for it): Back when I was still using the Cacko ROM, I messed around with the Super Nintendo emulator quite a bit. It was clumsy with the key layout on my 860, but fun nonetheless. For some speed improvement, I downloaded a newer (modified) SDL and installed it. For some reason, using it caused my screen to rotate 180 degrees, so everything was upside-down when using the emulator. Though it was easy to remedy the flipped screen, I actually ended up liking it better that way- the direction keys were on the left like a standard controller, and surprisingly, it was more comfortable to hold this way (slightly awkward because the screen was below the controls, backwards from how most portable game systems are). This may not be to everyone's liking, but I'd suggest giving it a shot. I haven't used a C-1000 (well, actually, I used one to sign up for a credit card, but that's another story), but I'd imagine with the round direction pad, it'd be even easier to use.
Foxdie
Holy crap! I take a break and I return to find there's a PSX emulator in the works for the C series?

Goddam this is amazing news!

zodttd, I can't afford much in the way of money as I'm having to use all my spare cash on driving lessons, but if you need anything like webspace / mirrors just let me or anyone else here know, we'll look after you smile.gif
urielka
i am working on a dynamic recompiler for the emulator(with zodttd) so when it will be done we will have the closest possible to full speed.

does anyone know about a emulator that have SomeCPU->Arm(need to be for ArmV5 or ArmV4) dynamic recompiler?
it will help me to write the dynamic recompiler which one part of it is the execution of arm asm codes.

so if anyone have documention on Arm,R3000A(psx cpu) or GTE(Geometry Transformation Engine - part of the R3000A that is basicly the real 3d gpu and have other opcodes) plz post it here to help me to write this dynamic recompiler.
and plz donate so we can get this working faster.

Uriel
zodttd
A little update on things...

I have the PSX running on the Z C1000 running pdaXrom. Since I just got my C1000, and it being my first Zaurus, I know little about the system.

For instance, when I went to draw directly to the mmap'd framebuffer, it was drawn as if the screen was 480x640, instead of 640x480...rotated? Which brings me to another question, what's the most common Zaurus screen dimension?

Anyways, the PSX emu is running pretty slowly right now. If I get some example code or information on using the framebuffer with, at least, the Z C1000 I can speed things up. It's using SDL right now, and I modified things so it just Locks the surface, draws to the surface, unlocks then updates. Argh SDL!

Controls are working, the screen is stretched when needed to 640x480 (hardcoded though, which is probably a bad thing considering other Z's probably don't have a 640x480 screen). The screen stretching makes things go pretty slow. There isn't any hardware stretch on the Z Cxxxx series is there?

So, you might be able to play a simple 2D game pretty well at this point, but FF7 is still slow. :/

I'll work on it a bit more before releasing an initial build. I want to make sure compressed ISO's load, as well as try to speed things up more.

Wish me luck. ;P
ZodTTD
stuffman
Great to hear things are progressing fast!

The C-series Zauruses all have 640x480 screens, though they'll also run happily at a scaled 320x240. The latter may be a better choice for now, as I'm sure it's much faster drawing only a quarter as many pixels. Also, even though SDL sucks, things may be quicker if we could get the "special" libsdl that I remember using on Cacko working for pdaXrom. I don't remember where I got it other than I think the site was completely in japanese. It was much faster than the other libsdls out there at the time, but I don't know how it compares to the one were using.

Good luck, and if there's anything I can do to help, let me know (webspace, etc... if I had money, you'd be getting it first, for sure).
zodttd
Yay! ZarPSX has been released!

Grab ZarPSX v0.01 at:
http://www.friggingames.com/zarpsx.zip

So, I named the emu ZarPSX. It's a working title. It's ZarPSX and not ZaurPSX since I have a tendancy to prefix things with a 3 letter name. Any suggestions for a final name?

Stuff that works in ZarPSX so far:
- A few games. I'm playing R-Types right now. Most games have graphical glitches or run slow in 640x480 mode. Let me know if you get a game working well. My guess is games like Bust A Move 4 and Buster Bros, will run well. Vandal Hearts runs pretty well but with a graphical glitch at the top of the screen. Compatibility list anyone?
- Saving/Loading from memory cards should work.
- BIN/Z/ZNX ISO support. I use XDuplicator (CDRTAO open source project frontend) for ripping to raw BIN format, then compress to Z or ZNX with PocketISO 2.0.
- Frameskipping works. Right now I only have it so the frameskip setting makes the actual blit skip, not the rendering. I can get a good speed up if I skip rendering of frames, but it causes graphical glitches as you could imagine.
- GPU is now my own custom version of Dr Hell's GPU. I like it a lot, but it needs more tweaking.
- 640x480 build for full screen 640x480 screen, as well as a 320x240 build for a huge speed increase (60 FPS in Final Fantasy 7 with frameskip of 1-2, though FF7 crashes pretty quickly into the game, more on that later).
- All the default controls work. They're mapped as noted below. They'll change as the emulator progresses, I just had this button layout set before people started suggesting there own. smile.gif
- File menu for loading ISO's. It sucks, but it works! smile.gif
- HLE support works. Hold down the 'H' key when selecting an ISO to run the game using HLE. HLE should improve performance, and perhaps fix or cause glitches by the way it handles emulating the PSX BIOS. When HLE is used, no BIOS ROM is needed, and no PSX splash screen is seen.

Stuff that doesn't work in ZarPSX yet:
- Final Fantasy 7 as well as some other games don't work when they should. As you can see in the code for ZarPSX, it's based off of PCSX. Yeah, PCSX. :/ ...Good thing is, PCSX works with a lot of games, including FF7, which is why I'm unsure as to the reason my small modifications to the core of PCSX made these games not work. I was thinking it might actually have to do with some of the "plugin" code I jammed into ZarPSX such as PlugCD.c. If someone feels like getting these games working with ZarPSX, please PM me. smile.gif
- MDEC timings are off. This is probably a quick fix, but I timed the MDEC interrupt wrong. MDEC is the "movie codec" the PSX uses. So if you get really jittery or slideshow-like movies, this is why. I'll fix it asap.
- Games that span multiple ISOs won't work currently.

As I've explained to Urielka, ZarPSX's code is horrid imho. I think we can make this emulator much better as a community. So take a look at the code, clean it up, edit it, and submit it back to me, and I'll keep everything in order and keep the ZarPSX project humming along. Urielka is researching dynamic recompilers, and if a dynamic recompiler is made for ZarPSX, we will see a fairly good speed increase from it. Right now, 320x240 ZarPSX is pretty fast, full speed for most games with a single frameskip. But 640x480 ZarPSX needs about a 3 or 4 frameskip to reach the same speed, yet appears choppy. So let's get 640x480 full screen ZarPSX fullspeed! smile.gif

Things to help out:
- Get a compatibility list for ZarPSX up and running. This will help me out greatly, especially when the emu progresses. A wiki would be good for this most likely.
- Fix bugs in ZarPSX and submit them to me. wink.gif
- Get a CVS going?
- Help me figure out how to use the framebuffer on the Zaurus Cxxxx line.
- Get ZarPSX running on Zaurus' other than the Cxxxx line.

Keep in mind it's "normal" to wait a minute or so for the stupid PSX splash screen to finish. I'll speed this process up for the next release, in the meantime, wait for it or use HLE to skip the process.

----
How to use ZarPSX:
Run zarpsxhi for a full 640x480 resolution. Games will go slower.
Run zarpsxlow for 320x240 resolution. Games will go faster but will appear in a small window in the center of the screen. :/
----
Controls:
PSX -> Zaurus
UP/DOWN/LEFT/RIGHT -> Digital Pad
X/SQUARE/O/TRIANGLE -> A/S/D/F (might have these in the wrong order, i'll get the correct order in a bit)
L1/R1/L2/R2 -> Z/X/C/V
START -> ENTER
SELECT -> SPACE

SELECT ISO -> ENTER/OK
QUIT EMU -> BACKSPACE
LOWER FRAMESKIP -> K
RAISE FRAMESKIP -> L

Every once and awhile an issue comes along that a game reads from the wrong coord in the VRAM set for the PSX. I made a little fix for this by using the 'P' key to toggle this graphics fix. Don't use it unless you think it's needed (such as when the game seems frozen or is stuck on a blank screen).
----
BIOS:
If you do not use HLE, you will *NEED* a PSX BIOS. The BIOS should be named scph1001.bin and be located where zarpsx is. Please DO NOT ask for this file. If you can't find the file, try using HLE by holding down the 'H' key when selecting an ISO. HLE should give a slight speed increase as well, but may cause glitches.
----
Saving games:
Currently only saving through a memory card file is supported. That's why the two formatted memory card files (.mcr files) are included. Saving within the game to the memory card files should be the same as if it were being saved to an actual memory card on a PSX. So nothing to worry about here. Just keep the .mcr files in the same directory as zarpsx.
----
Required Librarys:
You will need the SDL library as well as the Zlib library installed on your Zaurus.
----
Required Zaurus:
This version will probably only work on the Cxxxx line of Zaurus' from the sounds of things. But maybe not, let me know! smile.gif


Hope you enjoy ZarPSX! There's a long ways for it to go, but it's coming along. Once the compatibility goes up and things speed up enough to be able to use 640x480 over 320x240, things will be smooth. I really do think a fullspeed PSX emulator with sound is possible on the Zaurus Cxxxx. Let's get this project nice and polished.

smile.gif
ZodTTD

P.S. Anyone interested in a port of OpenTTD (Transport Tycoon Deluxe) to the Zaurus? I've ported it to many other handhelds, and can probably get it up and running on the Zaurus fairly easily if it hasn't been done already.
Also, I just remembered I forgot the makefile to compile zarpsx. It's simple to compile though. If anyone needs help compiling, let me know.
zodttd
Just got some example code for bvdd support. I'll see if working it into the code makes things go faster, which it should. Argh SDL! tongue.gif
kalgriffen
I think it's great that you are putting the time and effort into getting this working (and asking for community support to boot!). Keep up the good work, and I do believe thanks are in order from all of us.
danboid
Whoah!

I can't believe how fast you got a PSX emu for the Z together zodttd! You must've had yr Z for, what, 3 whole days? Is that Rtype Delta you say you've got running? WOW, if so! Wow anyway! ohmy.gif biggrin.gif

I was keen to get pdaxrom on my C3000 but now this has been released... I probably won't be able to wait much longer before I put the new beta version on. I would imagine a bvdd version with a few more speed-ups would push me over the edge!

Don't suppose this first version supports a USB joypad?

If you were to ask me about the name I would only be able to name it psxz, but converted into zodish i suppose its called psxzee wink.gif
stuffman
Wowie wow wow wow! That was fast! I'd like to report that it is running on my C860, albeit *very* slowly at the moment. I don't know if it has to do with the Zaurus model itself or SDL or whatever, but running the zarpsxlow will runs fullscreen for me. Seeing as how I can only overclock my 860 to 471mhz (can it go higher? I'm afraid to try), a dynamic recompiler would be great, but heck, this project is only a few days old and I already have Final Fantasy Tactics running (slowly) on my Zaurus! Great work, keep it up!
desertrat
QUOTE(zodttd @ Jan 21 2006, 06:33 PM)
P.S. Anyone interested in a port of OpenTTD (Transport Tycoon Deluxe) to the Zaurus? I've ported it to many other handhelds, and can probably get it up and running on the Zaurus fairly easily if it hasn't been done already.
Also, I just remembered I forgot the makefile to compile zarpsx. It's simple to compile though. If anyone needs help compiling, let me know.

I had been wondering why no-one (AFAIK) has ported it to the Z yet. Since you asked, I, for one would not say no to your kind offer biggrin.gif

-- cheers
urielka
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 smile.gif
2.examples of Arm Asm with C smile.gif
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 smile.gif
plz post here some documention so i can start this dynamic recompiler smile.gif
sashz
good datasheets on intel site smile.gif

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



QUOTE(urielka @ Jan 22 2006, 06:00 AM)
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  smile.gif
2.examples of Arm Asm with C smile.gif
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 smile.gif
plz post here some documention so i can start this dynamic recompiler smile.gif
*
urielka
misspelled you nick smile.gif
thx man :0
i need some arm asm examples smile.gif
and some arm-c example smile.gif
sashz
QUOTE(urielka @ Jan 22 2006, 06:12 AM)
misspelled you nick smile.gif
thx man :0
i need some arm asm examples smile.gif
and some arm-c example smile.gif
*


kernel sources ? there alot examples :-)
urielka
hehe i will check that too but that is not on my level smile.gif
i need some basic stuff and then i can go all the way.
sashz
QUOTE(urielka @ Jan 22 2006, 06:21 AM)
hehe i will check that too but that is not on my level smile.gif
i need some basic stuff and then i can go all the way.
*


look files in arch/arm/*
there you can see how mix arm-arm , arm-c code
urielka
thx
urielka
the linux kernel doesn`t help that much sad.gif
i need a example of something like this:
a C function that do c = a +b in asm and return normaly like this:
CODE
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
QUOTE(urielka @ Jan 22 2006, 06:01 PM)
the linux kernel doesn`t help that much sad.gif
i need a example of something like this:
a C function that do c = a +b in asm and return normaly like this:
CODE
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
*

CODE
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.
urielka
kickass!
you are my god smile.gif
zodttd
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.
urielka
here is my post:
http://www.oesf.org/forums/index.php?showtopic=15552&hl=pcsx
it is basicly makefile stuff + Gte.c and softgpu smile.gif
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
good arm tutorial:
http://www.heyrick.co.uk/assembler/index.html
stuffman
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 dry.gif ). 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!
urielka
static recompiler is not a option smile.gif
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 smile.gif
also there is no emulator that run with a true static recompiler so there is no way to learn how to do so.
stuffman
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.
urielka
beacuse of that a dynamic recompiler have a cache which it store common stuff and don`t get recompiled again.(every good dynamic recompiler have a cache and even some have code optimzers,cache code is pretty simple).
if you will see a graph of the speed of the dynamic recompiler it will look like a y=e^x coz in the first moment it start slowly recompiling every asm code and then it gather stuff in the cache(not single opcodes but blocks of code) and then it start going real fast,the time that it takes to gather the cache stuff is less than a second coz in a second a R3000A(Psx Cpu) preforme more than 30 MIPS(Million instructions per second,of course this number is theoreticy limit and not real preformence).
chiark
Blimey guys, I leave my Z alone for a month, and now I find that there's a decent playstation emulator and the possibility of running TomTom on it.

I really must do this more often biggrin.gif

Great to see you all working together, too, rather than fragmenting which happens all too often in the open world.
zodttd
It's definitely cool to finally get help with this stuff! The Z has a great community. smile.gif

I'm posting the source to cleaned up version of ZPSX ( ZPSX sounds better than ZarPSX tongue.gif). It still has some odd bugs in it relating to how I'm compiling PCSX, but it now uses CDRiso which supports .bz instead of .znx. I'll include the shared library for libbz2 just in case someone doesn't have it. Hope thats ok.

Once I track down why PCSX is giving some games glitches such as freezing at the psx logo at boot, or 3D not rendering textures properly, game compatibility should go way up. I think it may have to do with how I'm compiling the emu, since in this version I took out all edits to PCSX, used a different "CD Plugin" and I tested the GPU and it works in Windows. Anyways, I'll compile in Pete's SoftGPU with as few modifications as possible, and see if I can get things working that way, just in case it is the GPU.

Time to study makefiles and get a new version using Pete's softgpu up again. tongue.gif
zodttd
Well, I worked on "ZarPSX" some more. I started over completely and tried to get PCSX up and running on the Zaurus using GTK, CDRiso compiled as a shared object, and Dr Hell's GPU. Still got the same bug in Final Fantasy Tactics (no textures are shown in the opening scene in the rotating 3D building), and Tactics Ogre glitches when choosing the birthday when starting a new game. What's weird is I never use to get these bugs on previous ports, until I started to port to the GP2X, which is also a ARM/Linux based handheld. Now I can't seem to figure out what's causing this bug. Am I missing a compiler option for int sizes or something (had an issue on the Palm port where int size of 2 or 4byte was an issue)? I really doubt it's Dr Hell's GPU, since I got Pete's SoftGPU running and it had the problem as well, even on the GP2X. This bug is really bothering me. If someone can figure it out, please let me know how to fix it! Thanks!

In the meantime I cleaned up ZarPSX 0.01's code, still have that bug, but the code is a bit nicer looking.

From the readme:

UPDATED January 23rd, 2006:
Grab ZarPSX v0.02 at:
http://www.friggingames.com/zarpsx002.zip

ZarPSX (working title), has been updated to v0.02. This release is pretty much a cleanup of code and a change of the CDR plugin to try to find out what's causing strange glitches in games.
Changes include:
- CDR plugin changed to cdriso. This allows for .bz compression, but has temporarily taken away .znx compression. Due to including bz compression, you will *need* to have the "libbz2.so.1.0" shared object file put inside the "/usr/lib" directory on your Zaurus. If you need this file, it is included in this release.
- Clean up of code. I've tried to take away most of the crap needed for previous ports of this emulator. What's left is pretty much barebones.
- Downgraded from PCSX 1.6b to 1.5. I seemed to have left some code related to 1.6b in the last release by accident. Fixed.
- Set default frameskip to 3

This release is only useful to those who care to look at or use the source. Not much has changed for end users of this emulator...yet. At least once I track down a certain bug, compatibility should go way up.
azalin
Could it be something like this
( http://www.oesf.org/forums/index.php?showtopic=9343&st=15 see the post by ikm)
QUOTE
The xpdf crashing on pdaXrom is a memory access processor issue. This is related to the ARM processor design. Those kind or bugs are hard to find in source code, even hardder when the source code is not yours, even harder when there are a lot of memory pointer for document handling.

Yep, these problems seem likely to be caused by the unaligned memory accesses, which are not handled correctly by the ARM processor. There is a handy gcc's option to hunt down memory alignment problems such as these:

CODE

      -Wcast-align
          Warn whenever a pointer is cast such that the required alignment of
          the target is increased.  For example, warn if a "char *" is cast
          to an "int *" on machines where integers can only be accessed at
          two- or four-byte boundaries.


It creates much false positives, but it still is easier than just reading all the code


Good luck on the project, it is awesome!
This is a "lo-fi" version of our main content. To view the full version with more information, formatting and images, please click here.
Invision Power Board © 2001-2014 Invision Power Services, Inc.