byuu's message board

For discussion of projects related to www.byuu.org/


Previous  1 ... 13, 14, 15, 16, 17, 18, 19 ... 27  Next
emulator efficiency 
Author Message

Joined: Wed 06 May 2009, 04:13:19

Posts: 4543
Post Re: emulator efficiency
SoraK05: Assuming, for argument's sake, that you're right about SNES CPU calls being "convertible" to native x86 CPU calls at minimal overhead... HOW DO YOU INTEND TO REPRODUCE VIDEO AND AUDIO FUNCTIONS?
Those subsystems are not part of the 65816, and have no analogue:A Hate Story in any IBM clone ever.


BMF54123 wrote:
why is this thread fourteen pages long

Because it's sixteen pages. Get with the times, man!

_________________
This post best viewed at 800x600
;write ! ! !

Sat 31 May 2014, 02:47:44
User avatar

Joined: Wed 08 Sep 2010, 17:05:03

Posts: 133
Post Re: emulator efficiency
CaptainJistuce wrote:
HOW DO YOU INTEND TO REPRODUCE VIDEO AND AUDIO FUNCTIONS?


He already explained that. In his mind a PC knows how to display pixels in the screen, so these math functions he is talking about can fill a buffer with the correct pixels. In his mind you only need to convert the Snes opcodes to compatible x86 opcodes, and that's it, you are done. Doing that you automatically will generate the video/audio data to send to the video card and audio card, and these cards knows what to do.

In other words, he has zero knowledge about this subject.

Sat 31 May 2014, 03:25:25
User avatar

Joined: Mon 20 Apr 2009, 08:11:50

Posts: 5266
Location: 日本
Post Re: emulator efficiency
The Doug wrote:
Kakashi wrote:
OK, byuu has officially declared this thread a train wreck, so anything goes...

The Doug and Alegend45 are officially pissed, which makes this supposed troll thread a success.
My question is: Where on Earth are vxbinaca, Braintrash, FirebrandX and Broseph? More hilarity required.



Hey Kakashi, this is a troll thread, but I see little contribution from your side. What's happening? This is your turf man.

Replies like this are enough to entertain me.

_________________
CaptainJistuce: He's totally in the wrong, Kakashi's 100% in the right.
Note: The above statement is subject to act of byuu.

Sat 31 May 2014, 04:23:53

Joined: Fri 26 Oct 2012, 14:47:06

Posts: 81
Post Re: emulator efficiency
What I am referring to for emulation purposes is to take shortcuts where applicable without breaking proportion and doing chunks of steps with some timing mainly for input/output. A buildup of the numbers to send to video/audio will be done with its own coding when appropriate, and the main calculation to reach it is tweaked to suit steps for the x86.

http://fms.komkon.org/EMUL8/HOWTO.html#LABI

This is one example I came up on.
There are steps and things which can be adjusted so that it isn't necessarily 'cycle accurate' but will maintain the same proportional expectation of calculations to result in the same numbers which get collected for sending to output every synced expectation.

I'm referring to matching the math and taking shortcuts for calculating numbers and some other global adjustments to eventually get that data to where it should like monitor/sound.
Bursts can be calculated and timings in place to offer reception to input and then send numbers out with outputting.

Where basic opcodes functions are met, and virtual buffers to accommodate expected data, direct calculations and then timing for input/output including some shortcuts which maintain proportion should still be accurate and be more efficient.
It doesn't require being cycle accurate to get the same math done on the ROM and get the same output numbers for 'efficiency' purposes and for being functional.

The outputting of the calculated data isn't so relevant - it is the concrete function of doing the calculation to result in that data, with some timing for input mainly as long as all the rest is done step-by-step (tweaked).
For archival purposes the steps (and perhaps a data file to relate to hardware layout with images) would be appropriate.

Thanks for all the input, and for higan/contribution.

Sat 31 May 2014, 06:08:32
User avatar

Joined: Mon 20 Apr 2009, 08:11:50

Posts: 5266
Location: 日本
Post Re: emulator efficiency
So now you're describing the Performance core and byuu's SMP/DSP cores for Snes9x. Congratulations, you've re-invented the wheel countless times.

_________________
CaptainJistuce: He's totally in the wrong, Kakashi's 100% in the right.
Note: The above statement is subject to act of byuu.

