English Amiga Board


Go Back   English Amiga Board > Coders > Coders. General

 
 
Thread Tools
Old 23 May 2009, 12:10   #121
Thorham
Computer Nerd
 
Thorham's Avatar
 
Join Date: Sep 2007
Location: Rotterdam/Netherlands
Age: 47
Posts: 3,751
Quote:
Originally Posted by meynaf View Post
There are several things that could be done. In fact 3 ! (and 3rd is alas incompatible with yours because the code would no longer fit in cache)
Pity, but it seems to save little, so it doesn't matter much.
Quote:
Originally Posted by meynaf View Post
I'm telling you the first one now, and, same as you, I can't believe I didn't spot that one sooner !
Look at the move to a6. What's in the array ? Addresses. Which point on what ? 4 bytes.
Hey man, why not directly copying the data there and use lea ?
Even if the data is in cache (often in this case) it's 3 cycles gained !
Right, I get it. But that means an indexed lea is faster than an indexed move, that's great! Now tell me the other ones, please.
Quote:
Originally Posted by meynaf View Post
Should be very long then
What is the bitrate ?
Yes, they're long. They're an hour of continuous music each. They were originally encoded in mp3 format, and the guy I got them from burned them to cd, so I encoded them at 320kb to keep them in a good quality. They're both 182 mb large. Still a lot better then 650 mb per cd.
Quote:
Originally Posted by meynaf View Post
Would be pretty pointless on a 030 IMO, especially with this slow IDE controller we have.
Yeah, the interface sucks, but only because it dumps data to chip mem, witch then has to be copied to fast, that's the real problem. If only it was cpu idle and low mem bandwidth, it would've been a lot better.
Quote:
Originally Posted by meynaf View Post
Frankly if I had the choice I would go for a 3Ghz 68080
Not me. You might as well get a peecee with those speeds. Trying to get things fast on a 50mhz '030 is part of the fun!
Quote:
Originally Posted by meynaf View Post
I plan on separating (in files) more things that need improvements, but vast areas are completely unknown to me (especially layer I & II).
But aren't layers one and two video layers? You shouldn't really need those for mp3s as far as I know.
Quote:
Originally Posted by meynaf View Post
asr keeps the sign where lsr inserts only zeroes, e.g. lsr.b #1 on $80 gives $40, but asr would give $C0. You can see this as asr being signed (half of -128 is -64, not 64).
That's very interesting, didn't know that, thanks.
Quote:
Originally Posted by meynaf View Post
Probably. But when I discovered that 6 muls by a,b,c,d,e,f constants could be done with only 4 because e=a+b and f=c+d, all that repeated 8 times, that made 16 muls removed
Now that's optimizing!
Quote:
Originally Posted by meynaf View Post
My reason about not using tabs : I put comments at the right, and those are often too long to fit in the line if using tabs. But a lot of people don't put many comments in their code so they don't understand that
If I comment code properly, I usually just split comments over several lines. If it doesn't fit, I'll compact the comment. Also, English comments are usually short enough
Quote:
Originally Posted by meynaf View Post
About extra blank lines : okay, but please give me examples on where.
This:
Code:
; 2. valeurs 2,e,14,20
; on utilise le fait que 3b21=32c6+85b et 3f74=26f6+187e
 move.l d1,a4			; z0
 move.l d0,a5			; zc
 move.l d1,a6			; z14
 move.l d0,d2			; z10
 neg.l d1			; z4
 neg.l d0			; z8

 move.w 2(a0),d4
 beq.s .l0

 move.w d4,d3
 muls #$32c6,d3
 sub.l d3,a4			; z0
 sub.l d3,d1			; -32c6

 move.w d4,d3
 muls #$26f6,d3
 sub.l d3,a5			; zc
 sub.l d3,d0			; -26f6

 move.w d4,d3
 muls #$187e,d3
 sub.l d3,d2			; z10
 sub.l d3,d0			; -26f6 -187e -> -3f74

 muls #$85b,d4
 sub.l d4,a6			; z14
 sub.l d4,d1			; -32c6 - 85b -> -3b21
And this:
Code:
.loop

 ifne round
	moveq #2,d1
	moveq #2,d2
	moveq #2,d3
	add.b (a0)+,d1
	subx.b d4,d4			; 00 si ok, FF si ça dépasse
	or.b d4,d1			; inchangé si ok, FF si ça dépasse
	add.b (a0)+,d2
	subx.b d4,d4
	or.b d4,d2
	add.b (a0)+,d3
	subx.b d4,d4
	or.b d4,d3
 else					; round=0 pas d'arrondi, on coupe juste
	move.b (a0)+,d1
	move.b (a0)+,d2
	move.b (a0)+,d3
 endc
;
; Do this in parts later.
;
; moveq #-4,d4			; fc
; and.b d4,d1
; and.b d4,d2
; and.b d4,d3
;
 move.l d1,d4			; rrrr....
 lsl.l #4,d4			; rrrr....0000
 move.b d2,d4			; rrrrvvvv....
 lsl.l #4,d4			; rrrrvvvv....0000
 move.b d3,d4			; rrrrvvvvbbbb....
 lsr.l #4,d4			; rrrrvvvvbbbb
 move.l (a5,d4.l*4),a6
;
; Register swap and dec instead of
; inc (modify table gen a little)
;
 move.l d3,d6
 sub.b -(a6),d6
 bcc.s .n0
 neg.b d6

.n0
 move.l d2,d5
 sub.b -(a6),d5
 bcc.s .n1
 neg.b d5

.n1
 move.l d1,d0
 sub.b (a6),d0
 bcc.s .n2
 neg.b d0

.n2
 add.l d5,d0			; r+v
 add.l d0,d0			; (r+v)*2 = 2r+2v
 add.l d5,d0			; 2r+3v
 add.l d6,d0			; 2r+3v+1b

 move.l d1,d4
 sub.l a2,d4
 bpl.s .n3
 neg.l d4
 add.l d4,d4			; r *2

.n3
 move.l d2,d5
 sub.l a3,d5
 bpl.s .n4
 neg.l d5

.n4
 move.l d5,d6
 add.l d5,d5
 add.l d6,d5			; v *3
 move.l d3,d6
 sub.l a4,d6
 bpl.s .n5
 neg.l d6
.n5						; b *1

 add.l d4,d5			; d4=r d5=r+v d6=b
 add.l d6,d4			; r+b r+v b
 add.l d6,d6			; r+b r+v 2b
 add.l d5,d6			; r+b r+v 2b+r+v
 beq.s .vbrb			; all together = 0 -> gbrb
 sub.l d4,d6			; r+b r+v v+b

; d6=r d5=b d4=v d0=f
 cmp.l d4,d6
 bls.s .br
 cmp.l d4,d5
 bls.s .bx
 cmp.l d4,d0
 bls.s .fi

.ve
 moveq #-4,d4		;Moved (see above)
 and.b d4,d2

 move.l d2,a3
 addq.b #3,d2
 move.b d2,(a1)+
 dbf d7,.loop
 rts

.br
 cmp.l d6,d5
 bls.s .bx
 cmp.l d6,d0
 bls.s .fi

.ro
 moveq #-4,d4		;Moved
 and.b d4,d1

 move.l d1,a2
 addq.b #2,d1
 move.b d1,(a1)+
 dbf d7,.loop
 rts

.bx
 cmp.l d5,d0
 bls.s .fi

.bl
 moveq #-4,d4		;Moved
 and.b d4,d3

 move.l d3,a4
 addq.b #1,d3
 move.b d3,(a1)+
 dbf d7,.loop
 rts

.fi
 move.b (a6)+,d3	;Changed from dec to inc.
 move.b (a6)+,d2	;This is why the palette table
 move.b (a6)+,d1	;has to be altered a little.

 move.b (a6),(a1)+	;Moved for pipeline.

 move.l d1,a2
 move.l d2,a3
 move.l d3,a4
 dbf d7,.loop
 rts

.vbrb
 btst #0,d7				; 0,2 -> b
 beq.s .bl
 btst #1,d7				; 1 -> r
 beq.s .ro
 bra.s .ve				; 3 -> v	(3210->vbrb)
