View unanswered posts | View active topics It is currently Tue Nov 12, 2019 6:29 pm



This topic is locked, you cannot edit posts or make further replies.  [ 83 posts ]  Go to page 1, 2, 3, 4  Next
How other people should write their software 
Author Message
has wat u liek
User avatar

Joined: Tue Sep 11, 2007 2:54 pm
Posts: 559
Location: Banland.
Post How other people should write their software
Quote:
That would sorta of rock though.. "Bsnes: too demanding for today's fastest supercomputer"


No it wouldn't.

Throwing optimization out the window is utter insanity.

>.>

Honestly, this is exactly what is pissing me off so much lately with software in general. Developers not giving a shit for any form of optimization and justifying it with some BS. Like Vista, and loads others.

Sorry for being harsh, but I am fucking tired of no one giving a fucking damn anymore.


Last edited by mudlord on Mon Jul 28, 2008 3:30 am, edited 1 time in total.



Mon Jul 28, 2008 3:25 am
Profile
Post 
mudlord wrote:
Quote:
That would sorta of rock though.. "Bsnes: too demanding for today's fastest supercomputer"


No it wouldn't.

Throwing optimization out the window is utter insanity.

>.>


You're still going on about that? We have optimized emulators that run SFX/SA1 games already: here, here, here and here. What purpose would it serve for me to write yet another clone?

The SPC7110 code I have may not be lightning fast like in ZSNES, but it serves an important purpose: unlike with the register text document, it's possible to understand what each register fully does. And there's no non-essential stuff getting in the way of the raw implementation.


Last edited by byuu on Mon Jul 28, 2008 3:32 am, edited 1 time in total.



Mon Jul 28, 2008 3:30 am
has wat u liek
User avatar

Joined: Tue Sep 11, 2007 2:54 pm
Posts: 559
Location: Banland.
Post 
Quote:
You're still going on about that?


Is THAT a problem?


Quote:
We have optimized emulators that run SFX/SA1 games already: here, here, here and here. What purpose would it serve for me to write yet another clone?


But they are not accurate. There is a difference.

What we need is a accurate, and optimized emulator.


Mon Jul 28, 2008 3:32 am
Profile
Post 
Quote:
Is THAT a problem?


In this thread, it's getting to be.

Quote:
What we need is a accurate, and optimized emulator.


Nothing's stopping you from making it.


Mon Jul 28, 2008 3:33 am
has wat u liek
User avatar

Joined: Tue Sep 11, 2007 2:54 pm
Posts: 559
Location: Banland.
Post 
Quote:
Nothing's stopping you from making it.


Thats everyone's reaction.

"If you don't like it, make your own".

:roll:

Quote:
In this thread, it's getting to be.


I see. Then I won't respond in here if it pisses you off so much.


Mon Jul 28, 2008 3:34 am
Profile
Veteran
User avatar

Joined: Sat Apr 21, 2007 8:05 pm
Posts: 637
Post 
mudlord wrote:
Thats everyone's reaction.

"If you don't like it, make your own".

:roll:

It seems like it's everyone's reaction because everyone is working in their own way, at their own pace, on way, way more than one thing at a time. And honestly, you're one of the people who is knowledgeable enough in these things for it to be even possible that you COULD make your own. I don't really think the question is unfair, considering your experience. We can't just expect byuu to work on whatever we want him to at the drop of a hat... I don't think we can ask that of anyone here, really. Not even you.

It's not like no one "gives a damn", but all of the devs in these projects are doing the best they can in the style they choose to code. No one is literally throwing optimization out the window here. From what I've gathered, byuu likes to code things as accurately as he can, whether that sacrifices speed or not. Once this code is in place and properly tested, he DOES work to optimize as best he can. Work isn't finished here, and no one said it was. I'll be glad if and when the code becomes more "optimized", but I've got plenty of time to wait. Maybe that's just me being too easy to please, though: I see any activity as good activity.

_________________
I bring the trouble.


Mon Jul 28, 2008 3:44 am
Profile
Trooper
User avatar