Sat 31 May 2014, 06:23:16
User avatar

Joined: Fri 10 Apr 2009, 20:54:19

Posts: 2679
Post Re: emulator efficiency
I think we have ourselves some pointy haired boss material.

_________________
blag

Sat 31 May 2014, 06:45:40

Joined: Wed 06 May 2009, 04:13:19

Posts: 4543
Post Re: emulator efficiency
SoraK05 wrote:
What I am referring to for emulation purposes is to take shortcuts where applicable without breaking proportion and doing chunks of steps with some timing mainly for input/output.

Shortcuts are not applicable because they DO change the results. That's kind of the problem.

Quote:
A buildup of the numbers to send to video/audio will be done with its own coding when appropriate, and the main calculation to reach it is tweaked to suit steps for the x86.

How do you "buildup the numbers"?

Quote:
http://fms.komkon.org/EMUL8/HOWTO.html#LABI

This is one example I came up on.

And seems entirely unrelated to your premise.
Compiler optimization switches and "don't use C++" is WAY different than what you seem to be proposing. And won't get you a Super Nintendo emulator running on a 486(I believe you said 20 MHz was a realistic goal?).

Quote:
There are steps and things which can be adjusted so that it isn't necessarily 'cycle accurate' but will maintain the same proportional expectation of calculations to result in the same numbers which get collected for sending to output every synced expectation.

No, because "cycle accurate" means you get the same results every emulated clock cycle that you would for a real clock cycle on real hardware. If you aren't cycle accurate, you AREN'T getting "the same numbers."
Not to mention cycle-accurate is itself inadequate. higan is subcycle accurate, because it MATTERS for the Super Nintendo.

Quote:
I'm referring to matching the math and taking shortcuts for calculating numbers and some other global adjustments to eventually get that data to where it should like monitor/sound.

If you cut corners, you have problems. It's that simple.

Quote:
Where basic opcodes functions are met, and virtual buffers to accommodate expected data, direct calculations and then timing for input/output including some shortcuts which maintain proportion should still be accurate and be more efficient.

And then we can hack up a GUI interface in visual basic to track the IP and geoposition the numbers! I see now!

Quote:
It doesn't require being cycle accurate to get the same math done on the ROM and get the same output numbers for 'efficiency' purposes and for being functional.

No, it doesn't require being cycle accurate. It requires you to be BETTER THAN CYCLE ACCURATE.

Quote:
The outputting of the calculated data isn't so relevant - it is the concrete function of doing the calculation to result in that data, with some timing for input mainly as long as all the rest is done step-by-step (tweaked).

Stop. Right now. I have to ask a question for clarification.

You DO understand that the SNES' audio and video hardware is not a dumb terminal, right? That EXTENSIVE data-processing occurs in both devices? That the 65816 is not only not the ONLY processor in the system, it's also not even the most important one?
Yes? That merely speeding up emulation of the CPU will do very little for overall emulation performance? Right?

You don't believe that merely speeding up CPU emulation will cause a hundred-fold increase in emulation performance?

_________________
This post best viewed at 800x600
;write ! ! !

Sat 31 May 2014, 06:57:38
User avatar

Joined: Mon 20 Apr 2009, 08:11:50

Posts: 5266
Location: 日本
Post Re: emulator efficiency
Chips? What are these chips you speak of? You need a motherboard file that does the math. Didn't you listen to him the 1000th time he reworded his proposal?

_________________
CaptainJistuce: He's totally in the wrong, Kakashi's 100% in the right.
Note: The above statement is subject to act of byuu.

Sat 31 May 2014, 07:01:10

Joined: Wed 06 May 2009, 04:13:19

Posts: 4543
Post Re: emulator efficiency
Kakashi wrote:
Chips? What are these chips you speak of?

They are delicious treats.

_________________
This post best viewed at 800x600
;write ! ! !

Sat 31 May 2014, 07:06:02
User avatar

Joined: Sun 05 Sep 2010, 15:42:48

Posts: 1344
Post Re: emulator efficiency
Code:
Asspull Mk.II
-------------
Slightly Less Braindead Edition

Layout:
* 65535 bytes of RAM.
* Five 16-bit registers.
* One 16-bit Program Counter.
* One 16-bit Stack Pointer.