Quote:
Originally Posted by meynaf View Post
For me they are code which fit in the cache and is responsible of an important part of the overall time. How do you define them ?
Code witch is executed a large number of times in a loop. It doesn't have to fit in the cache, and it can call outside routines if need be. Not much difference.
Quote:
Originally Posted by meynaf View Post
If you have any doubt, remember that you can now check it by yourself : you have the whole code and means to assemble and run it !
(and remember to flush libs between attempts - you'll also need to eject and reload the module before new settings can take effect)
Great, I forgot about the flush libs thing. Bah
Quote:
Originally Posted by meynaf View Post
It's not a matter of being slow, it's a matter of being not free (even though at overall it's still much cheaper than a DSL), so I keep it online only when I'm actually using it.
That makes sense.
Quote:
Originally Posted by meynaf View Post
Perhaps it looks odd. But my usual includes (you know them now ) allow me to do that in two lines of code, without worrying about removing it at the end or saving regs in the int itself.
Two lines, huh? Then such a program should still be easy to write.
Quote:
Originally Posted by meynaf View Post
I did not mean part of the library, but part of the benchmark program.
Okay.
Quote:
Originally Posted by meynaf View Post
Cutting is probably a better idea here.
However if you feel like encoding something, a few mp1/mp2 could be of use.
I don't know if I have the software. If not I can probably download it. But, who uses mp1/mp2? My guess is no one.
Quote:
Originally Posted by meynaf View Post
It seems that the "mpega" program (which is a player) is able to decode to disk, too. Was it that program ?
I think it is.
Quote:
Originally Posted by meynaf View Post
Seen anything now ?
Not yet. This code is quite tough. Maybe I'll never spot a single thing, so I'm not promising anything. It's fun to try, though.
Quote:
Originally Posted by meynaf View Post
If it sounds good... just do it !
Not yet. I'm going to keep looking first. Maybe I'll spot more interesting optimizations. If tables won't increase the speed much, it's perhaps better to try them later, when all else has failed.
Quote:
Originally Posted by meynaf View Post
Well, some changes can be better for all cpus, but things are very different when it comes to muls vs shifts.
Yeah, that's true. For '060 you don't need shifts at all, as far as I know. Makes life simple, though.
Quote:
Originally Posted by meynaf View Post
What's not clear is which parts are the best for non-030 !
I'd still forget about it for now, if I were you. Just focus on the cpu that needs optimizations the most.
Quote:
Originally Posted by meynaf View Post
What ? Don't tell me you can't reduce that to half
Yeah, right, if only.
Quote:
Originally Posted by meynaf View Post
It IS tough. But if something significant was done in here, it would dramatically reduce the speed impact of the "quality" setting.
Haven't seen anything so far...
Quote:
Originally Posted by meynaf View Post
If this is the "mpega" program then I have it.
Now we need some optims to check
Yes, I think it is. Just try decoding a single three minute song in good quality to wav and play it back. If it sounds good, it's the program.
Thorham is offline  
Old 24 May 2009, 13:39   #122
meynaf
son of 68k
 
meynaf's Avatar
 
Join Date: Nov 2007
Location: Lyon / France
Age: 51
Posts: 5,323
Quote:
Originally Posted by Thorham View Post
Right, I get it. But that means an indexed lea is faster than an indexed move, that's great! Now tell me the other ones, please.
An lea is always faster than equivalent move, because it doesn't access memory, it just takes the address of it. And you certainly know that memory accesses aren't exactly what's fastest for a CPU nowadays

As for the next one :
Code:
 move.b (a0)+,d0
 move.b (a0)+,d2
 move.b (a0)+,d3
 moveq #-4,d4   ; fc
 and.b d4,d2
 and.b d4,d3
 and.l d0,d4    ; d0=original, d4=and fc
 move.l d4,d1
We can then use d0 where the 2 lower bits don't need to be cleared ; we have a copy of the data that's free to make. The part computing the 4-4-4 rgb value is the good place to use it.
Okay, that's only 2 cycles ;-)

The last one was more complex to do. The idea was to move fixed pixel computation at the end, so that before doing it we know that this particular pixel is identical to its predecessor.
It involved much code duplication, due to massive register shortage.
But now this code :
Code:
 add.l d4,d5   ; d4=r d5=r+v d6=b
 add.l d6,d4   ; r+b r+v b
 add.l d6,d6   ; r+b r+v 2b
 add.l d5,d6   ; r+b r+v 2b+r+v
 beq.s .vbrb   ; all together = 0 -> gbrb
is executed earlier, and images with identical rows of pixels will decode faster (this isn't spectacular, but now Visage is ALWAYS beaten )

Quote:
Originally Posted by Thorham View Post
Yes, they're long. They're an hour of continuous music each. They were originally encoded in mp3 format, and the guy I got them from burned them to cd, so I encoded them at 320kb to keep them in a good quality. They're both 182 mb large. Still a lot better then 650 mb per cd.
Perhaps you can gain a little bit more without altering quality. There is a PC program around called MP3 optimizer or something like that (I could use it at work some time ago) ; for me it has turned a 20Mb 320kbps MP3 into a 16Mb VBR MP3 without any loss.

Quote:
Originally Posted by Thorham View Post
Yeah, the interface sucks, but only because it dumps data to chip mem, witch then has to be copied to fast, that's the real problem. If only it was cpu idle and low mem bandwidth, it would've been a lot better.
For that you'd need an SCSI extension plugged in your A1230 board, or something like that. But for IDE there is no DMA channel at all : the CPU simply reads a 16-bit hardware register (= speed of chipmem) and copies data wherever needed. Not efficient (but data really won't go into chipmem).

Quote:
Originally Posted by Thorham View Post
Not me. You might as well get a peecee with those speeds. Trying to get things fast on a 50mhz '030 is part of the fun!
But I firmly believe a 3Ghz peecee would be far beaten by an equivalent 68k.
And trying to get things fast on your 030-50 is fun only when you're successful

Quote:
Originally Posted by Thorham View Post
But aren't layers one and two video layers? You shouldn't really need those for mp3s as far as I know.
ALL are video layers if you see things like that. MP3 is just version #3 of the audio part, like the two 1 & 2 layers were.
All the MPx formats are just Motion Picture expert group, audio part, layer x.

Note : MP1 and MP2 are somewhat misnamed and can be confused with MPEG-1 and MPEG-2 video formats.
You have MPEG-1 layer 3 and MPEG-2 layer 3 for audio (there is also an unofficial MPEG2.5), just to make things simpler
Drop an MP3 into DT and you will read e.g. MPEG1-III as format.

What you need to know is that MPEG audio has 3 (now 4) layers, each one being more efficient and more complex than its predecessor. Layer 4 is AAC (M4A).
It's just accidental that MP3 got so widely used as standalone audio.

All first 3 layers are supported by original mpega.library so I want to keep that, even though I have no layer 1 at all and only one layer 2 stream to test

Quote:
Originally Posted by Thorham View Post
That's very interesting, didn't know that, thanks.
Any time

Quote:
Originally Posted by Thorham View Post
Now that's optimizing!
Indeed.

Quote:
Originally Posted by Thorham View Post
If I comment code properly, I usually just split comments over several lines. If it doesn't fit, I'll compact the comment. Also, English comments are usually short enough
English comments may be short, but they're rarely precise enough

I don't see the point in putting more than one space at left of code anyway. Code formatted like that leaves left half for code, right half for comments and it's good for me.

Anyway, code formatting is source of endless discussions between programmers, perhaps it's finally just a matter of personal taste.
Btw. where do you put your opening curly braces ? At the wrong place I bet

Quote:
Originally Posted by Thorham View Post
This:
(...)

And this:
(...)
Perhaps it's a little bit of exageration. For me, it is.
If I did my 44000 lines DM1 source like that it'd end up 60000 lines or so

Quote:
Originally Posted by Thorham View Post
Code witch is executed a large number of times in a loop. It doesn't have to fit in the cache, and it can call outside routines if need be. Not much difference.
Well, now you can have a look in that big source to see if you spot things which look like that.

Quote:
Originally Posted by Thorham View Post
Great, I forgot about the flush libs thing. Bah
Made any test so far ?

Quote:
Originally Posted by Thorham View Post
Two lines, huh? Then such a program should still be easy to write.
As I said, only problem is to actually call the library to do the job.

Quote:
Originally Posted by Thorham View Post
I don't know if I have the software. If not I can probably download it. But, who uses mp1/mp2? My guess is no one.
I have one mp2 (coming from Aminet), so what ? Should I really remove functionalities off the lib and delete it ?

Quote:
Originally Posted by Thorham View Post
I think it is.
So it is.
But now that I think about it, using an external program would perhaps add some quite random I/O time and lose accuracy. Unsure, though.

Quote:
Originally Posted by Thorham View Post
Not yet. This code is quite tough. Maybe I'll never spot a single thing, so I'm not promising anything. It's fun to try, though.
C'mon, kill a few seconds of decoding for me...

Quote:
Originally Posted by Thorham View Post
Not yet. I'm going to keep looking first. Maybe I'll spot more interesting optimizations. If tables won't increase the speed much, it's perhaps better to try them later, when all else has failed.
Good luck, pal. You'll need it.

Quote:
Originally Posted by Thorham View Post
Yeah, that's true. For '060 you don't need shifts at all, as far as I know. Makes life simple, though.
If it's too simple for you, you can still reschedule things for dual execute... should be fun too.

Quote:
Originally Posted by Thorham View Post
I'd still forget about it for now, if I were you. Just focus on the cpu that needs optimizations the most.
But now I see nothing left to do...

Quote:
Originally Posted by Thorham View Post
Haven't seen anything so far...
For 3 blocks adda.l a6,a4 can be removed because A4 is not used, so don't care about them, it's a known thing. But that's neglectable...

Quote:
Originally Posted by Thorham View Post
Yes, I think it is. Just try decoding a single three minute song in good quality to wav and play it back. If it sounds good, it's the program.
So if mpega.library can sound good enough, have you tried the version in my archive, with its default settings ?
meynaf is offline  
Old 27 May 2009, 20:16   #123
Thorham
Computer Nerd
 
Thorham's Avatar
 
Join Date: Sep 2007
Location: Rotterdam/Netherlands
Age: 47
Posts: 3,751
Quote:
Originally Posted by meynaf View Post
An lea is always faster than equivalent move, because it doesn't access memory, it just takes the address of it. And you certainly know that memory accesses aren't exactly what's fastest for a CPU nowadays.
And it's so obvious that it get's looked over way to easily It also helps that I never use lea...
Quote:
Originally Posted by meynaf View Post
As for the next one :
Code:
...
We can then use d0 where the 2 lower bits don't need to be cleared ; we have a copy of the data that's free to make. The part computing the 4-4-4 rgb value is the good place to use it.
Okay, that's only 2 cycles ;-)

The last one was more complex to do. The idea was to move fixed pixel computation at the end, so that before doing it we know that this particular pixel is identical to its predecessor.
It involved much code duplication, due to massive register shortage.
But now this code :
Code:
...
is executed earlier, and images with identical rows of pixels will decode faster (this isn't spectacular, but now Visage is ALWAYS beaten.)
Great Can it be downloaded already? I really want look at this.
Quote:
Originally Posted by meynaf View Post
Perhaps you can gain a little bit more without altering quality. There is a PC program around called MP3 optimizer or something like that (I could use it at work some time ago) ; for me it has turned a 20Mb 320kbps MP3 into a 16Mb VBR MP3 without any loss.
That's impressive, but with 240 gig of hd space not really needed
Quote:
Originally Posted by meynaf View Post
For that you'd need an SCSI extension plugged in your A1230 board, or something like that. But for IDE there is no DMA channel at all : the CPU simply reads a 16-bit hardware register (= speed of chipmem) and copies data wherever needed. Not efficient (but data really won't go into chipmem).
Oh no, they use the cpu to read a register Man, that sucks. I thought the data was dmaed (new word) to chipmem. That would at least allow data that needs to be in chipmem to be transferred there directly. Pity
Quote:
Originally Posted by meynaf View Post
But I firmly believe a 3Ghz peecee would be far beaten by an equivalent 68k.
Of course, but it would probably be more expensive as well. Besides, such a fast 68k cpu wouldn't be much fun, no challenge
Quote:
Originally Posted by meynaf View Post
And trying to get things fast on your 030-50 is fun only when you're successful.
To me, trying is part of the fun.
Quote:
Originally Posted by meynaf View Post
ALL are video layers if you see things like that. MP3 is just version #3 of the audio part, like the two 1 & 2 layers were.
All the MPx formats are just Motion Picture expert group, audio part, layer x.

Note : MP1 and MP2 are somewhat misnamed and can be confused with MPEG-1 and MPEG-2 video formats.
You have MPEG-1 layer 3 and MPEG-2 layer 3 for audio (there is also an unofficial MPEG2.5), just to make things simpler.
Drop an MP3 into DT and you will read e.g. MPEG1-III as format.

What you need to know is that MPEG audio has 3 (now 4) layers, each one being more efficient and more complex than its predecessor. Layer 4 is AAC (M4A).
It's just accidental that MP3 got so widely used as standalone audio.
Right, got it, I think
Quote:
Originally Posted by meynaf View Post
All first 3 layers are supported by original mpega.library so I want to keep that, even though I have no layer 1 at all and only one layer 2 stream to test/
Okay, but does anyone actually use it? Everyone encodes music in mp3, ogg, etc these days. It would be a waste of time to optimize code that won't be used. It seems a lot better to get the mp3 part to be as fast as possible.
Quote:
Originally Posted by meynaf View Post
English comments may be short, but they're rarely precise enough.
That depends on the coders commenting skills
Quote:
Originally Posted by meynaf View Post
I don't see the point in putting more than one space at left of code anyway. Code formatted like that leaves left half for code, right half for comments and it's good for me.

Anyway, code formatting is source of endless discussions between programmers, perhaps it's finally just a matter of personal taste.
Yes, but not everything. Having big blocks of code without spaces in between a few lines here and there makes it harder to read.
Quote:
Originally Posted by meynaf View Post
Btw. where do you put your opening curly braces ? At the wrong place I bet.
Perhaps, perhaps not. I don't write in C often, and as such my C coding style is probably less then optimal.
Quote:
Originally Posted by meynaf View Post
Perhaps it's a little bit of exageration. For me, it is.
If I did my 44000 lines DM1 source like that it'd end up 60000 lines or so.
And be much easier to read, I bet
Quote:
Originally Posted by meynaf View Post
Well, now you can have a look in that big source to see if you spot things which look like that.
It's been 'fun' so far... Man, what a big one
Quote:
Originally Posted by meynaf View Post
Made any test so far ?
I tried the library itself. The problem was that I thought I had to reset to get the new library to work after testing the original, witch made me think that trying things would suck. D'oh. I had totally forgotten about flushlibs.

Anyway, since the problem is solved... I tried it with Delitracker, and although it produces a nice stream of continuous audio, the quality was quite bad, witch is sadly due to Delitracker. Why on earth does Delitracker only use the 14bit genie when you turn on mixing? It only reduces the quality level. 14Bit replay is DMA, and doesn't need mixing.

As for your optimizing effort, top notch I tried the same high quality mp3 with Hippoplayer (quality 0, frequency devision 2) in 14 bit, and it sounded fantastic. Now you know the audio isn't continuous, of course, some of the buffer is replayed, but... the replay length is short, much better than the original.

I think that it may be possible to actually get this to work properly. In fact, seeing how dreadful the quality is with Delitracker, why not take shortcuts such as the ones I proposed for your jpeg decoder? In this case, the audio will still sound much better than with Deli, so throwing some quality away won't really matter. Can't hurt to try.
Quote:
Originally Posted by meynaf View Post
As I said, only problem is to actually call the library to do the job.
Then do it in the way I proposed earlier. Really easy to write then, and if it doesn't work properly, you haven't wasted much time. Give it a shot.
Quote:
Originally Posted by meynaf View Post
I have one mp2 (coming from Aminet), so what ? Should I really remove functionalities off the lib and delete it ?
In my opinion, yes. No one uses mp1 and mp2, in fact, do mp3 players even support it? Unlikely, so just get rid of it, it's a waste of time.
Quote:
Originally Posted by meynaf View Post
So it is.
But now that I think about it, using an external program would perhaps add some quite random I/O time and lose accuracy. Unsure, though.
Do it in the ram disk. Further more, if you're willing to wait 30 seconds to decode a short piece of audio to ram, then it probably won't matter much. Just try it before you take the complex route.
Quote:
Originally Posted by meynaf View Post
C'mon, kill a few seconds of decoding for me...
If you agree that taking decoding short cuts might work, then sure, if not, you're going to have to wait until I see something, this is code is quite tough.
Quote:
Originally Posted by meynaf View Post
Good luck, pal. You'll need it.
Thanks, I know
Quote:
Originally Posted by meynaf View Post
If it's too simple for you, you can still reschedule things for dual execute... should be fun too.
It's just simple in cases where you need multiple instructions to do a mul, there you can just use a mul on '060, as far as I know.
Quote:
Originally Posted by meynaf View Post
But now I see nothing left to do...
Then it's time to squeeze your brain more Start by using Hippo in 14 bit (not with ahi, of course), and use the settings I wrote above. Try to sacrifice quality in the decoding process, while keeping the audio quality better than what Deli gives us.
Quote:
Originally Posted by meynaf View Post
For 3 blocks adda.l a6,a4 can be removed because A4 is not used, so don't care about them, it's a known thing. But that's neglectable...
Didn't spot it. Anyway, if it's executed in a loop, directly, or indirectly, it has to go. All instructions that don't have to be there should be removed.
Quote:
Originally Posted by meynaf View Post
So if mpega.library can sound good enough, have you tried the version in my archive, with its default settings ?
When I decoded some good quality mp3s to wav in the highest quality settings, the audio sounded fantastic. As said, I've tried your version with the Delitracker you supplied, and Deli made it sound bloody awefull. It sounds great with Hippo, and I'm sure it sounds just as good as the original when using the highest settings. It's not your version that's the problem, its Delitracker. Get a better player, meynaf

Last edited by Thorham; 27 May 2009 at 20:27. Reason: Many big 'typos'.
Thorham is offline  
Old 27 May 2009, 22:58   #124
antonvaltaz
Registered User
 
antonvaltaz's Avatar
 
Join Date: May 2009
Location: Oxford, UK
Age: 43
Posts: 511
edit: sorry, using a mobile and got mixed up between 'search' and 'new entry' sections.

Feel very stupid now!
antonvaltaz is offline  
Old 28 May 2009, 02:29   #125
Thorham
Computer Nerd
 
Thorham's Avatar
 
Join Date: Sep 2007
Location: Rotterdam/Netherlands
Age: 47
Posts: 3,751
Quote:
Originally Posted by antonvaltaz View Post
edit: sorry, using a mobile and got mixed up between 'search' and 'new entry' sections.

Feel very stupid now!
Don't worry about, mate

Small update:

Meynaf, I've tried messing around with the quality. My first attempt was in the subb_w.s file, and this went pear shaped very quickly

My second attempt was quite the opposite. I tried replacing constants in the mdct part, and guess what, very little difference. I went quite far, rounding constants to the nearest multiple of of $1000. I did it for the first four in the code, and I replaced a whole block of them (one of the blocks with the increadible code ). Worked like a charm, so I went ahead and optimized them to two shifts and a small number of subs and adds. You've got to see and hear this to believe it I'll post the first bunch of optimizations later today. It's late (2:20 am), and I'm going to bed in a few minutes.

But don't wait for it, and try replacing some constants whith some rounded ones, and hear it for yourself. Perhaps it's an idea to make an extra version that uses this slightly reduced quality, but let's just see (or should I say hear ) how far this can be stretched.

It's quite amazing how much you can play with those constants. I guess those dcts are lossy, and you can actually play with this lossyness, without actually affecting the amount that is lost too much, just like with jpeg. Funny
Thorham is offline  
Old 28 May 2009, 10:06   #126
Thorham
Computer Nerd
 
Thorham's Avatar
 
Join Date: Sep 2007
Location: Rotterdam/Netherlands
Age: 47
Posts: 3,751
Second update:

First, here is some simple stuff from the start of subb_w.s that can be optimized without loss of quality:
Code:
    move.w	d2,d5
    sub.w	d3,d5
    movea.l	d5,a5
    add.l	a5,a5

; move.w d2,d5
; sub.w d3,d5
; ext.l d5
; add.l d5,d5
; movea.l d5,a5			; a5=addy src1 (a3)

    move.w	d2,d5
    sub.w	d4,d5
    movea.l	d5,a6
    add.l	a6,a6

; move.w d2,d5
; sub.w d4,d5
; ext.l d5
; add.l d5,d5
; movea.l d5,a6			; a6=addy src2 (a4)

    move.w	2(sp),d3
    sub.w	d3,d2
    ext.l	d2
    add.l	d2,d2

; sub.w 2(a7),d2			; d2 empilé
; ext.l d2
; add.l d2,d2			; d2, c'est ce qu'on ajoute à a2
; move.w 2(a7),d3		; d2 empilé
Next, some lossy optimizations from mdct_l.s.

This code is from the beginning of mdct:
Code:
    moveq	#13,d1

    move.w	$1a(a0),a4
    move.l	a4,d2
    lsl.l	d1,d2
    move.l	d2,d0
    add.l	d2,d2

    move.w	8(a0),a4
    move.l	a4,d3
    lsl.l	d1,d3
    move.l	d3,d1
    add.l	d3,d3

    add.l	d3,d0
    sub.l	d2,d1
It replaces:
Code:
 move.w $1a(a0),d2
 move.w 8(a0),d3
 move.w d2,d0
 move.w d3,d1
 muls #$187e,d0
 muls #$187e,d1
 muls #$3b21,d2
 muls #$3b21,d3
 add.l d3,d0
 sub.l d2,d1
And this from block 1/12:
Code:
    move.w	(a0),d0
    beq.s	.rien0

    ext.l	d0
    lsl.l	#8,d0	;$100

    move.l	d0,d7
    add.l	d7,d7
    add.l	d0,d7	;$300

    add.l	d7,a6
    sub.l	d7,d3

    lsl.l	#4,d0	;$1000
    move.l	d0,d7
    add.l	d7,d7	;$2000
;$1000
    add.l	d0,a5
    sub.l	d0,d4
;$1000
    add.l	d0,a4
    sub.l	d0,d5
;$2000
    add.l	d7,a3
    sub.l	d7,a2
;$2000
    add.l	d7,a1
    sub.l	d7,a2

    add.l	d0,d7   ;$3000
;$3000
    sub.l	d7,d1
    sub.l	d7,d4
;$3000
    sub.l	d7,d2
    sub.l	d7,d3
;$3000
    add.l	d7,d6
    sub.l	d7,d5
.rien0
Witch replaces:
Code:
; bloc 1/12
 ifeq mul8
 move.w (a0),d0			; 0(a0)
 beq.s .rien0			; il y en a donc ça vaut le coup
 move.w d0,d7
 muls #$2f30,d7
 sub.l d7,d1
 sub.l d7,d4			; -2f30
 move.w d0,d7
 muls #$35fa,d7
 sub.l d7,d2
 sub.l d7,d3			; -35fa
 move.w d0,d7
 muls #$2cb,d7
 add.l d7,a6
 sub.l d7,d3			; -35fa -2cb -> -38c5
 move.w d0,d7
 muls #$dda,d7
 add.l d7,a5
 sub.l d7,d4			; -2f30 -dda -> -3d0a
 move.w d0,d7
 muls #$1d8d,d7
 add.l d7,a3
 sub.l d7,a2			; -1d8d
 move.w d0,d7
 muls #$133f,d7
 add.l d7,a4
 sub.l d7,d5			; -133f
 move.w d0,d7
 muls #$2263,d7
 add.l d7,a1
 sub.l d7,a2			; -133f -2263 -> -3ff0
 move.w d0,d7
 muls #$2b3d,d7
 add.l d7,d6
 sub.l d7,d5			; -133f -2b3d -> -3e7c
Now go and try it, and tell me how it sounds. Also, don't worry about the lossyness of those oprimizations, they really sound much better than you think.

Last edited by Thorham; 28 May 2009 at 10:12.
Thorham is offline  
Old 30 May 2009, 09:26   #127
meynaf
son of 68k
 
meynaf's Avatar
 
Join Date: Nov 2007
Location: Lyon / France
Age: 51
Posts: 5,323
Quote:
Originally Posted by Thorham View Post
Second update:

First, here is some simple stuff from the start of subb_w.s that can be optimized without loss of quality:
This part can be reduced quite a lot, but it's not worth because it doesn't have a measurable impact on speed.

Quote:
Originally Posted by Thorham View Post
Next, some lossy optimizations from mdct_l.s.
Lossy ? Did I read lossy ?
Did you measure the decoding time it gets ?

Quote:
Originally Posted by Thorham View Post
Now go and try it, and tell me how it sounds. Also, don't worry about the lossyness of those oprimizations, they really sound much better than you think.
*ahem* Perhaps you need to know that the purpose of this optimization is actually to raise quality, not lower it.
If you want to be faster with lower quality, just select "medium" instead of "high" (and it will sound better than you think)
meynaf is offline  
Old 30 May 2009, 09:46   #128
meynaf
son of 68k
 
meynaf's Avatar
 
Join Date: Nov 2007
Location: Lyon / France
Age: 51
Posts: 5,323
Quote:
Originally Posted by Thorham View Post
Small update:

Meynaf, I've tried messing around with the quality. My first attempt was in the subb_w.s file, and this went pear shaped very quickly
*cough*

Quote:
Originally Posted by Thorham View Post
My second attempt was quite the opposite. I tried replacing constants in the mdct part, and guess what, very little difference. I went quite far, rounding constants to the nearest multiple of of $1000. I did it for the first four in the code, and I replaced a whole block of them (one of the blocks with the increadible code ). Worked like a charm, so I went ahead and optimized them to two shifts and a small number of subs and adds. You've got to see and hear this to believe it I'll post the first bunch of optimizations later today. It's late (2:20 am), and I'm going to bed in a few minutes.

But don't wait for it, and try replacing some constants whith some rounded ones, and hear it for yourself. Perhaps it's an idea to make an extra version that uses this slightly reduced quality, but let's just see (or should I say hear ) how far this can be stretched.

It's quite amazing how much you can play with those constants. I guess those dcts are lossy, and you can actually play with this lossyness, without actually affecting the amount that is lost too much, just like with jpeg. Funny
Funny, but dangerous. Many coefficients here are zero, and if you change constants there may seem to be no difference. And one day you'll check an MP3 with much higher values and get bogus sound.

Lossy things like that can be subject to quality settings, but they need to gain a lot of cpu power to be really acceptable. Is it the case here ?

Besides, they're not acceptable at all for high quality setting, and this is the ultimate goal.
meynaf is offline  
Old 30 May 2009, 14:35   #129
meynaf
son of 68k
 
meynaf's Avatar
 
Join Date: Nov 2007
Location: Lyon / France
Age: 51
Posts: 5,323
Quote:
Originally Posted by Thorham View Post
And it's so obvious that it get's looked over way to easily It also helps that I never use lea...
I find this strange. Even though there are insns that are not useful, lea isn't among them !

Quote:
Originally Posted by Thorham View Post
Great Can it be downloaded already? I really want look at this.
Well, it wasn't by the time you posted, but now it can (see attached file).

Quote:
Originally Posted by Thorham View Post
That's impressive, but with 240 gig of hd space not really needed
Of course, if you see things like that ;-)

Quote:
Originally Posted by Thorham View Post
Oh no, they use the cpu to read a register Man, that sucks. I thought the data was dmaed (new word) to chipmem. That would at least allow data that needs to be in chipmem to be transferred there directly. Pity
This is cheap solution. Using dma would require to add a new dma channel.
Also, HD back in 1992 weren't fast enough to push this system to its limits.

Quote:
Originally Posted by Thorham View Post
Of course, but it would probably be more expensive as well. Besides, such a fast 68k cpu wouldn't be much fun, no challenge
Not more expensive if it finally takes over like x86 did. Probably cheaper in fact, because of simpler architecture. You just need equal sales volume.

About the challenge, there can still be some. If it's not making it faster, could be making it smaller. Or make enormous computations (such as video encoding or world simulations) run faster

Quote:
Originally Posted by Thorham View Post
To me, trying is part of the fun.
I have some fun in store for you then

Quote:
Originally Posted by Thorham View Post
Okay, but does anyone actually use it? Everyone encodes music in mp3, ogg, etc these days. It would be a waste of time to optimize code that won't be used. It seems a lot better to get the mp3 part to be as fast as possible.
This is what I'm doing, actually. Other layers are a remote todo list

Quote:
Originally Posted by Thorham View Post
That depends on the coders commenting skills
I want to see yours then

Quote:
Originally Posted by Thorham View Post
Yes, but not everything. Having big blocks of code without spaces in between a few lines here and there makes it harder to read.
That depends on the coders reading skills

Quote:
Originally Posted by Thorham View Post
Perhaps, perhaps not. I don't write in C often, and as such my C coding style is probably less then optimal.
IMO the worse coding style is the most frequently used one...

Quote:
Originally Posted by Thorham View Post
And be much easier to read, I bet
Unsure. More lines in overall means less meaningful lines on actual view.

Quote:
Originally Posted by Thorham View Post
It's been 'fun' so far... Man, what a big one
Yeah, that sure is big, but there are bigger ones.

Quote:
Originally Posted by Thorham View Post
I tried the library itself. The problem was that I thought I had to reset to get the new library to work after testing the original, witch made me think that trying things would suck. D'oh. I had totally forgotten about flushlibs.

Anyway, since the problem is solved... I tried it with Delitracker, and although it produces a nice stream of continuous audio, the quality was quite bad, witch is sadly due to Delitracker. Why on earth does Delitracker only use the 14bit genie when you turn on mixing? It only reduces the quality level. 14Bit replay is DMA, and doesn't need mixing.
Don't turn on mixing, it's useless and just wastes time (and it won't use 14bit genie). Also don't use AHI, or quality will decrease (but then you deserved it) !

Quote:
Originally Posted by Thorham View Post
As for your optimizing effort, top notch I tried the same high quality mp3 with Hippoplayer (quality 0, frequency devision 2) in 14 bit, and it sounded fantastic. Now you know the audio isn't continuous, of course, some of the buffer is replayed, but... the replay length is short, much better than the original.

I think that it may be possible to actually get this to work properly. In fact, seeing how dreadful the quality is with Delitracker, why not take shortcuts such as the ones I proposed for your jpeg decoder? In this case, the audio will still sound much better than with Deli, so throwing some quality away won't really matter. Can't hurt to try.
If DT2 is dreadful on your machine, then there's something wrong with your setup...
Besides, if it's really dreadful, then it's not DT but its mpegaplayer plugin.

Or... Are you SURE it wasn't one of your lossy tests which got used ?
I forgot to tell you that doing a lib flush isn't enough : you must also eject the mpega player before ! (open the players window and click on "clear" to do this quickly)

Or... Are you playing something with settings just too high ? If so, it'll sound bad but it's just because there are small "holes" in the replay. If you check "mono" the quality will be normal. Playing with settings your cpu can't handle is looking for bad quality

Quote:
Originally Posted by Thorham View Post
Then do it in the way I proposed earlier. Really easy to write then, and if it doesn't work properly, you haven't wasted much time. Give it a shot.
You mean calling the external player ? Well, ok, but it's for when I have something new to test.

Quote:
Originally Posted by Thorham View Post
In my opinion, yes. No one uses mp1 and mp2, in fact, do mp3 players even support it? Unlikely, so just get rid of it, it's a waste of time.
For now I prefer to just leave them alone.

Quote:
Originally Posted by Thorham View Post
Do it in the ram disk. Further more, if you're willing to wait 30 seconds to decode a short piece of audio to ram, then it probably won't matter much. Just try it before you take the complex route.
It's worth trying (if I have something new to actually test), even though I prefer to have timings up to the frame even for 30 seconds...

Quote:
Originally Posted by Thorham View Post
If you agree that taking decoding short cuts might work, then sure, if not, you're going to have to wait until I see something, this is code is quite tough.
Such short cuts are for low, perhaps medium, qualities only. Not for high, and high is the goal.

Quote:
Originally Posted by Thorham View Post
It's just simple in cases where you need multiple instructions to do a mul, there you can just use a mul on '060, as far as I know.
Sometimes the mul just can't be avoided... and then you're happy when you have a 060 !

Quote:
Originally Posted by Thorham View Post
Then it's time to squeeze your brain more Start by using Hippo in 14 bit (not with ahi, of course), and use the settings I wrote above. Try to sacrifice quality in the decoding process, while keeping the audio quality better than what Deli gives us.
But Deli doesn't give worse quality than Hippo...

Quote:
Originally Posted by Thorham View Post
Didn't spot it. Anyway, if it's executed in a loop, directly, or indirectly, it has to go. All instructions that don't have to be there should be removed.
There aren't many now, apart in the not time critical parts.

Quote:
Originally Posted by Thorham View Post
When I decoded some good quality mp3s to wav in the highest quality settings, the audio sounded fantastic. As said, I've tried your version with the Delitracker you supplied, and Deli made it sound bloody awefull. It sounds great with Hippo, and I'm sure it sounds just as good as the original when using the highest settings. It's not your version that's the problem, its Delitracker.
Perhaps it's just that 14 bit calibration problem again. I have no trouble with DT.
Didn't you try DT after your lossy tests ? I suspect this version wasn't used by Hippo (perhaps it holds the lib permanently) but later used by DT !

Quote:
Originally Posted by Thorham View Post
Get a better player, meynaf
There are none.

Btw if you really think it's crap when playing MP3, I have resourced the player too. But it's not that. Quality on DT is same as decoded wave and if it's not the case for you there's something wrong and it's not DT itself.

Last edited by meynaf; 12 May 2011 at 08:32.
meynaf is offline  
Old 30 May 2009, 16:09   #130
Thorham
Computer Nerd
 
Thorham's Avatar
 
Join Date: Sep 2007
Location: Rotterdam/Netherlands
Age: 47
Posts: 3,751
Quote:
Originally Posted by meynaf View Post
This part can be reduced quite a lot, but it's not worth because it doesn't have a measurable impact on speed.
Yeah, sorry, I noticed that too late.
Quote:
Originally Posted by meynaf View Post
Lossy ? Did I read lossy ?
Did you measure the decoding time it gets ?
No, I didn't, I just wanted to know the effect of this lossy optimization. I'm also going to replace all of the multiply blocks with lossy optimizations too hear how it sounds. When that's done, and it's worth it, I'll take measurements.
Quote:
Originally Posted by meynaf View Post
*ahem* Perhaps you need to know that the purpose of this optimization is actually to raise quality, not lower it.
Didn't know that. In that case my lossy optims are pointless in a high quality version.
Quote:
Originally Posted by meynaf View Post
If you want to be faster with lower quality, just select "medium" instead of "high" (and it will sound better than you think)
I've tested with high in Deli, and it doesn't sound as good as the lossy optims+Hippo. Odd...
Quote:
Originally Posted by meynaf View Post
*cough*
Indeed
Quote:
Originally Posted by meynaf View Post
Funny, but dangerous. Many coefficients here are zero, and if you change constants there may seem to be no difference. And one day you'll check an MP3 with much higher values and get bogus sound.
Possible, but still worth trying in my opinion.
Quote:
Originally Posted by meynaf View Post
Lossy things like that can be subject to quality settings, but they need to gain a lot of cpu power to be really acceptable. Is it the case here ?
Depends. If all of those mul blocks can be made like the one I showed you, then it might actually save a nice amount of cpu time. Simply has to be tested.
Quote:
Originally Posted by meynaf View Post
Besides, they're not acceptable at all for high quality setting, and this is the ultimate goal.
Of course they aren't. I'm actually thinking about making those lossy optims an option that can be set in a config file, or something.
Quote:
Originally Posted by meynaf View Post
I find this strange. Even though there are insns that are not useful, lea isn't among them !
True, but I guess move takes care of everything. But I'm not doing that anymore. Time to use lea
Quote:
Originally Posted by meynaf View Post
Well, it wasn't by the time you posted, but now it can (see attached file).
Cool! I'll take a look and see if it's possible to do even more
Quote:
Originally Posted by meynaf View Post
Of course, if you see things like that ;-)
That's how I see it
Quote:
Originally Posted by meynaf View Post
This is cheap solution. Using dma would require to add a new dma channel.
Also, HD back in 1992 weren't fast enough to push this system to its limits.
It's cheap indeed. Dma is still better I this case, because the cpu doesn't have to read the data. Always better.
Quote:
Originally Posted by meynaf View Post
Not more expensive if it finally takes over like x86 did. Probably cheaper in fact, because of simpler architecture. You just need equal sales volume.
Okay, but then why are they using a more complex architecture if it doesn't make for a faster cpu?
Quote:
Originally Posted by meynaf View Post
About the challenge, there can still be some. If it's not making it faster, could be making it smaller. Or make enormous computations (such as video encoding or world simulations) run faster
Yes, but I personally like Amiga speeds, it makes more things challenging
Quote:
Originally Posted by meynaf View Post
I have some fun in store for you then/
Okay, show me then!
Quote:
Originally Posted by meynaf View Post
This is what I'm doing, actually. Other layers are a remote todo list/
Good, keep them there
Quote:
Originally Posted by meynaf View Post
I want to see yours then.
It depends on your ability to describe things in a clear and compact way.
Quote:
Originally Posted by meynaf View Post
That depends on the coders reading skills/
Not in my opinion
Quote:
Originally Posted by meynaf View Post
IMO the worse coding style is the most frequently used one...
Perhaps. I haven't seen a lot of C code, so I wouldn't know.
Quote:
Originally Posted by meynaf View Post
Unsure. More lines in overall means less meaningful lines on actual view.
Yes, but a routine is often made up out of smaller parts of multiple instructions. In my opinion these parts should be separated by blank lines, which I do a little bit too often, perhaps. The key is not over doing it.
Quote:
Originally Posted by meynaf View Post
Yeah, that sure is big, but there are bigger ones.
Like what?
Quote:
Originally Posted by meynaf View Post
Don't turn on mixing, it's useless and just wastes time (and it won't use 14bit genie). Also don't use AHI, or quality will decrease (but then you deserved it) !
Alright, but how do I get Deli to use the 14 bit genie?
Quote:
Originally Posted by meynaf View Post
If DT2 is dreadful on your machine, then there's something wrong with your setup...
Besides, if it's really dreadful, then it's not DT but its mpegaplayer plugin.
Well, besides not using the 14 bit genie, it's actually your quality settings that don't sound to hot.
Quote:
Originally Posted by meynaf View Post
Or... Are you SURE it wasn't one of your lossy tests which got used ?
Absolutely. Also, I've been using Hippo all the time after getting really annoyed with Deli. I tried Deli out of the box, just the way you supplied it. And like I said, the lossy optims sound fine in Hippo.
Quote:
Originally Posted by meynaf View Post
I forgot to tell you that doing a lib flush isn't enough : you must also eject the mpega player before ! (open the players window and click on "clear" to do this quickly)
Right. I thought you had to restart the program for this .
Quote:
Originally Posted by meynaf View Post
Or... Are you playing something with settings just too high ? If so, it'll sound bad but it's just because there are small "holes" in the replay. If you check "mono" the quality will be normal. Playing with settings your cpu can't handle is looking for bad quality/
That's not what I mean with bad quality. What I mean is AM radio like quality. Not that that dreadful, but it's going in that direction.
Quote:
Originally Posted by meynaf View Post
It's worth trying (if I have something new to actually test), even though I prefer to have timings up to the frame even for 30 seconds...
Can't say I disagree here.
Quote:
Originally Posted by meynaf View Post
Such short cuts are for low, perhaps medium, qualities only. Not for high, and high is the goal.
High is going to be tough, mate, good luck. Perhaps a separate lossy version?
Quote:
Originally Posted by meynaf View Post
Sometimes the mul just can't be avoided... and then you're happy when you have a 060 !
Indeed.
Quote:
Originally Posted by meynaf View Post
But Deli doesn't give worse quality than Hippo...
Odd, guess I'll try again.
Quote:
Originally Posted by meynaf View Post
There aren't many now, apart in the not time critical parts.
Okay, I guess they can stay in then.
Quote:
Originally Posted by meynaf View Post
Perhaps it's just that 14 bit calibration problem again. I have no trouble with DT.
To me Deli is a headache man. And it's not a calibration problem. Calibrated 14 bit sounds better than non calibrated, but non calibrated still sounds a million times better than 8 bit.
Quote:
Originally Posted by meynaf View Post
Didn't you try DT after your lossy tests ? I suspect this version wasn't used by Hippo (perhaps it holds the lib permanently) but later used by DT !
While I did try Deli with my lossy optims, I also tried it out of the box. Further more, Hippo doesn't hold the library, I know this because I have used the color macros in your source code, cycling through colors as I changed more things. A flush lib is enough.
Quote:
Originally Posted by meynaf View Post
There are none.
Sad
Quote:
Originally Posted by meynaf View Post
Btw if you really think it's crap when playing MP3, I have resourced the player too. But it's not that. Quality on DT is same as decoded wave and if it's not the case for you there's something wrong and it's not DT itself.
Perhaps, maybe I'm just screwing up, maybe there is something else. I'll try to figure it out.
Thorham is offline  
Old 01 June 2009, 16:29   #131
meynaf
son of 68k
 
meynaf's Avatar
 
Join Date: Nov 2007
Location: Lyon / France
Age: 51
Posts: 5,323
Quote:
Originally Posted by Thorham View Post
Yeah, sorry, I noticed that too late.
But this part poses a problem anyway : it decides of which routine to call, and I don't know on which criteria ! (apart the 3 quality settings)

Quote:
Originally Posted by Thorham View Post
No, I didn't, I just wanted to know the effect of this lossy optimization. I'm also going to replace all of the multiply blocks with lossy optimizations too hear how it sounds. When that's done, and it's worth it, I'll take measurements.
Ok.

Quote:
Originally Posted by Thorham View Post
Didn't know that. In that case my lossy optims are pointless in a high quality version.
Yes. But it can be useful if we are able to reach medium quality, so don't drop it too fast.

Quote:
Originally Posted by Thorham View Post
I've tested with high in Deli, and it doesn't sound as good as the lossy optims+Hippo. Odd...
Please select "mono" if you try hi-q. Else you'll get something way too slow.

Quote:
Originally Posted by Thorham View Post
Possible, but still worth trying in my opinion.
Check with several very different MP3. I've already had bad surprises while doing so...

Quote:
Originally Posted by Thorham View Post
Depends. If all of those mul blocks can be made like the one I showed you, then it might actually save a nice amount of cpu time. Simply has to be tested.
So... test it
If you have a version that works OK for you, I can test it too, so just give it to me.

Quote:
Originally Posted by Thorham View Post
Of course they aren't. I'm actually thinking about making those lossy optims an option that can be set in a config file, or something.
It is difficult to add new config things because the library would become incompatible - or actual programs using it would never use the new stuff.
However it can be linked with the "low" and "medium" settings.

Quote:
Originally Posted by Thorham View Post
True, but I guess move takes care of everything. But I'm not doing that anymore. Time to use lea
Yeah, 68k's move is incredibly powerful. But it is true that there are quite a few useless instructions.

Quote:
Originally Posted by Thorham View Post
Cool! I'll take a look and see if it's possible to do even more
Beware : my tests have shown that loop must remain within 240 bytes.

Quote:
Originally Posted by Thorham View Post
It's cheap indeed. Dma is still better I this case, because the cpu doesn't have to read the data. Always better.
Anyway now it's too late to change that.

Quote:
Originally Posted by Thorham View Post
Okay, but then why are they using a more complex architecture if it doesn't make for a faster cpu?
Because they are forced to use it. Like everyone else.

Quote:
Originally Posted by Thorham View Post
Yes, but I personally like Amiga speeds, it makes more things challenging
Get an old 8-bit computer if you like challenges so much

Quote:
Originally Posted by Thorham View Post
Okay, show me then!
I have some sources for OGG that need to be ported to ASM. Interested ?

Quote:
Originally Posted by Thorham View Post
It depends on your ability to describe things in a clear and compact way.
That's what I think I do... for those who can understand them, of course

Quote:
Originally Posted by Thorham View Post
Not in my opinion
On second thought, it can be just a matter of habits. The closer the code is from your own way of making it, the more readable you'll find it.

Quote:
Originally Posted by Thorham View Post
Perhaps. I haven't seen a lot of C code, so I wouldn't know.
You haven't seen a lot of C code ? Ya are a lucky guy then

Quote:
Originally Posted by Thorham View Post
Yes, but a routine is often made up out of smaller parts of multiple instructions. In my opinion these parts should be separated by blank lines, which I do a little bit too often, perhaps. The key is not over doing it.
I prefer using blank lines for things which are not related to each other, and if things become a mess I'd prefer adding a comment.
But I admit I like things that are small and compact

Quote:
Originally Posted by Thorham View Post
Like what?
Disassemble a whole game and you'll see.

Quote:
Originally Posted by Thorham View Post
Alright, but how do I get Deli to use the 14 bit genie?
mpegaplayer will never use the 14 bit genie whatever you do. Why do you want this anyway ?

Quote:
Originally Posted by Thorham View Post
Well, besides not using the 14 bit genie, it's actually your quality settings that don't sound to hot.
It outputs in 14 bit, doesn't need the genie for that. I think there's nothing wrong with my quality settings ; could you provide me a screen grab showing them ? Perhaps I messed up the config files

Quote:
Originally Posted by Thorham View Post
Absolutely. Also, I've been using Hippo all the time after getting really annoyed with Deli. I tried Deli out of the box, just the way you supplied it. And like I said, the lossy optims sound fine in Hippo.
Strange thing, that is... Can you get a Snoopdos output for both of them, from the point you load the player to the point the file is playing ?

Quote:
Originally Posted by Thorham View Post
Right. I thought you had to restart the program for this .
Just eject player, flush libs, and reload player.

Quote:
Originally Posted by Thorham View Post
That's not what I mean with bad quality. What I mean is AM radio like quality. Not that that dreadful, but it's going in that direction.
I really want to know what's going on !
Is final playtime right ? Does activating the audio filter do any good ? (click on quotation mark icon, then "filter" check-box)

Quote:
Originally Posted by Thorham View Post
High is going to be tough, mate, good luck. Perhaps a separate lossy version?
Perhaps, yes.

Quote:
Originally Posted by Thorham View Post
Odd, guess I'll try again.
Which version of Hippo are you using, so I can check the exact same things ? Can I get the very same config file for it too ?

Quote:
Originally Posted by Thorham View Post
Okay, I guess they can stay in then.
They can, even though a little bit of clean-up wouldn't hurt.

Quote:
Originally Posted by Thorham View Post
To me Deli is a headache man. And it's not a calibration problem. Calibrated 14 bit sounds better than non calibrated, but non calibrated still sounds a million times better than 8 bit.

While I did try Deli with my lossy optims, I also tried it out of the box. Further more, Hippo doesn't hold the library, I know this because I have used the color macros in your source code, cycling through colors as I changed more things. A flush lib is enough.
Did you use colors with DT as well ?

Quote:
Originally Posted by Thorham View Post
Sad
Indeed.

Quote:
Originally Posted by Thorham View Post
Perhaps, maybe I'm just screwing up, maybe there is something else. I'll try to figure it out.
If things still go wrong, I can make a booby-trapped lib for you, to see the data path.
meynaf is offline  
Old 03 June 2009, 23:13   #132
Thorham
Computer Nerd
 
Thorham's Avatar
 
Join Date: Sep 2007
Location: Rotterdam/Netherlands
Age: 47
Posts: 3,751
Quote:
Originally Posted by meynaf View Post
But this part poses a problem anyway : it decides of which routine to call, and I don't know on which criteria ! (apart the 3 quality settings)
I haven't thought about that yet, but won't experiments reveal the best results? I've only looked over the code quickly, but I'll look at it more deeply.
Quote:
Originally Posted by meynaf View Post
Yes. But it can be useful if we are able to reach medium quality, so don't drop it too fast.
Don't worry, I'm not dropping them
Quote:
Originally Posted by meynaf View Post
Please select "mono" if you try hi-q. Else you'll get something way too slow.
Right, I forgot that, too. However, I don't like mono, and never use it. For the sake of running tests I think I can make an exception
Quote:
Originally Posted by meynaf View Post
Check with several very different MP3. I've already had bad surprises while doing so...
Haven't checked yet, but I'll certainly do so in the weekend, but I must admit that I don't have many. Would it help to encode some mp3s at different settings, or is it about the contents?
Quote:
Originally Posted by meynaf View Post
So... test it.
If you have a version that works OK for you, I can test it too, so just give it to me.
Then you'll have to wait a bit. I'll probably get back to it during the weekend, but I'm not promising a thing
Quote:
Originally Posted by meynaf View Post
It is difficult to add new config things because the library would become incompatible - or actual programs using it would never use the new stuff.
However it can be linked with the "low" and "medium" settings.
Actually, what I'm thinking of is a simple text file with the extended settings. Should work with everything. It might be better to simply make two versions.
Quote:
Originally Posted by meynaf View Post
Yeah, 68k's move is incredibly powerful. But it is true that there are quite a few useless instructions.
Witch ones?
Quote:
Originally Posted by meynaf View Post
Beware : my tests have shown that loop must remain within 240 bytes.
Maybe it's time to align the code to 256 bytes so the cache handles it properly. If you do, that's eight extra instructions.
Quote:
Originally Posted by meynaf View Post
Anyway now it's too late to change that.
Indeed Makes me wish I had a scsi expansion for my Blizzard
Quote:
Originally Posted by meynaf View Post
Because they are forced to use it. Like everyone else.
By whom? Microsucks? If so, then perhaps it's an idea to drop a big bomb on all the M$ offices, etc, problem solved Anyway, in the future all that shite will be dropped anyway. No one is going to stick to a pile of poo for ever.
Quote:
Originally Posted by meynaf View Post
Get an old 8-bit computer if you like challenges so much.
Oh noes, 8bit assembler sucks. I know, because I used to code on the C64. I'm never ever going back there. IA32 is probably more fun
Quote:
Originally Posted by meynaf View Post
I have some sources for OGG that need to be ported to ASM. Interested ?
It sounds cool, but I'm not getting into any new projects. Getting into too many used to be one of my bad habits, and it's not happening again. Let's first work on the mpeg library
Quote:
Originally Posted by meynaf View Post
That's what I think I do... for those who can understand them, of course.
Your comments look fine, it's just that they're in French, that's all. Makes me wish I took it more seriously in high school
Quote:
Originally Posted by meynaf View Post
On second thought, it can be just a matter of habits. The closer the code is from your own way of making it, the more readable you'll find it.
You're absolutely right. It's all quite subjective.
Quote:
Originally Posted by meynaf View Post
You haven't seen a lot of C code ? Ya are a lucky guy then/
I know
Quote:
Originally Posted by meynaf View Post
I prefer using blank lines for things which are not related to each other, and if things become a mess I'd prefer adding a comment.
But I admit I like things that are small and compact/
Hmm, I like them more spaced out
Quote:
Originally Posted by meynaf View Post
Disassemble a whole game and you'll see.
Hehe, I don't think so, mate, not this guy.
Quote:
Originally Posted by meynaf View Post
mpegaplayer will never use the 14 bit genie whatever you do. Why do you want this anyway ?
Well, Delitracker doesn't seem to output in 14 bit by default, so I thought the genie was needed. If not, what is it for then?
Quote:
Originally Posted by meynaf View Post
It outputs in 14 bit, doesn't need the genie for that.
Doesn't sound like it, though. Odd.
Quote:
Originally Posted by meynaf View Post
I think there's nothing wrong with my quality settings ; could you provide me a screen grab showing them ? Perhaps I messed up the config files.
I could, but I know them. Everything is set to low quality, and all the frequencies are set to 20000, and the player is set to mono. Don't need a grab for that
Quote:
Originally Posted by meynaf View Post
Strange thing, that is... Can you get a Snoopdos output for both of them, from the point you load the player to the point the file is playing ?
What I actually meant is that the lossy optims sound the same as the library you supplied in the archive. Furthermore, I don't need snoopdos for this. What I did was simple: Each time I changed something, I also changed the test colors used, and this has worked each time. Trust me, I'm not doing it wrong
Quote:
Originally Posted by meynaf View Post
Just eject player, flush libs, and reload player.
Right. I'm still sticking to Hippo for now, though. Easier to use for this. And I'm making a script as well. It will assemble the library, copy it to hd0:libs/ and flush the library. Then all I have to do is splay an mp3.
Quote:
Originally Posted by meynaf View Post
I really want to know what's going on !
Is final playtime right ? Does activating the audio filter do any good ? (click on quotation mark icon, then "filter" check-box)
I never ever use that awful filter, it's useless to me because it makes things sound worse, please don't ask me to go there

As for what's going on, it's simple, I'm using a full stereo set with old kef speakers, and you're using your 1084S' internal speakers. On a stereo system you can't get away with as much as on those internal speakers, and it's something you really have to take in account when doing audio work. Your settings probably sound fine on your 1084S, but not on my system (again, not very advanced and the kefs tweeters are blow, so I'm using cheap Aiwa satellites for high freqs).
Quote:
Originally Posted by meynaf View Post
Perhaps, yes.
Why not? It's not much work. I'll see if I can get it done during the weekend, but as said, I'm not promising anything.
Quote:
Originally Posted by meynaf View Post
Which version of Hippo are you using, so I can check the exact same things ? Can I get the very same config file for it too ?
The one currently on Aminet: Hippoplayer 2.45

As for the settings, I have an Idefix problem, witch means I can't transfer the file right now (I have to burn the file to cd, and I don't feel like fixing it now, either, sorry ), so here goes: Just set mpeg quality to 0 and the frequency divider to 2 and don't forget to set the program to use calibration, and use double buffering. As far as I know, that's it. Probably not important, but I use a 128kb sample buffer.
Quote:
Originally Posted by meynaf View Post
Did you use colors with DT as well ?
Yes, as said I changed the colors each time I changed something in the source code.
Quote:
Originally Posted by meynaf View Post
If things still go wrong, I can make a booby-trapped lib for you, to see the data path.
I'll test again, but it's probably due to the fact that your settings are based on the 1084S speakers, and not a stereo system witch is really needed.