Joined: Tue Oct 31, 2006 7:17 pm
Posts: 376
Post 
mudlord wrote:
Quote:
That would sorta of rock though.. "Bsnes: too demanding for today's fastest supercomputer"


No it wouldn't.

Throwing optimization out the window is utter insanity.

>.>

Honestly, this is exactly what is pissing me off so much lately with software in general. Developers not giving a shit for any form of optimization and justifying it with some BS. Like Vista, and loads others.

Sorry for being harsh, but I am fucking tired of no one giving a fucking damn anymore.


I was kidding when I said it would be cool -_-

Although no one really answered so I'm asking: Would a "supercomputer" (thousands of normal computers working together) could run bsnes at +10000000 fps? Or would it make no difference and basically run no faster than on your average PC?

I have no way to look and really understand bsnes codes but... how do you know it's not optimized? . Sure, maybe it could gain a few fps if it were coded in pure assembly, maybe a faster compiler...but for all I know it's basically going nearly as fast as it can go with it's current design.

I've been over this before but it's not always clear what people mean when they say "optimization". For me, there's a difference between design and optimization, so when I say "optimization" I mean "doing the 'same' "job" with the least amount of code or fastest code...Now another person could mean something entirely different and mean optimization in the sense of "opcode accurate vs cycle accurate"...Well yeah, of course switching to an opcode approach (nothing wrong with this approach btw, just different designs) is going to give you a hell of a lot more speed...But it's not the same emulator anymore and it's like comparing apple and oranges.

If someone could show bsnes could be substantially faster without sacrificing any accuracy or without going "back" to a higher level of code (opcode level for example) then yes: it would show it could use some optimization but until then I'm not convinced.

edit: hope the split of the the thread wasn't caused by something I said in this post...So, sorry if I said something stupid...

_________________
I want to fry~~ Sky Hiiiiiiiiigh~
Let's go-o-o-O~ togeda~


Mon Jul 28, 2008 4:20 am
Profile
has wat u liek
User avatar

Joined: Tue Sep 11, 2007 2:54 pm
Posts: 559
Location: Banland.
Post 
Quote:
how do you know it's not optimized?



Hmmmm....Lets see:

* Speed. Quite obvious there. However, the approach sort of justifies it. HOWEVER, it is possible to maintain speed while still being cycle accurate. Around TWO emulators proved its possible.
* Code quality (its very obvious that its written for clarity, NOT speed).



Quote:
I've been over this before but it's not always clear what people mean when they say "optimization". For me, there's a difference between design and optimization, so when I say "optimization" I mean "doing the 'same' "job" with the least amount of code or fastest code


Now THAT is exactly what I mean about optimization. To me it means, doing the same amount of work, with the least code AND space.



Quote:
Now another person could mean something entirely different and mean optimization in the sense of "opcode accurate vs cycle accurate"...Well yeah, of course switching to an opcode approach (nothing wrong with this approach btw, just different designs) is going to give you a hell of a lot more speed...But it's not the same emulator anymore and it's like comparing apple and oranges.


Correct. Which would throw BSNES's strengths entirely out the window.



Quote:
If someone could show bsnes could be substantially faster without sacrificing any accuracy or without going "back" to a higher level of code (opcode level for example) then yes: it would show it could use some optimization but until then I'm not convinced.


It could be a bit faster, but its not realistic saying that major improvements can be made.

BTW: Real mature with the topic name. :roll: Okay, that does it. No further BSNES help from me, with whatever renderers and shit. I had enough. Nice talking to you.


Mon Jul 28, 2008 4:40 am
Profile
Veteran
User avatar

Joined: Sat Apr 21, 2007 8:05 pm
Posts: 637
Post 
mudlord wrote:
BTW: Real mature with the topic name. :roll: Okay, that does it. No further BSNES help from me, with whatever renderers and shit. I had enough. Nice talking to you.

For whatever my opinion is worth, I sincerely doubt byuu moved this topic. It doesn't seem right to threaten to pull what is very much appreciated help just because of that. It's your decision, though.