Rules:
* Timing doesn't matter.
* Everything is abstract. Everything is cool when you're part of a team.
* Stack pointer works packwards from $FFFE.
* Execution starts from $0000.
* You decide how to handle compare and branch.

Opcodes:
$00 nop
$10 load rX, #YY
$11 load rX, #YYYY
$12 load rX, rY
$13 load rX, =$YYYY
$14 load rX, =rY
$20 store rX, =$YYYY
$21 store rX, =rY
$30 add rX, #YY
$31 add rX, rY
$40 sub rX, #YY
$41 sub rX, rY
$50 mul rX, #YY
$51 mul rX, rY
$60 div rX, #YY
$61 div rX, rY
$70 shl rX, #YY
$71 shr rX, #YY
$80 cmp rX, #YY
$81 cmp rX, rY
$90 beq $YYYY
$91 bnq $YYYY
$92 bgt $YYYY
$93 blt $YYYY
$94 jmp $YYYY
$95 call $YYYY
$96 return
$A0 int YY
$B1 push rX
$B2 push rY

Expected interrupts:
$00 nothing
$01 write zero-terminated string pointed at by r0 to screen.
$FF hang

Stupid little examples:
   .org 0
   load r0, #10   ; 10 00 0A
   int 1      ; A0 01
   int $ff      ; A0 FF
   .org 10
   .asciiz "Hello peepl!"

   .org 0
   load r0, #1   ; 10 00 01
   load r1, #3   ; 10 01 03
   add r0, r1   ; 31 00 01
   int $ff      ; A0 FF

   .org 0
   add r0, #1   ; 30 00 01
   jmp $0000   ; 94 00 00

   .org 0
   load r0, #2   ; 10 00 02
   call $0010   ; 95 00 10
   int $ff      ; A0 FF
   .org $0010
   mul r0, #2   ; 50 00 02
   return      ; 96



Here's your challenge, people. Accept it or not.

_________________
http://helmet.kafuka.org

Sat 31 May 2014, 08:46:53
User avatar

Joined: Thu 22 Mar 2012, 04:37:56

Posts: 502
Post Re: emulator efficiency
Where is Asspull Mk I?

Sat 31 May 2014, 09:47:13
User avatar

Joined: Sun 05 Sep 2010, 15:42:48

Posts: 1344
Post Re: emulator efficiency
wareya wrote:
Where is Asspull Mk I?
We don't speak of the Mk.1.

_________________
http://helmet.kafuka.org

Sat 31 May 2014, 10:00:19
User avatar

Joined: Fri 10 Apr 2009, 18:17:56

Posts: 3308
Location: Germany
Post Re: emulator efficiency
Kawa wrote:
* 65535 bytes of RAM.
* Stack pointer works packwards from $FFFE.

First value on the stack is always corrupted? :o

_________________
"The first time I watched [FLCL] I was like 12 or 13 and I was scared and confused." - isthisagoodusername
"I think it's more natural for human beings to be anxious. I think happiness is nothing but an illusion." - Hideaki Anno
"If you can't joke about incest in anime then what kind of world are we living in?!" - gothicmaster

Sat 31 May 2014, 10:16:58

Joined: Wed 06 May 2009, 04:13:19

Posts: 4543
Post Re: emulator efficiency
creaothceann wrote:
Kawa wrote:
* 65535 bytes of RAM.
* Stack pointer works packwards from $FFFE.

First value on the stack is always corrupted? :o

What kind of processor would it be without the odd glitch or two?

_________________
This post best viewed at 800x600
;write ! ! !

Sat 31 May 2014, 10:21:51
User avatar

Joined: Sun 05 Sep 2010, 15:42:48

Posts: 1344
Post Re: emulator efficiency
creaothceann wrote:
Kawa wrote:
* 65535 bytes of RAM.
* Stack pointer works packwards from $FFFE.

First value on the stack is always corrupted? :o
I don't math well. You might have heard. Anyway, you know damn well what the intent here is.

_________________
http://helmet.kafuka.org

Sat 31 May 2014, 10:23:26
Previous  1 ... 13, 14, 15, 16, 17, 18, 19 ... 27  Next

Who is online

Users browsing this forum: No registered users and 0 guests

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