Last edited by Thorham; 03 June 2009 at 23:22.
Thorham is offline  
Old 05 June 2009, 19:28   #133
meynaf
son of 68k
 
meynaf's Avatar
 
Join Date: Nov 2007
Location: Lyon / France
Age: 51
Posts: 5,323
Quote:
Originally Posted by Thorham View Post
I haven't thought about that yet, but won't experiments reveal the best results? I've only looked over the code quickly, but I'll look at it more deeply.
What can experiments reveal ? There are 16 routines for high, 8 for medium, 4 for low and I don't know why one is taken at a given call. And if you take the wrong one, output will certainly be wrong too.

Quote:
Originally Posted by Thorham View Post
Don't worry, I'm not dropping them
I just said "not too fast"

Quote:
Originally Posted by Thorham View Post
Right, I forgot that, too. However, I don't like mono, and never use it. For the sake of running tests I think I can make an exception
It's necessary to reach realtime for now, unless you use a very low bitrate (such as 64kbps) and use low quality. But mono isn't that bad : the vast majority of mp3s have very little difference between left and right channels.

Quote:
Originally Posted by Thorham View Post
Haven't checked yet, but I'll certainly do so in the weekend, but I must admit that I don't have many. Would it help to encode some mp3s at different settings, or is it about the contents?
It's more about the contents, even though high bitrates should be (a little bit) more sensitive than low ones and block types/stereo mode can change a few things too.
If you're short on mp3s, you can PM me to borrow a few ones. I have at least one where the difference between medium and high qualities can clearly be heard.