_________________
I bring the trouble.


Mon Jul 28, 2008 4:47 am
Profile
Post 
Quote:
I see. Then I won't respond in here if it pisses you off so much.


I split the thread for you. Feel free to continue discussing the matter without me.

My bottom line: everyone should be free to develop however they want, and nobody has the right to tell others what they should be doing with their unpaid time. This goes for past poorly-made comments I've made, as well.

Quote:
Once this code is in place and properly tested, he DOES work to optimize as best he can.


Quote:
I have no way to look and really understand bsnes codes but... how do you know it's not optimized?


I'd estimate bsnes could be about twice as fast as it is now, without losing any accuracy at all. But if you give up just a little, you could get it to be much faster.

What people don't understand is that I'm just one person, working alone, with no pay or benefits. I work a full-time job, fight OCD, deal with a pretty severe sleeping disorder, and I also work on other major projects in the fan translation scene. I really have very little time.

If I were to spend more time optimizing bsnes, I would lose time improving it. If I were to optimize the code, it would be harder for me to read. If the code was harder for me to read, I wouldn't have made the progress I have. Spotting bugs would be much harder, replacing entire processor cores would take years instead of weeks, etc.

The fact that I've made as much progress in as little time as I have is clear evidence that my method has at least a little merit.


Last edited by byuu on Mon Jul 28, 2008 4:49 am, edited 1 time in total.



Mon Jul 28, 2008 4:48 am
has wat u liek
User avatar

Joined: Tue Sep 11, 2007 2:54 pm
Posts: 559
Location: Banland.
Post 
Quote:
t doesn't seem right to threaten to pull what is very much appreciated help just because of that. It's your decision, though.


Of course its my choice and I completely stand by it. :?


Mon Jul 28, 2008 4:48 am
Profile
Veteran
User avatar

Joined: Sat Apr 21, 2007 8:05 pm
Posts: 637
Post 
I know. I'm not mad or anything, I just always feel bad when everyone clashes around here. And I appreciate the work you all do, so I feel bad when something stops that progress.

_________________
I bring the trouble.


Mon Jul 28, 2008 4:53 am
Profile
Post 
Quote:
BTW: Real mature with the topic name. Okay, that does it. No further BSNES help from me, with whatever renderers and shit. I had enough. Nice talking to you.


Do you really feel that a couple of lines for an OpenGL renderer entitle you to treat me like dirt?

Well, it's your decision to make at any rate.

Could you also stop doing things like calling my methodologies BS just because you don't agree with them, then?

Quote:
Developers not giving a shit for any form of optimization and justifying it with some BS.


Mon Jul 28, 2008 4:54 am
has wat u liek
User avatar

Joined: Tue Sep 11, 2007 2:54 pm
Posts: 559
Location: Banland.
Post 
Quote:
everyone should be free to develop however they want, and nobody has the right to tell others what they should be doing with their unpaid time.


Good point. Point taken.


Quote:
If I were to spend more time optimizing bsnes, I would lose time improving it. If I were to optimize the code, it would be harder for me to read. If the code was harder for me to read, I wouldn't have made the progress I have. Spotting bugs would be much harder, replacing entire processor cores would take years instead of weeks, etc.

The fact that I've made as much progress in as little time as I have is clear evidence that my method has at least a little merit.


Good point, which brings back to the clarity argument.

Oh well, whatever you do is fine. I will just teach myself to not be so obsessive over little details such as noticing flaws in the tiniest things. And then making a issue over it, like always. :?


Mon Jul 28, 2008 4:55 am
Profile
Trooper
User avatar

Joined: Tue Oct 31, 2006 7:17 pm
Posts: 376
Post 
byuu wrote:
Quote:
I see. Then I won't respond in here if it pisses you off so much.


I split the thread for you. Feel free to continue discussing the matter without me.

My bottom line: everyone should be free to develop however they want, and nobody has the right to tell others what they should be doing with their unpaid time. This goes for past poorly-made comments I've made, as well.