Quote:
Originally Posted by Thorham View Post
Then you'll have to wait a bit. I'll probably get back to it during the weekend, but I'm not promising a thing
But you told me that your "lossy" version sounded OK for you, so you have something already.

Quote:
Originally Posted by Thorham View Post
Actually, what I'm thinking of is a simple text file with the extended settings. Should work with everything. It might be better to simply make two versions.
I prefer the two versions idea ; it's the path to take for a start anyway.

Quote:
Originally Posted by Thorham View Post
Witch ones?
Not lea of course
It's things such as chk/chk2, trapv, rtr, cas/cas2, negx, nbcd, reset, move16.
If you have a good use for them then I really want to see it !

Quote:
Originally Posted by Thorham View Post
Maybe it's time to align the code to 256 bytes so the cache handles it properly. If you do, that's eight extra instructions.
Aligning to 256 bytes will do no good because cache lines are 16 bytes. I tried aligning to 16 bytes and it raises the value to 242. Wow. Not to mention I don't like aligning the code because it makes disassembled code unreadable (e.g. when debugging) and is, more often than not, a pure waste of space.

Quote:
Originally Posted by Thorham View Post
Indeed Makes me wish I had a scsi expansion for my Blizzard
Perhaps they can still be found e.g. on eBay or similar sites.

Quote:
Originally Posted by Thorham View Post
By whom? Microsucks? If so, then perhaps it's an idea to drop a big bomb on all the M$ offices, etc, problem solved
It's not M$. They're forced to use it too (but I like the bomb idea anyway)
In fact it's your fault (You have a PC at home, don't you ? There would have been no x86 everywhere if no-one to buy them !)

More seriously, it's simply because all existing software would no longer work on a non-x86 machine.

Quote:
Originally Posted by Thorham View Post
Anyway, in the future all that shite will be dropped anyway. No one is going to stick to a pile of poo for ever.
I wish this happens soon !!!
But will users who know nothing but their pile of poo want to change ?

Quote:
Originally Posted by Thorham View Post
Oh noes, 8bit assembler sucks. I know, because I used to code on the C64. I'm never ever going back there. IA32 is probably more fun
Or switch directly to IA64. PPC is rumoured to be quite funny too (if you like to puke).

Quote:
Originally Posted by Thorham View Post
It sounds cool, but I'm not getting into any new projects. Getting into too many used to be one of my bad habits, and it's not happening again. Let's first work on the mpeg library
I understand. Having too many projects means never finishing one. And the mpeg library is a good idea ;-)

Quote:
Originally Posted by Thorham View Post
Your comments look fine, it's just that they're in French, that's all. Makes me wish I took it more seriously in high school
It's never too late to learn. After all if you know English you also know 20,000 words of French or so. Shouldn't be very difficult

Because you can count on my laziness, as translated comments aren't automatic for me !

Quote:
Originally Posted by Thorham View Post
You're absolutely right. It's all quite subjective.
And my way is just too far from everyone else's

Quote:
Originally Posted by Thorham View Post
Hmm, I like them more spaced out
You can reformat as you read...

Quote:
Originally Posted by Thorham View Post
Hehe, I don't think so, mate, not this guy.
Oh yeah ? I wonder why

Quote:
Originally Posted by Thorham View Post
Well, Delitracker doesn't seem to output in 14 bit by default, so I thought the genie was needed. If not, what is it for then?
It's for trackers with more than 4 channels (or using frequencies higher than 28.8). For MP3 it would be a pure waste of CPU power (because of mixing), if not a loss of quality (because of frequency change).

Quote:
Originally Posted by Thorham View Post
Doesn't sound like it, though. Odd.
But it IS 14-bit even on your machine. Something else is wrong.

Quote:
Originally Posted by Thorham View Post
I could, but I know them. Everything is set to low quality, and all the frequencies are set to 20000, and the player is set to mono. Don't need a grab for that
Those are NOT the settings I gave out !
Now try setting the frequencies to 25000 like I did (not 20000), the quality to high, still mono, and tell me the result
And don't tell me you don't want to do that (like with filter). TRY IT !

Quote:
Originally Posted by Thorham View Post
What I actually meant is that the lossy optims sound the same as the library you supplied in the archive. Furthermore, I don't need snoopdos for this. What I did was simple: Each time I changed something, I also changed the test colors used, and this has worked each time. Trust me, I'm not doing it wrong
Ok, no need for snoopdos output anyway now.
But then why can't you give me that lossy version ?

Quote:
Originally Posted by Thorham View Post
Right. I'm still sticking to Hippo for now, though. Easier to use for this. And I'm making a script as well. It will assemble the library, copy it to hd0:libs/ and flush the library. Then all I have to do is play an mp3.
I do that in ram: without using libs: to store the library. It works if the lib is only there.

With DT you can use a script as well. You can even do this in ARexx, to command DT by script : even the mp3 loading would then be done automatically. I can help if you don't know how to do that.

Quote:
Originally Posted by Thorham View Post
I never ever use that awful filter, it's useless to me because it makes things sound worse, please don't ask me to go there
I'm sure it would have sounded better in our case anyway...

Quote:
Originally Posted by Thorham View Post
As for what's going on, it's simple, I'm using a full stereo set with old kef speakers, and you're using your 1084S' internal speakers. On a stereo system you can't get away with as much as on those internal speakers, and it's something you really have to take in account when doing audio work. Your settings probably sound fine on your 1084S, but not on my system (again, not very advanced and the kefs tweeters are blow, so I'm using cheap Aiwa satellites for high freqs).
First it is DT, then it's my monitor, eh ?
But no my friend, it's not that. Try setting frequency division to 4 in Hippo and compare with DT output. Can't you guess what's really going on then ?

Quote:
Originally Posted by Thorham View Post
Why not? It's not much work. I'll see if I can get it done during the weekend, but as said, I'm not promising anything.
That's something I already tried in the past. There are still quite a few "equ" directives at start of code to activate some lossy tests. But cpu gain wasn't enormous and I dropped the idea.

Quote:
Originally Posted by Thorham View Post
The one currently on Aminet: Hippoplayer 2.45
Ah, yes, that horror. I think I trashed it

So it has a better quality than DT, eh ? Perhaps it has different cpu use too ?

Quote:
Originally Posted by Thorham View Post
As for the settings, I have an Idefix problem, witch means I can't transfer the file right now (I have to burn the file to cd, and I don't feel like fixing it now, either, sorry )
Burn the files to CD ??? Can't you use CF cards instead ?

Quote:
Originally Posted by Thorham View Post
so here goes: Just set mpeg quality to 0 and the frequency divider to 2 and don't forget to set the program to use calibration, and use double buffering. As far as I know, that's it. Probably not important, but I use a 128kb sample buffer.
DT's mpega player is better than that simple double-buffering. It can store up to 10 pre-computed seconds of music, but it doesn't need the buffers to be full before starting. Also if you set freq div to 2, you won't play a 22 khz mp3 at full quality. DT will (with correct settings, of course).

Quote:
Originally Posted by Thorham View Post
Yes, as said I changed the colors each time I changed something in the source code.
Even if you put different colors at start of the three sfb_x routines in subb_f.s ?

Quote:
Originally Posted by Thorham View Post
I'll test again, but it's probably due to the fact that your settings are based on the 1084S speakers, and not a stereo system witch is really needed.
Nope. Definitely not.

But I don't need to check data path any longer. I know what happens now. I suppose you do too, or you will by the time of answering (at least you should know what to do to fix it).
meynaf is offline  
Old 08 June 2009, 13:42   #134
Thorham
Computer Nerd
 