Quote:
Once this code is in place and properly tested, he DOES work to optimize as best he can.


Quote:
I have no way to look and really understand bsnes codes but... how do you know it's not optimized?


I'd estimate bsnes could be about twice as fast as it is now, without losing any accuracy at all. But if you give up just a little, you could get it to be much faster.

What people don't understand is that I'm just one person, working alone, with no pay or benefits. I work a full-time job, fight OCD, deal with a pretty severe sleeping disorder, and I also work on other major projects in the fan translation scene. I really have very little time.

If I were to spend more time optimizing bsnes, I would lose time improving it. If I were to optimize the code, it would be harder for me to read. If the code was harder for me to read, I wouldn't have made the progress I have. Spotting bugs would be much harder, replacing entire processor cores would take years instead of weeks, etc.

The fact that I've made as much progress in as little time as I have is clear evidence that my method has at least a little merit.


Hope you weren't including me and the vast majority here in those people that doesn't understand your work : P I'm always supporting bsnes and your work certainly doesn't go unappreciated.


Last edited by Snark on Mon Jul 28, 2008 5:05 am, edited 2 times in total.



Mon Jul 28, 2008 5:02 am
Profile
has wat u liek
User avatar

Joined: Tue Sep 11, 2007 2:54 pm
Posts: 559
Location: Banland.
Post 
Quote:
Do you really feel that a couple of lines for an OpenGL renderer entitle you to treat me like dirt?


No

However, when there is immaturity around, I can't stand it. So, I honestly don't want anything to BSNES. Its that simple. Which means I won't assist with anything to do with it that I know I can do. Like graphics shit. I won't touch the source since obviously my views with code optimization completely and utterly clash, and then there's drama.

And we don't want that happening.

Quote:
Well, it's your decision to make at any rate.

Could you also stop doing things like calling my methodologies BS just because you don't agree with them, then?


Fine. I won't say what I think from now on. Is that good enough?


Mon Jul 28, 2008 5:02 am
Profile
Post 
Truth be told, we're both too damn polarized. Both of us. Sadly, we're destined to clash repeatedly. I wish that weren't the case, but it is what it is.

We both seem to be good at dragging each other down into pissing matches (ergo my previous post), which reflects badly on both of our characters.

Quote:
Oh well, whatever you do is fine. I will just teach myself to not be so obsessive over little details such as noticing flaws in the tiniest things. And then making a issue over it, like always.


No worries. If you don't want to help with bsnes, I understand. I really do appreciate the help, but it's clear our differences are too severe, and it's causing you a lot of unneeded stress. Just let me know if I can return the favor one day by helping with something I'm good at in VBA-M.

Quote:
No


Well, that's how I felt about what you said, anyway. For what it's worth.

Quote:
Fine. I won't say what I think from now on. Is that good enough?


I don't wish to silence you, I just wish you'd be a bit more respectful of others' opinions. Have I ever attacked your approaches in the VBA-M thread?

Quote:
Hope you weren't including me and the vast majority here in those people that doesn't understand your work


Definitely not :)


Mon Jul 28, 2008 5:05 am
Trooper
User avatar

Joined: Tue Oct 31, 2006 7:17 pm
Posts: 376
Post 
byuu wrote:
Quote:
Hope you weren't including me and the vast majority here in those people that doesn't understand your work


Definitely not :)


Aw whew!...I can sleep tonight j/k

_________________
I want to fry~~ Sky Hiiiiiiiiigh~
Let's go-o-o-O~ togeda~


Last edited by Snark on Mon Jul 28, 2008 5:08 am, edited 1 time in total.



Mon Jul 28, 2008 5:07 am
Profile
ZSNES Developer
ZSNES Developer

Joined: Tue Dec 28, 2004 6:47 am
Posts: 6747
Post 
Personally byuu, I think you could do better than to prefer asthetics than to trying to optimize when it comes to coding.