Thorham's Avatar
 
Join Date: Sep 2007
Location: Rotterdam/Netherlands
Age: 47
Posts: 3,751
Quote:
Originally Posted by meynaf View Post
What can experiments reveal ? There are 16 routines for high, 8 for medium, 4 for low and I don't know why one is taken at a given call. And if you take the wrong one, output will certainly be wrong too.
All right, that's clear. As said I'll check it out.
Quote:
Originally Posted by meynaf View Post
It's necessary to reach realtime for now, unless you use a very low bitrate (such as 64kbps) and use low quality. But mono isn't that bad : the vast majority of mp3s have very little difference between left and right channels.
Okay, I'll test using mono then
Quote:
Originally Posted by meynaf View Post
It's more about the contents, even though high bitrates should be (a little bit) more sensitive than low ones and block types/stereo mode can change a few things too.
If you're short on mp3s, you can PM me to borrow a few ones. I have at least one where the difference between medium and high qualities can clearly be heard.
Yes, I think it's a good idea to send those to me. By the way, I only have high bit rate ones (highest rate).
Quote:
Originally Posted by meynaf View Post
But you told me that your "lossy" version sounded OK for you, so you have something already.
Yes, but I had only done what I showed you. What I meant was that I want to do a lot more similar optimizations to see how far it can be stretched. As for doing it in the weekend, I didn't have a lot of time, so I couldn't do much. This is the reason I didn't promise anything (I knew there was a good change I wouldn't have much time). However, I've taken this week off, so I have a lot of time this week.
Quote:
Originally Posted by meynaf View Post
I prefer the two versions idea ; it's the path to take for a start anyway.
So do I. It let's the user choose what they want easily.
Quote:
Originally Posted by meynaf View Post
Not lea of course.
It's things such as chk/chk2, trapv, rtr, cas/cas2, negx, nbcd, reset, move16.
If you have a good use for them then I really want to see it !
Well, I can certainly try to come up with something
Quote:
Originally Posted by meynaf View Post
Aligning to 256 bytes will do no good because cache lines are 16 bytes. I tried aligning to 16 bytes and it raises the value to 242. Wow. Not to mention I don't like aligning the code because it makes disassembled code unreadable (e.g. when debugging) and is, more often than not, a pure waste of space.
Odd, I thought 256 byte aligning enabled the use of the entire cache. Must be a brain glitch
Quote:
Originally Posted by meynaf View Post
Perhaps they can still be found e.g. on eBay or similar sites.
Yes, and probably for way to much cash Damn, I really want one.
Quote:
Originally Posted by meynaf View Post
It's not M$. They're forced to use it too (but I like the bomb idea anyway)
In fact it's your fault (You have a PC at home, don't you ? There would have been no x86 everywhere if no-one to buy them !)
Hey now, I didn't buy my peecee. The neighbor of a guy at work was going to throw the thing away, so the guy at work took the thing, and ended up giving it to me. Although I've spent money on the machine, I did not buy it
Quote:
Originally Posted by meynaf View Post
More seriously, it's simply because all existing software would no longer work on a non-x86 machine.
X86 is going to end one day, trust me. It makes no sense to stick to it for another 20 years.
Quote:
Originally Posted by meynaf View Post
I wish this happens soon !!!
But will users who know nothing but their pile of poo want to change ?
If it benefits them they might.
Quote:
Originally Posted by meynaf View Post
Or switch directly to IA64. PPC is rumoured to be quite funny too (if you like to puke).
Risc is probably not much fun to code in by hand, but I have no experience with that.
Quote:
Originally Posted by meynaf View Post
I understand. Having too many projects means never finishing one. And the mpeg library is a good idea ;-)
Indeed.
Quote:
Originally Posted by meynaf View Post
It's never too late to learn. After all if you know English you also know 20,000 words of French or so. Shouldn't be very difficult/
French is practically around the corner, so no, it's not that hard.
Quote:
Originally Posted by meynaf View Post
Because you can count on my laziness, as translated comments aren't automatic for me !
I only comment in English. Always have, always will, while Dutch is really my first language.
Quote:
Originally Posted by meynaf View Post
And my way is just too far from everyone else's.
Perhaps.
Quote:
Originally Posted by meynaf View Post
You can reformat as you read...
Yeah, I do that anyway.
Quote:
Originally Posted by meynaf View Post
It's for trackers with more than 4 channels (or using frequencies higher than 28.8). For MP3 it would be a pure waste of CPU power (because of mixing), if not a loss of quality (because of frequency change).
I see now.
Quote:
Originally Posted by meynaf View Post
But it IS 14-bit even on your machine. Something else is wrong.
Yes, you're right...
Quote:
Originally Posted by meynaf View Post
Those are NOT the settings I gave out !
Now try setting the frequencies to 25000 like I did (not 20000), the quality to high, still mono, and tell me the result
And don't tell me you don't want to do that (like with filter). TRY IT !
...25000 is indeed what you set the config to. It works now, and, of course, it sounded much better. Finally
Quote:
Originally Posted by meynaf View Post
Ok, no need for snoopdos output anyway now.
But then why can't you give me that lossy version ?
Because it's not finished. As said, there were only the optimizations I've showed you. I've done a few more last weekend (not much) and I'll do more this week. Witch leads me to a question: Where on earth can I find the macro zmacro? I can't find it!
Quote:
Originally Posted by meynaf View Post
I do that in ram: without using libs: to store the library. It works if the lib is only there.
If libs: is assigned to ram:. Anyway, I made the script, and it works like a charm with Hippo: Make changes, run scripts, play mp3 in Hippo. That simple
Quote:
Originally Posted by meynaf View Post
With DT you can use a script as well. You can even do this in ARexx, to command DT by script : even the mp3 loading would then be done automatically. I can help if you don't know how to do that.
If this can all be automated, then I have just become interested in Delitracker. Please show me how it's done, or is it in the manual?
Quote:
Originally Posted by meynaf View Post
I'm sure it would have sounded better in our case anyway...
Not to me, because the filter chops off too many high frequencies, and to me that just sucks.
Quote:
Originally Posted by meynaf View Post
First it is DT, then it's my monitor, eh ?
But no my friend, it's not that. Try setting frequency division to 4 in Hippo and compare with DT output. Can't you guess what's really going on then ?
Hey man, I was just guessing Anyway it's all solved now.
Quote:
Originally Posted by meynaf View Post
That's something I already tried in the past. There are still quite a few "equ" directives at start of code to activate some lossy tests. But cpu gain wasn't enormous and I dropped the idea.
I'll just keep going at it.
Quote:
Originally Posted by meynaf View Post
Ah, yes, that horror. I think I trashed it.
Nooooo
Quote:
Originally Posted by meynaf View Post
So it has a better quality than DT, eh ? Perhaps it has different cpu use too ?
As said, it's solved. And I do think Hippo uses more cpu time
Quote:
Originally Posted by meynaf View Post
Burn the files to CD ??? Can't you use CF cards instead ?
No, I can't because I don't have CF cards Besides, I want a pcmcia network adapter. Much better for me.
Quote:
Originally Posted by meynaf View Post
DT's mpega player is better than that simple double-buffering. It can store up to 10 pre-computed seconds of music, but it doesn't need the buffers to be full before starting. Also if you set freq div to 2, you won't play a 22 khz mp3 at full quality. DT will (with correct settings, of course).
I'm starting to think that Deli is indeed better than Hippo
Quote:
Originally Posted by meynaf View Post
Even if you put different colors at start of the three sfb_x routines in subb_f.s ?
Yes, always, although at first I couldn't find the used code (for the used settings) in subb_f.s, when I tried to change things I did also use colors. And with the script I've made it's almost not needed anymore.
Quote:
Originally Posted by meynaf View Post
Nope. Definitely not.

But I don't need to check data path any longer. I know what happens now. I suppose you do too, or you will by the time of answering (at least you should know what to do to fix it).
You were right all a long. It's just that I've had three 1084s and I've always been amazed at how much better a stereo system sounds. Sorry mate
Thorham is offline  
Old 09 June 2009, 13:06   #135
meynaf
son of 68k
 
meynaf's Avatar
 
Join Date: Nov 2007
Location: Lyon / France
Age: 51
Posts: 5,323
Quote:
Originally Posted by Thorham View Post
All right, that's clear. As said I'll check it out.
Ok. Check, mate

Quote:
Originally Posted by Thorham View Post
Okay, I'll test using mono then
Sorry. Only a few stereo streams can be played realtime (and with quality set to low).

Quote:
Originally Posted by Thorham View Post
Yes, I think it's a good idea to send those to me. By the way, I only have high bit rate ones (highest rate).
Check your PM.

Quote:
Originally Posted by Thorham View Post
Yes, but I had only done what I showed you. What I meant was that I want to do a lot more similar optimizations to see how far it can be stretched. As for doing it in the weekend, I didn't have a lot of time, so I couldn't do much. This is the reason I didn't promise anything (I knew there was a good change I wouldn't have much time). However, I've taken this week off, so I have a lot of time this week.
Sounds good.

Quote:
Originally Posted by Thorham View Post
So do I. It let's the user choose what they want easily.
Indeed.

Quote:
Originally Posted by Thorham View Post
Well, I can certainly try to come up with something
A concrete case ?

Quote:
Originally Posted by Thorham View Post
Odd, I thought 256 byte aligning enabled the use of the entire cache. Must be a brain glitch
Maybe. Cache consists of 16 blocks of 16 bytes. I do not know its filling algorithm, cache-overrun timings are mysterious to me. But my tests have shown that if your loop is 240 consecutive bytes or less, it will always fit.

Quote:
Originally Posted by Thorham View Post
Yes, and probably for way to much cash Damn, I really want one.
A quick look won't cost...

Quote:
Originally Posted by Thorham View Post
Hey now, I didn't buy my peecee. The neighbor of a guy at work was going to throw the thing away, so the guy at work took the thing, and ended up giving it to me. Although I've spent money on the machine, I did not buy it
Yeah, sure. But it's going to the dark side anyway

Quote:
Originally Posted by Thorham View Post
X86 is going to end one day, trust me. It makes no sense to stick to it for another 20 years.
It makes no sense, apart making more money out of the unsatisfied users...

Quote:
Originally Posted by Thorham View Post
If it benefits them they might.
I hope I'll see that.

Quote:
Originally Posted by Thorham View Post
Risc is probably not much fun to code in by hand, but I have no experience with that.
Not much fun ? Yeah, it may even make you seriously consider the x86

Quote:
Originally Posted by Thorham View Post
French is practically around the corner, so no, it's not that hard.
Practically. You've already got some experience with my comments anyway :-)

Quote:
Originally Posted by Thorham View Post
I only comment in English. Always have, always will, while Dutch is really my first language.
One day I'll try to comment code in Elfish

Quote:
Originally Posted by Thorham View Post
...25000 is indeed what you set the config to. It works now, and, of course, it sounded much better. Finally
You've setup frequency division to 2 in Hippo. So if you play 44100Hz MP3 (and I bet you do) you'll end up with 22050.
Now you set up an unfair limit of 20000 in DT. So if you play 44.1 MP3 (you do, don't you ?) the player can't use 22050 (yes, 22050>20000 ) and it will switch the freq div to 4, leading to 11025 Hz. And that's really AM radio quality, as you said.
The frequency you give is a limit to compute the freq_div value. Ability to use arbitrary ratios would be overly complex, so only values 1,2,4 are supported.
If you play a 22050 MP3 (there are some), you can play it with freq_div=1, so specifying freq_div directly is not good. I put 25000, but writing 22222 or 28836 would make no difference (for 44100).

Quote:
Originally Posted by Thorham View Post
Because it's not finished. As said, there were only the optimizations I've showed you. I've done a few more last weekend (not much) and I'll do more this week. Witch leads me to a question: Where on earth can I find the macro zmacro? I can't find it!
There is no "zmacro"
If it's "zmac" you're looking for, then it is obsolete. It was my old "multiply-accumulate" macro. No longer used ; see if/endc pairs.

Quote:
Originally Posted by Thorham View Post
If libs: is assigned to ram:. Anyway, I made the script, and it works like a charm with Hippo: Make changes, run scripts, play mp3 in Hippo. That simple
libs: doesn't need to be assigned to ram:. It will work just because it's in the same dir as DT.

Quote:
Originally Posted by Thorham View Post
If this can all be automated, then I have just become interested in Delitracker. Please show me how it's done, or is it in the manual?
If you have a complete DT2 somewhere, then you have an "ARexx" dir showing you examples. I can help too if you have trouble, of course.

Quote:
Originally Posted by Thorham View Post
Not to me, because the filter chops off too many high frequencies, and to me that just sucks.
Yeah, but it would have sucked less than AM radio ;-)

Quote:
Originally Posted by Thorham View Post
Hey man, I was just guessing. Anyway it's all solved now.
It is.

Quote:
Originally Posted by Thorham View Post
I'll just keep going at it.
You're welcome.

Quote:
Originally Posted by Thorham View Post
Nooooo
The mere fact it can't be extended by custom players makes it unsuitable for me.

Quote:
Originally Posted by Thorham View Post
As said, it's solved. And I do think Hippo uses more cpu time
If playing at freq_div=2 where DT uses 4, then certainly

Quote:
Originally Posted by Thorham View Post
No, I can't because I don't have CF cards Besides, I want a pcmcia network adapter. Much better for me.
Cards with Prism2 chip, such as NetGear MA-401, work well. It's just too bad there is no free access point close to my home

Quote:
Originally Posted by Thorham View Post
I'm starting to think that Deli is indeed better than Hippo
Could be much better, but nothing else suits my needs.

Quote:
Originally Posted by Thorham View Post
Yes, always, although at first I couldn't find the used code (for the used settings) in subb_f.s, when I tried to change things I did also use colors. And with the script I've made it's almost not needed anymore.
Not needed anymore, unless you want to see how often something gets called.

Quote:
Originally Posted by Thorham View Post
You were right all a long. It's just that I've had three 1084s and I've always been amazed at how much better a stereo system sounds. Sorry mate
Now it's solved...
meynaf is offline  
Old 11 June 2009, 21:58   #136
Thorham
Computer Nerd
 
Thorham's Avatar
 
Join Date: Sep 2007
Location: Rotterdam/Netherlands
Age: 47
Posts: 3,751
Here is the partially completed mdct file: mdct_l.txt

It's partial because I have a feeling that if I lossy optimize more, that it's going to sound bad and I want your opinion about the sound quality first.

What I've done is (besides the two optims I've showed you earlier) lossy optimze the bunch of blocks between:
Code:
; on sort avec d0-d1 pour calcul suivant

; 2. valeurs 2,e,14,20
; on utilise le fait que 3b21=32c6+85b et 3f74=26f6+187e
and
Code:
; 4. phase d'écriture, pour nos 6 valeurs
; attn : il faut lire les valeurs (a3) avant de les réécrire !
 moveq #14,d6			; ça va durer tout le long
; si je déplace les asr ici, on ne peut plus pipeliner le dernier write
and I've replaced the first of the incredible code blocks. I had to figure out what the zmac macro did. Am I correct when I say that it just does this:
Code:
zmac macro
    muls.w  \1,\2
    add.l   \2,\3
 endm
if you change
Code:
 mc -z2263,z133f...
to
Code:
 mc #-$2263,#$133f...
or did I get it wrong? It seems to work just fine. I had to know, because those mc lines are the easiest reference.

Anyway, I checked your mp3s, and one of them does sound bloody awful in low quality, so I just did the tests in high quality. There seemed to be little difference between your original version, and my lossy version, but a second ear is always useful. As for the music styles, I just have to say that I've heard far worse, they're not half bad
Quote:
Originally Posted by meynaf View Post
Ok. Check, mate.
Nice pun I will, but first the mpeg library.
Quote:
Originally Posted by meynaf View Post
Sorry. Only a few stereo streams can be played realtime (and with quality set to low).
This is certainly something that may be a problem, because stereo music sounds better in stereo, it sound clearer. The channels are different, and adding them up can mask sounds.
Quote:
Originally Posted by meynaf View Post
Check your PM.
Got them, thanks. As said, the music isn't bad, but it's not my style, I mostly listen to different varieties of house music, so don't worry, I'll delete them when I don't need them anymore.
Quote:
Originally Posted by meynaf View Post
Sounds good.
You can say that again. No matter how good the hours are, a person needs a break sometimes
Quote:
Originally Posted by meynaf View Post
A concrete case ?
Don't know yet, haven't looked into it (yet).
Quote:
Originally Posted by meynaf View Post
Maybe. Cache consists of 16 blocks of 16 bytes. I do not know its filling algorithm, cache-overrun timings are mysterious to me. But my tests have shown that if your loop is 240 consecutive bytes or less, it will always fit.
Okay, but why not add an in-source option to toggle between aligning and debug compatibility? I'd test proper alignment if I were you, if it works (it should, shouldn't it?), then that's up to eight extra instructions that will fit in the cache. Perhaps 16 byte aligning will work as well, wastes less space.
Quote:
Originally Posted by meynaf View Post
A quick look won't cost...
You're right, of course. They're probably not that common, though, and that will drive the price up, because I'm not the only one who wants one. Anyway, it's just a luxury, a network card is more useful right now.
Quote:
Originally Posted by meynaf View Post
Yeah, sure. But it's going to the dark side anyway.
Yes, it is, but only because I want a new peecee to play games on
Quote:
Originally Posted by meynaf View Post
It makes no sense, apart making more money out of the unsatisfied users...
... and at a certain point they're going to understand that they're not getting what they could be getting.
Quote:
Originally Posted by meynaf View Post
I hope I'll see that.
So do I, but it will probably happen.
Quote:
Originally Posted by meynaf View Post
Not much fun ? Yeah, it may even make you seriously consider the x86
That bad, eh? I know it's a load/store kind of system, that's it. Reminds me of the old 8bit cpus... 68k just rules
Quote:
Originally Posted by meynaf View Post
Practically. You've already got some experience with my comments anyway :-)
True, and I almost understand them. If only my vocabulary was large enough...
Quote:
Originally Posted by meynaf View Post
One day I'll try to comment code in Elfish/

Quote:
Originally Posted by meynaf View Post
You've setup frequency division to 2 in Hippo. So if you play 44100Hz MP3 (and I bet you do) you'll end up with 22050.
Now you set up an unfair limit of 20000 in DT. So if you play 44.1 MP3 (you do, don't you ?) the player can't use 22050 (yes, 22050>20000) and it will switch the freq div to 4, leading to 11025 Hz. And that's really AM radio quality, as you said.

The frequency you give is a limit to compute the freq_div value. Ability to use arbitrary ratios would be overly complex, so only values 1,2,4 are supported.
If you play a 22050 MP3 (there are some), you can play it with freq_div=1, so specifying freq_div directly is not good. I put 25000, but writing 22222 or 28836 would make no difference (for 44100).
I already had Delitracker installed, so I guess it used the old settings The problem was solved, because I made a fresh system installation. After having some problems with idefix (powercomputing registration code, go figure ), and seeing how messy my system actually was (lot's of stuff I had copied to it without needing it), I thought, what the heck, why not make a very clean Workbench. Problem solved.

Silly handling of the frequency divider on Delitrackers part. Could've been done much better, because allowing the user to enter a frequency implies that this will be the output frequency.
Quote:
Originally Posted by meynaf View Post
libs: doesn't need to be assigned to ram:. It will work just because it's in the same dir as DT.
But I don't have DT in ram, it's on my hd, so I just have the script copy the assembled library to HD0:libs, works perfectly.
Quote:
Originally Posted by meynaf View Post
If you have a complete DT2 somewhere, then you have an "ARexx" dir showing you examples. I can help too if you have trouble, of course.
Haven't done it yet, because I'm still using HIP, and my script works perfectly.
Quote:
Originally Posted by meynaf View Post
Yeah, but it would have sucked less than AM radio ;-)
Could be so, but if it needs that awful filter, then it ain' good, man I just hate that filter
Quote:
Originally Posted by meynaf View Post
The mere fact it can't be extended by custom players makes it unsuitable for me.
Can't it? Isn't it open source these days? But I understand it would still suck, because of the player group file. Bad design choice.
Quote:
Originally Posted by meynaf View Post
Cards with Prism2 chip, such as NetGear MA-401, work well. It's just too bad there is no free access point close to my home.
I might just order a card from Amigakit. You'll get software, and support a great Amiga shop As for access, how much is broadband in France? You won't need the fastest package.
Quote:
Originally Posted by meynaf View Post
Could be much better, but nothing else suits my needs.
It probably is, but the gui just blows chunks. Grr
Thorham is offline  
Old 16 June 2009, 12:37   #137
meynaf
son of 68k
 
meynaf's Avatar
 
Join Date: Nov 2007
Location: Lyon / France
Age: 51
Posts: 5,323
Quote:
Originally Posted by Thorham View Post
Here is the partially completed mdct file
(...)
It's partial because I have a feeling that if I lossy optimize more, that it's going to sound bad and I want your opinion about the sound quality first.

What I've done is (besides the two optims I've showed you earlier) lossy optimze the bunch of blocks between:
(...)
and
(...)
and I've replaced the first of the incredible code blocks. I had to figure out what the zmac macro did. Am I correct when I say that it just does this:
(...)
or did I get it wrong? It seems to work just fine. I had to know, because those mc lines are the easiest reference.
Beware : those mc lines are wrong now because I changed the register usage afterwards !

As for the macro, you're right. But it was more complex than that, as some muls were done with shifts (I checked if the value was a known one, and then used the relevant code).

My opinion about quality is... errh... not that bad after all. The difference is slight, but hearable : it seems to perturbate frequency responses, as if some sort of weird multi-band filter was added.

I made a few tests and found a stream where the difference can be heard quite clearly. Apparently "pure" (few different freqs) sounds suffer the more.
Speedwise, it did 2:57 vs 3:04 on this 2:56 stereo stream (256kbps, low qual). I'll let you judge if it is worth or not.

Quote:
Originally Posted by Thorham View Post
Anyway, I checked your mp3s, and one of them does sound bloody awful in low quality, so I just did the tests in high quality. There seemed to be little difference between your original version, and my lossy version, but a second ear is always useful. As for the music styles, I just have to say that I've heard far worse, they're not half bad
I have another which sounds that awful in low quality. Still hearable in medium. As far as I advance in that project, I see the results depend more and more on the contents, rather than anything else. So I don't like lossy opts because they look like time bombs to me.

Quote:
Originally Posted by Thorham View Post
This is certainly something that may be a problem, because stereo music sounds better in stereo, it sound clearer. The channels are different, and adding them up can mask sounds.
They're not added up. You just have the left one. You can be but you apparently did not guess this by hearing

Quote:
Originally Posted by Thorham View Post
Got them, thanks. As said, the music isn't bad, but it's not my style, I mostly listen to different varieties of house music, so don't worry, I'll delete them when I don't need them anymore.
I don't like house music, so we probably have very different tastes

Quote:
Originally Posted by Thorham View Post
You can say that again. No matter how good the hours are, a person needs a break sometimes
Yeah, sure.

Quote:
Originally Posted by Thorham View Post
Don't know yet, haven't looked into it (yet).
You can also try to find a use for 020's callm/rtm. Good luck

Quote:
Originally Posted by Thorham View Post
Okay, but why not add an in-source option to toggle between aligning and debug compatibility? I'd test proper alignment if I were you, if it works (it should, shouldn't it?), then that's up to eight extra instructions that will fit in the cache. Perhaps 16 byte aligning will work as well, wastes less space.
I have tested code alignment long ago. And discovered that it was totally useless on a 030.

I've dropped the idea, so if you think you have time to waste with that, feel free to make your own tests ;-)

Quote:
Originally Posted by Thorham View Post
You're right, of course. They're probably not that common, though, and that will drive the price up, because I'm not the only one who wants one. Anyway, it's just a luxury, a network card is more useful right now.
What sort of network card ? Must be 16-bit pcmcia, or you cannot plug it in your A1200.

Quote:
Originally Posted by Thorham View Post
Yes, it is, but only because I want a new peecee to play games on
And back in the 80's IBM said the PC was "a serious machine", not designed at all for gaming

Quote:
Originally Posted by Thorham View Post
... and at a certain point they're going to understand that they're not getting what they could be getting.
But what can people get nowadays, apart the usual rubbish ?

Quote:
Originally Posted by Thorham View Post
So do I, but it will probably happen.
Maybe we'll all have long white beards when the day finally comes

Quote:
Originally Posted by Thorham View Post
That bad, eh? I know it's a load/store kind of system, that's it. Reminds me of the old 8bit cpus... 68k just rules
At least old 8bit cpus were good for learning asm...

Quote:
Originally Posted by Thorham View Post
True, and I almost understand them. If only my vocabulary was large enough...
If one particular comment poses problem to you, don't hesitate to ask.

Quote:
Originally Posted by Thorham View Post


Quote:
Originally Posted by Thorham View Post
I already had Delitracker installed, so I guess it used the old settings The problem was solved, because I made a fresh system installation. After having some problems with idefix (powercomputing registration code, go figure ), and seeing how messy my system actually was (lot's of stuff I had copied to it without needing it), I thought, what the heck, why not make a very clean Workbench. Problem solved.

Silly handling of the frequency divider on Delitrackers part. Could've been done much better, because allowing the user to enter a frequency implies that this will be the output frequency.
How could it have been done much better ?

If you think things should have been done otherwise, nothing prevents you from rewriting dt's mpeg audio player anyway. Could even gain more speed because it is quite messy.

Quote:
Originally Posted by Thorham View Post
But I don't have DT in ram, it's on my hd, so I just have the script copy the assembled library to HD0:libs, works perfectly.

Haven't done it yet, because I'm still using HIP, and my script works perfectly.
Well, I prefer using ram: whenever I can. After all, only Amiga makes it possible ;-)

Quote:
Originally Posted by Thorham View Post
Could be so, but if it needs that awful filter, then it ain' good, man I just hate that filter
Filter helps a lot with low replay frequencies, but if you just hate it then it's ok for me

Quote:
Originally Posted by Thorham View Post
Can't it? Isn't it open source these days? But I understand it would still suck, because of the player group file. Bad design choice.
Open source ? Maybe. But custom players is just one thing among many.
DT supports custom converters and decrunchers. Hip doesn't. DT has NotePlayer interface (just fill in a struct to play things, will use common mixing code when needed). Hip hasn't. Should I list more ?

Quote:
Originally Posted by Thorham View Post
I might just order a card from Amigakit. You'll get software, and support a great Amiga shop As for access, how much is broadband in France? You won't need the fastest package.
It't not very much but still more than what I pay now ;-)
As for Amigakit, my actual keyboard comes from them.

Quote:
Originally Posted by Thorham View Post
It probably is, but the gui just blows chunks. Grr
What's wrong with the gui ? I find it clear enough...
meynaf is offline  
Old 19 June 2009, 10:15   #138
Thorham
Computer Nerd
 
Thorham's Avatar
 
Join Date: Sep 2007
Location: Rotterdam/Netherlands
Age: 47
Posts: 3,751
Quote:
Originally Posted by meynaf View Post
Beware : those mc lines are wrong now because I changed the register usage afterwards !
Oh no I've used those mc lines for further optimizations, and the sound quality went down too fast Can I get the register order from the current code easily?
Quote:
Originally Posted by meynaf View Post
As for the macro, you're right. But it was more complex than that, as some muls were done with shifts (I checked if the value was a known one, and then used the relevant code).
Good, that's what I wanted to know. The rest of the macro is not needed, I just needed to know what mc and zmac did.
Quote:
Originally Posted by meynaf View Post
My opinion about quality is... errh... not that bad after all. The difference is slight, but hearable : it seems to perturbate frequency responses, as if some sort of weird multi-band filter was added.
Glad you think that However, the last block (2/12) is optimized wrongly because of register usage based on the mc line. It may make a difference, and than there is always the possibility of doing the lossy optims more precise, where something like $1500 gets rounded to $1800 instead of $1000, witch is the sort of thing thats happening now.
Quote:
Originally Posted by meynaf View Post
I made a few tests and found a stream where the difference can be heard quite clearly. Apparently "pure" (few different freqs) sounds suffer the more.
Speedwise, it did 2:57 vs 3:04 on this 2:56 stereo stream (256kbps, low qual). I'll let you judge if it is worth or not.
Ouch, that's not a lot Guess you were right about those tables Could you send me that particular mp3, I'd like to test it. I'll see what less rounding can do for the quality, it's only a few extra instructions.
Quote:
Originally Posted by meynaf View Post
I have another which sounds that awful in low quality. Still hearable in medium. As far as I advance in that project, I see the results depend more and more on the contents, rather than anything else. So I don't like lossy opts because they look like time bombs to me.
Doesn't sound too good. But if it works like that, then it works like that and there is little that can be done about it.
Quote:
Originally Posted by meynaf View Post
They're not added up. You just have the left one. You can be shocked but you apparently did not guess this by hearing.
No, I can't hear it, because I never listen to mp3s in mono It is a simple mistake, though. If they're added up, it would actually cost a bit more time than stereo. My bad
Quote:
Originally Posted by meynaf View Post
I don't like house music, so we probably have very different tastes.
Not if you like rock, classic, old jazz and/or synthesizer music. Don't tell me you don't like any of those
Quote:
Originally Posted by meynaf View Post
You can also try to find a use for 020's callm/rtm. Good luck.
Thank's, I'll see if I can come up with something, there has to be some good use for them, otherwise, why were they put into the instruction set?
Quote:
Originally Posted by meynaf View Post
I have tested code alignment long ago. And discovered that it was totally useless on a 030.