I'd say you certainly could try a little harder there. It's not a requirement, but it seems to me you could be better served by optimizing and commenting on what you are doing in the code. If you are having trouble reading it, it's because you are not reminding yourself wtf the code is doing. At least if you comment it, you can better served to optimize it (or improve it even) later on when you realize it's not that great.

Documentation doesn't have to suck.

_________________
Continuing FF4 Research...


Mon Jul 28, 2008 5:08 am
Profile
Post 
Deathlike2 wrote:
Personally byuu, I think you could do better than to prefer asthetics than to trying to optimize when it comes to coding.


You're right, of course. But I honestly have tried somewhat. Take a look at the PPU color blending code (many thanks to blargg there of course), look at my tile caching system, the optimizations in the PPU render loop, leaving blargg's S-DSP to run as a state machine rather than as a cothread (which would be ideal to me personally), and much of the CPU timing system.

There's really only two major bottlenecks, one which is the CPU NMI/IRQ edge testing. Profiling shows sCPU::add_clocks() consumes >40% CPU time alone. I've spent years trying to optimize it, it's all in the massive "bsnes thread archive." But I've failed. It really truly is above me as a programmer to do better there, sadly. The months I've wasted there trying to optimize could've meant mouse / superscope / justifier / SFX / SA-1 emulation instead.

The other major issue is that PGO doesn't work anymore. That gave a 30% speedup, free of charge.

Combine those two, and bsnes was almost equal to Super Sleuth in terms of speed.

The things I'm stubborn about don't really eat up that much extra time. The cothreads are debatably faster. We got a ~10% speedup compared to the previously convoluted nested switch tables when I first added them. The memory may have an extra indirection that allows me to dynamically remap entire memory ranges in a single line of code, but it's enabled things like SPC7110 and BS-X support to be trivial at a mere ~3% speed hit. It also means I'm not directly manipulating raw memory pointers, so you rarely if ever see bsnes crash from out-of-bounds memory accesses. I may use abstract base classes, but I've mitigated most of the damage by bypassing the polymorphism and referencing the final classes directly. The overhead I still take from this is made up by the fact that I can (and have, twice) replace entire CPU cores in a matter of weeks, rather than months or years.

I could enslave the S-SMP to the S-DSP (as all other emulators do) for a ~5-10% speedup, but that would be truly detrimental to readability to me. That my CPU and SMP work completely independently of one another is one of the things I am most proud of, in fact. But yeah, enslavement isn't something you can add a quick comment on and say "by the way, real hardware doesn't do any of this."

I may not use things like "NZ" processor flag optimization, but that really wouldn't make a huge difference, either.

If you have any other glaring areas that you feel should be improved, I'll welcome constructive criticism, and especially some help improving it. Seriously, if a comment will allow the same meaning to come across while not substantially hurting readability, I'll add it.

I rewrote the video filtering code after hearing that you didn't like it (and rightly so, it was a mess), so I honestly do listen to constructive criticism.


Mon Jul 28, 2008 5:21 am
has wat u liek
User avatar

Joined: Tue Sep 11, 2007 2:54 pm
Posts: 559
Location: Banland.
Post 
Quote:
Truth be told, we're both too damn polarized. Both of us. Sadly, we're destined to clash repeatedly. I wish that weren't the case, but it is what it is.


True. Nothing much can be done about that.



Quote:
We both seem to be good at dragging each other down into pissing matches (ergo my previous post), which reflects badly on both of our characters.


Yep, like with this whole thread and how I brought up my feelings about optimization (which to me, optimization matters a lot).



Quote:
but it's clear our differences are too severe, and it's causing you a lot of unneeded stress.


Yes, and because of our polarization, it just won't work out. So its wise to just avoid any confrontation at all, whatever it may be. If that involves me not contributing any code at all because it conflicts with your views, so be it.

Quote:
Just let me know if I can return the favor one day by helping with something I'm good at in VBA-M.