I've dropped the idea, so if you think you have time to waste with that, feel free to make your own tests ;-)
So does that mean the 256 bytes of instruction cache can't be used completely? If it's true, then that's really strange. As for wasting time testing this stuff, I think it will only take at most 20 minutes, I can waste that
Quote:
Originally Posted by meynaf View Post
What sort of network card ? Must be 16-bit pcmcia, or you cannot plug it in your A1200.
Pcmcia. As said, I'll probably get one from Amigakit.
Quote:
Originally Posted by meynaf View Post
And back in the 80's IBM said the PC was "a serious machine", not designed at all for gaming.
Hehe, back then those peecees were indeed only usable for serious software anyway. Todays peecees are fine for gaming. And the peecee platform has some good games, Starcraft, anyone? I would love to see that one on the Amiga, but it's probably not possible with a '030
Quote:
Originally Posted by meynaf View Post
But what can people get nowadays, apart the usual rubbish ?
As far as I know, nothing. The only option is build quality. There is a huge hole to be filled up in terms of software quality, though.
Quote:
Originally Posted by meynaf View Post
Maybe we'll all have long white beards when the day finally comes.
Man, I certainly don't hope so
Quote:
Originally Posted by meynaf View Post
At least old 8bit cpus were good for learning asm...
That's how I learned it, although I think 68000 is the best for beginners, because it's easy and powerful.
Quote:
Originally Posted by meynaf View Post
If one particular comment poses problem to you, don't hesitate to ask.
You got it
Quote:
Originally Posted by meynaf View Post
How could it have been done much better ?
Simple. As said, allowing the user to enter a frequency implies that that's the frequency used for playback, witch is not the case. Using three radio buttons would be much better:
Code:
+-Frequency divider-----+
|                       |
| (x) Full frequency    |
| ( ) Half frequency    |
| ( ) Quarter frequency |
|                       |
+-----------------------+
Quote:
Originally Posted by meynaf View Post
If you think things should have been done otherwise, nothing prevents you from rewriting dt's mpeg audio player anyway. Could even gain more speed because it is quite messy.
Okay, I'll definitely take a look. Source from Aminet?
Quote:
Originally Posted by meynaf View Post
Well, I prefer using ram: whenever I can. After all, only Amiga makes it possible ;-)
Not anymore I usually don't bother with ram, and just work on the hd.
Quote:
Originally Posted by meynaf View Post
Filter helps a lot with low replay frequencies, but if you just hate it then it's ok for me.
It's just that I've never heard it improve anything, that's why.
Quote:
Originally Posted by meynaf View Post
Open source ? Maybe. But custom players is just one thing among many.
DT supports custom converters and decrunchers. Hip doesn't. DT has NotePlayer interface (just fill in a struct to play things, will use common mixing code when needed). Hip hasn't. Should I list more ?
You don't have to, you've convinced me
Quote:
Originally Posted by meynaf View Post
It't not very much but still more than what I pay now ;-)
As for Amigakit, my actual keyboard comes from them.
Well, I certainly am not going to order keyboards from them, I have a ps2 interface. Now I can use any old ps2 keyboard out there.
Quote:
Originally Posted by meynaf View Post
What's wrong with the gui ? I find it clear enough...
It can be improved, that's all. Then again, many things can be improved in the world of software, can't they
Thorham is offline  
Old 22 June 2009, 11:15   #139
meynaf
son of 68k
 
meynaf's Avatar
 
Join Date: Nov 2007
Location: Lyon / France
Age: 51
Posts: 5,323
Quote:
Originally Posted by Thorham View Post
Oh no I've used those mc lines for further optimizations, and the sound quality went down too fast Can I get the register order from the current code easily?
Perhaps you can have a look to the comments. If it says a particular value has been reached, look at which dest register the insn accessed.
OR...
Extract a code part and trace it with 1 in read data and all other regs being 0, so you'll see final value in registers.
And be warned that the value is often negative !

Quote:
Originally Posted by Thorham View Post
Good, that's what I wanted to know. The rest of the macro is not needed, I just needed to know what mc and zmac did.
You know what they did, but please ignore them now. As I said, they're totally obsolete.

Quote:
Originally Posted by Thorham View Post
Glad you think that However, the last block (2/12) is optimized wrongly because of register usage based on the mc line. It may make a difference, and than there is always the possibility of doing the lossy optims more precise, where something like $1500 gets rounded to $1800 instead of $1000, witch is the sort of thing thats happening now.
Ok, let me know when you have something better.

Quote:
Originally Posted by Thorham View Post
Ouch, that's not a lot Guess you were right about those tables Could you send me that particular mp3, I'd like to test it. I'll see what less rounding can do for the quality, it's only a few extra instructions.
Ok. Get it from the same place you got the others (tmp/tstmp3.lzx), but remember : it's only an example.
Note that it needs to be played in stereo, as the part in which the difference is heard isn't there at all in mono

In the archive you'll also find another test file. Here the difference is less flagrant, but still there.
The one you wanted is tst1, the other is tst2.

Quote:
Originally Posted by Thorham View Post
Doesn't sound too good. But if it works like that, then it works like that and there is little that can be done about it.
It's probably better than to depend too much on bitrate because of very poor huffman decoder like with the original code ;-)

Quote:
Originally Posted by Thorham View Post
No, I can't hear it, because I never listen to mp3s in mono It is a simple mistake, though. If they're added up, it would actually cost a bit more time than stereo. My bad
No, it wouldn't cost more time than stereo because frequencies would be added, not samples. And the toughest part is to convert frequencies into samples !

In fact it's not even sure it would always cost more time than actual mono, because of joint stereo. I have tried to mix them up but it failed (sometimes worked like charm, sometimes gave horrors).
Anyway, what I'm sure is that if I could successfully make that mixing to work, high quality would be already there.

Quote:
Originally Posted by Thorham View Post
Not if you like rock, classic, old jazz and/or synthesizer music. Don't tell me you don't like any of those
rock : a few
classic : sometimes yes, sometimes no (but I can't imagine you listening classic music ?!)
old jazz : nope
synthesizer music : usually

I can say I like sweet feminine voices (wonder why ), and computer game music (mostly, but not only, Amiga soundtrackers).

Quote:
Originally Posted by Thorham View Post
Thank's, I'll see if I can come up with something, there has to be some good use for them, otherwise, why were they put into the instruction set?
You put a feature somewhere because you think it can be good. And sometimes you later discover it wasn't but it's too late

x86 is full of things that "may be used" but never will.

If there is some good use for the insns I told you about... then I really need to know it !
(apart in cpu type checking and copy protection routines, I don't see...)

Quote:
Originally Posted by Thorham View Post
So does that mean the 256 bytes of instruction cache can't be used completely? If it's true, then that's really strange. As for wasting time testing this stuff, I think it will only take at most 20 minutes, I can waste that
Nope, it doesn't really mean that. But how can the cache filling electronics guess that your dbf will happen soon and the loop will still be valid, before it decides to start reading what's behind ? (some cpus with branch prediction could do that, but they have much larger caches and it wouldn't be worth)
So just before the end of your loop the cpu starts to fetch code for after it. And it reduces your maximum loop size by one cache line (16 bytes). Easy ?

This is my interpretation. Of course, if you have time to waste, do it

Quote:
Originally Posted by Thorham View Post
Pcmcia. As said, I'll probably get one from Amigakit.
You'd better. Not all pc cards will work but Amigakit knows better.

Quote:
Originally Posted by Thorham View Post
Hehe, back then those peecees were indeed only usable for serious software anyway. Todays peecees are fine for gaming. And the peecee platform has some good games, Starcraft, anyone?
Their basic structure didn't change, so if they weren't good, they're still not. They compensate by raw computing power.

Of course there are good games on them, but it's only because when a good game is released, it has absolutely no choice but to run on those stupid pcs !
You can't imagine how a game such as Starcraft was a pain in the ass for its authors to make.

Quote:
Originally Posted by Thorham View Post
I would love to see that one on the Amiga, but it's probably not possible with a '030
Unsure it's not possible on a 030. The trick is actually to disassemble and fully understand that damn x86 code. I have a copy of Broodwars somewhere on my HD, so if you want you can try

Quote:
Originally Posted by Thorham View Post
As far as I know, nothing. The only option is build quality. There is a huge hole to be filled up in terms of software quality, though.
... and don't expect this hole to be filled with x86.

Quote:
Originally Posted by Thorham View Post
Man, I certainly don't hope so
As long as money rules the world, nothing will come...

Quote:
Originally Posted by Thorham View Post
That's how I learned it, although I think 68000 is the best for beginners, because it's easy and powerful.
68000 is perhaps too powerful for beginners. Anyway, once you've learnt it, you can't go back !

Quote:
Originally Posted by Thorham View Post
Simple. As said, allowing the user to enter a frequency implies that that's the frequency used for playback, witch is not the case. Using three radio buttons would be much better
No way ! I don't want to play 22 khz mp3 in half freq !

If I say 25, then 22 is under -> full freq.
But 44 is higher -> half freq.
And I do not want to change settings all the time, so no, this is no good solution.

But you don't have mpeg2 streams don't you ? Go to Aminet to find an example :
http://aminet.net/package/mods/mpg/fangorn

Quote:
Originally Posted by Thorham View Post
Okay, I'll definitely take a look. Source from Aminet?
No original source, sorry. I re-sourced it (see in my actual tstmp3 archive).
But you can write one from scratch if re-sourced code isn't good for you.

Quote:
Originally Posted by Thorham View Post
Not anymore I usually don't bother with ram, and just work on the hd.
HD is mass storage, not temporary storage, but how to explain this to a pc user ?!

Quote:
Originally Posted by Thorham View Post
It's just that I've never heard it improve anything, that's why.
Then you've never heard anything under 12 khz, for sure !

Quote:
Originally Posted by Thorham View Post
You don't have to, you've convinced me
I find this surprising

Quote:
Originally Posted by Thorham View Post
Well, I certainly am not going to order keyboards from them, I have a ps2 interface. Now I can use any old ps2 keyboard out there.
So you have a keyboard with windows keys

Quote:
Originally Posted by Thorham View Post
It can be improved, that's all. Then again, many things can be improved in the world of software, can't they
So it can be improved ? And... HOW ???
meynaf is offline  
Old 22 June 2009, 12:15   #140
StingRay
move.l #$c0ff33,throat
 
StingRay's Avatar
 
Join Date: Dec 2005
Location: Berlin/Joymoney
Posts: 6,863
Quote:
Originally Posted by meynaf View Post
'99 ? There has been quite a few new versions of phxass since then !
Sure thing but my opinion didn't change!

Quote:
Originally Posted by meynaf
Just too bad. And of course all asm1 development was abandoned ?
Actually not. When Promax left the Amiga scene, other people updated Asm1 or even created completely new versions (Deftronic's Trash'm-One being the most famous/known, he added the "switch between sources with F1-F10" feature which I couldn't live without anymore).
Same thing that happened with SEKA back in the day, as they say, history repeats itself. ;D
In recent years there weren't many updates anymore though.


Quote:
Originally Posted by meynaf
Tested version was 1.48. Is there a newer one ?
Or isn't it one of those debuggers which need an external (parallel or serial) device to display things ?
There is a newer one (v1.49RC2) which you can download here.
The debugger doesn't need an external device. I don't know why it doesn't work on your machine though.

Quote:
Originally Posted by meynaf
It COULD be easier. What are the two "press Escape" for, eh ?
I don't see any use for this command-line stuff and it's constantly coming in the way between editor and assembler.
Escape to switch between editor/command line is logical and I can't see how it could be any easier. And the command line is extremely useful! You can use it to create sintables, read tracks from disk etc pp!

Quote:
Originally Posted by meynaf
I started on devpac 2 and I can't say I like it...
I never liked devpac either even though the actual assembler (genam) is quite ok.

Quote:
Originally Posted by meynaf
But why not doing something like this :
Code:
 ifd _PHXASS_
PHXASS        = 1
 else
PHXASS        = 0
 endc
As said, I want to assemble my code with Asm1 despite being in PHX ass mode. Thus, the _PHXASS_ symbol is not known. I'm using it like this:
Code:
    IFNE    PHXASS

PRINTT        MACRO
        ENDM


    MACHINE    68020
    FPU
    ENDC

Quote:
Originally Posted by meynaf
We're fighting for nothing.
I know. But it's fun. :P



Quote:
Originally Posted by meynaf
So, how good is asmpro ?
ASM-Pro also has a lot of problems (it's a resourced ASM1 and was then constantly improved), the 680x0 support is even worse than in ASM1, specially bitfields are a problem. The graphics card support is better than in ASM1 though which is why I'm using it. It also has some other nice features.

Quote:
Originally Posted by meynaf
For help on asm1, I think I pointed you some example code... Could be good to make it asm1 compatible.
I'll see about that when I have a bit time.
StingRay is offline  
 


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools

Similar Threads
Thread Thread Starter Forum Replies Last Post
Old KGLoad Discussion killergorilla project.KGLoad 357 20 January 2011 16:08
Castlevania Discussion john4p Retrogaming General Discussion 30 30 January 2009 02:10
ROM Discussion... derSammler project.EAB 41 29 January 2008 23:36
General Discussion Zetr0 project.Amiga Game Factory 12 15 December 2005 13:53

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT +2. The time now is 18:19.

Top

Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2024, vBulletin Solutions Inc.
Page generated in 0.93019 seconds with 14 queries