You could persuade Nach to get UPS support in. All my reminders to him have fallen on death ears, since he seemed very interested to implement it. :(

Quote:
Well, that's how I felt about what you said, anyway. For what it's worth.


Okay, well it certainly wasn't used as leverage. I was just saying, I don't feel the desire to help in any areas that I can (which are primarily anything graphics related), due to what was discussed earlier.



Quote:
Have I ever attacked your approaches in the VBA-M thread?


You are quite welcome to. However, most of the core was done by the previous official VBA devs & 3rd party patches. So the door is open to any criticism of our goals. I don't really care. Seeing what people truly think is good, least its all out in the open.

Besides, Exophase already abused me about it. So I doubt you will add anything new. :P


Mon Jul 28, 2008 5:52 am
Profile
Rookie
User avatar

Joined: Fri Feb 22, 2008 8:46 pm
Posts: 37
Post 
Your computer sucks
end of story

p.s. try MAME and/or MESS, and then be super offended that it's OMG NOT OPTIMIZED FOR YOUR CRAP COMPUTER. Accuracy comes before adventuring into breaking functionality down into speed hacks. In ZSNES/SNES9x's case, at the time it wasn't feasible to do any sort of accurate emulation with Pentium Pro 200s that were out at the time of their respective incarnations, therefore you are spoiled by emulator speed.

it's not like bsnes is the only snes emulator in the world and that you don't have a choice.

_________________
o^_^o


Last edited by leilei on Mon Jul 28, 2008 6:17 am, edited 1 time in total.



Mon Jul 28, 2008 6:12 am
Profile
has wat u liek
User avatar

Joined: Tue Sep 11, 2007 2:54 pm
Posts: 559
Location: Banland.
Post 
Quote:
Your computer sucks
end of story


Do you call a overclocked C2Q Q6600, with 2GB RAM crap?


Quote:
p.s. try MAME and/or MESS, and then be super offended that it's OMG NOT OPTIMIZED FOR YOUR CRAP COMPUTER. Accuracy comes before adventuring into breaking functionality down into speed hacks. In ZSNES/SNES9x's case, at the time it wasn't feasible to do any sort of accurate emulation with Pentium Pro 200s that were out at the time of their respective incarnations, therefore you are spoiled by emulator speed.


You obviously don't get it.

I am NOT complaining that emulators are slow for my computer. I am saying that optimization SHOULD matter, REGARDLESS of computer speed!!!! And when I say optimization, IT DOES NOT INVOLVE HACKS!

Is that so hard to fucking comprehend?

And no. I will NEVER use MAME/MESS when MooglyGuy is alive.


Last edited by mudlord on Mon Jul 28, 2008 6:17 am, edited 1 time in total.



Mon Jul 28, 2008 6:16 am
Profile
Rookie
User avatar

Joined: Fri Feb 22, 2008 8:46 pm
Posts: 37
Post 
mudlord wrote:
Quote:
Your computer sucks
end of story


Do you call a overclocked C2Q Q6600, with 2GB RAM crap?

I didn't call it crap. I said it sucks. It's true if it sucks if it's slow at bsnes and it has good specs on paper at that.

something is obviously wrong since bsnes runs playably fine and okay on my old sempron computer, which funnily enough it runs bsnes better than vba (which chokes on some games I have here, yeah talk about optimization lmao)

_________________
o^_^o


Mon Jul 28, 2008 6:17 am
Profile
has wat u liek
User avatar

Joined: Tue Sep 11, 2007 2:54 pm
Posts: 559
Location: Banland.
Post 
Quote:
It's true if it sucks if it's slow at bsnes and it has good specs on paper at that.


You obviously didn't read. *facepalm*

It aint slow at BSNES.

What I was saying all along is that optimization matters, REGARDLESS of how fast your CPU is, AND it doesn't really involve hacks if you know how to optimize well.

Byuu, however, believes code clarity matters first. And so, there is a major clash. EVEN though my views DON'T involve hacks.

Sheesh.


Mon Jul 28, 2008 6:21 am
Profile
Display posts from previous:  Sort by  
This topic is locked, you cannot edit posts or make further replies.   [ 83 posts ]  Go to page 1, 2, 3, 4  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

Search for:
Jump to:  
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group.
Designed by ST Software.