A multicore FLAC encoder |
A multicore FLAC encoder |
Nov 15 2009, 19:38
Post
#1
|
|
|
Group: Members Posts: 81 Joined: 2-August 09 Member No.: 71959 |
Hi!
Maybe you already know fpMP3Enc, my multicore MP3 encoder... This time, I'd like to introduce my multicore FLAC encoder. You can download the binaries here. The package contains Win32 binaries for XP, Vista and 7, and Win64 binaries for Vista and 7. The FLAC encoder is part of my "fpStream" project. The command-line to convert a WAV file to FLAC is as follows: CODE FPSTREAM.EXE readfile in -f <wav-filename> + wavin wav -s in + fpflacenc enc -s wav [-<compression level>] + writefile out -s enc -f <flac-filename> The benchmarks so far: I used the same test suite as in fpMP3Enc (Intel Q9450, 61 WAV files, about 5 hours playing time). The compression level was 5. The files were encoded one after the other, not in parallel. - flac 1.2.1: 3 min 26 secs - fpFLAC x64: 1 min 13 secs So, the speedup was 2.8x. This is quite good if you consider that this version does not contain any SSE optimizations. What's missing: - SSE optimizations - Metadata support (tags, seek points etc.) - free of bugs And some limitations: - Win32 version: The total WAV file size sum must not exceed 400MiB(? - not sure). - Win64 version: The total WAV file size sum must not exceed 400GiB. - Input: WAV 16-bit stereo, 44.1kHz Comments and feedback are welcome! George |
|
|
|
![]() |
Dec 2 2009, 07:23
Post
#2
|
|
![]() Group: Members Posts: 90 Joined: 22-July 09 Member No.: 71664 |
Alright! I'm impressed. I have to say that I didn't think the improvement would be that great on my system, but here are my results (based on about a 53 minute CD):
original FLAC encoder (-8) = 1 minute, 15 seconds. and George FP's encoder (-8) = 24 seconds! i didn't believe it, so I did a bit-compare on the two files: CODE All tracks decoded fine, no differences found. Comparing: "X:\encode1.flac" "X:\encode2.flac" No differences in decoded data found. and then I did a verify on the FLAC files, to make sure they were identical (audio data-wise): CODE Item: "X:\encode1.flac" MD5: 66B84449D7A9899065A11FA190C994AC CRC32: D199E9A2 No problems found. All items decoded successfully. Item: "X:\encode2.flac" MD5: 66B84449D7A9899065A11FA190C994AC CRC32: D199E9A2 No problems found. All items decoded successfully. finally, to prove that it wasn't EXACTLY THE SAME THING, i have noted the file sizes and hashes of both FLAC files... different! both files are unique. CODE File: encode1.flac Size: 357MB (374,398,783 bytes) CRC-32: fa984f9e MD5: 6eb400219c22f1aa1525d13f5f7f1135 SHA-1: 70aa7e4a65ed635eb78b52ef3d2f1b1b8b435692 File: encode2.flac Size: 356MB (374,328,806 bytes) CRC-32: eac29087 MD5: a8d830f2defbe50af368ce60a5a69460 SHA-1: c356080e0e508d26b8d7b625229af0d2ca2dde7b so George... you have made a believer of me! empirical evidence, right there for me and everyone else to see.... congrats! I am about to do a second test on a second system, then I will post those results below. Results from test #2: original FLAC encoder (-8 compression) = 1 minute, 07 seconds and George FP's encoder (-8 compression) = 21 seconds just for kicks I tried flaCUDA... flaCUDA encoder (-11 compression) = 58 seconds flaCUDA encoder (-8 compression) = 16 seconds CODE E:\Temp>CUETools.FlaCuda.exe -11 encode.wav -o encode3.flac CUETools.FlaCuda, Copyright (C) 2009 Gregory S. Chudov. Filename : encode.wav File Info : 44100kHz; 2 channel; 16 bit; 00:52:53.4930000 Results : 53.89x; 373021162 bytes in 00:00:58.8901034 seconds; E:\Temp>CUETools.FlaCuda.exe -8 encode.wav -o encode4.flac CUETools.FlaCuda, Copyright (C) 2009 Gregory S. Chudov. Filename : encode.wav File Info : 44100kHz; 2 channel; 16 bit; 00:52:53.4930000 Results : 198.27x; 373969399 bytes in 00:00:16.0056281 seconds; but there is a discrepancy.... flaCUDA's compression scheme goes up to 11, and that is what the 58 second result was based on... when I use compression -8, the encoding time ends up only taking 16 seconds. jeez. I'm not sure how the compression numbers crossover though. all 4 output files are identical to the original and each other (same audio MD5's), the two files produced by FLAC and fpFLAC both have a bitrate of 944, whereas the flaCUDA -11 encode shows a 940 bitrate, and the flaCUDA -8 encode shows a 943 bitrate (in foobar2000) -- all end-product FLAC files are sized between 355MB and 357MB, so negligible difference, size wise. *shrug* i have no idea.... already put waaaay too much thought into this as it is haha anyways, with differing compression schemes, it's hard to make a solid conclusion.... other than that both of these two are VERY FAST encoders! oh yeah, and of course, I forgot to include what specs I was using to test: Intel i7-860 (2.8Ghz stock, 3.47Ghz in turbo mode -- it's a Quad-core with Hyper-Threading, so it sees it as 8 CPU's) 4GB DDR3-1600 RAM Windows7 x64... I used of course the 64 bit version and the SSE4 instructions as George said in the readme (and video card is Nvidia GeForce 9600 GSO) This post has been edited by Chinch: Dec 2 2009, 08:18 |
|
|
|
GeorgeFP A multicore FLAC encoder Nov 15 2009, 19:38
Cokemonkey11 Good stuff, can't wait for the GUI. Nov 15 2009, 21:49
punkrockdude Yeah! I love that your make multi core applica... Nov 15 2009, 23:03
flacflac Wow, this is very interesting. The speed-gain you... Nov 16 2009, 11:14
GeorgeFP QUOTE (flacflac @ Nov 16 2009, 11:14) Wow... Nov 16 2009, 13:34
Maurits Is there any chance that these improvements can be... Nov 16 2009, 12:39
GeorgeFP QUOTE (Maurits @ Nov 16 2009, 12:39) Is t... Nov 16 2009, 13:56
hlloyge It would be interesting to compare it to CUDA FLAC... Nov 16 2009, 12:55
GeorgeFP QUOTE (hlloyge @ Nov 16 2009, 12:55) It w... Nov 16 2009, 20:51
Lucho QUOTE (GeorgeFP @ Nov 15 2009, 20:38) COD... Nov 16 2009, 16:12
GeorgeFP QUOTE (Lucho @ Nov 16 2009, 16:12) This i... Nov 16 2009, 17:33
GeorgeFP OK, I've uploaded a new version. The link is t... Nov 16 2009, 18:25
flacflac Hi GeorgeFP,
thank you for this exciting multicor... Nov 17 2009, 18:58
GeorgeFP Thanks for your feedback!
QUOTE 1) Using Win7... Nov 17 2009, 22:21
flacflac Hi George, thank you for that detailed reply! ... Nov 18 2009, 03:10

GeorgeFP QUOTE (flacflac @ Nov 18 2009, 03:10) Awe... Nov 18 2009, 07:05
Cokemonkey11 QUOTE (GeorgeFP @ Nov 17 2009, 13:21) Yes... Nov 18 2009, 03:58
GeorgeFP QUOTE (Cokemonkey11 @ Nov 18 2009, 03:58)... Nov 18 2009, 06:59
Cokemonkey11 QUOTE (GeorgeFP @ Nov 17 2009, 21:59) QUO... Nov 18 2009, 07:09
GeorgeFP QUOTE (Cokemonkey11 @ Nov 18 2009, 07:09)... Nov 18 2009, 13:25
GeorgeFP I have uploaded a new version.
The release notes ... Nov 18 2009, 19:52
flacflac QUOTE (GeorgeFP @ Nov 18 2009, 13:52) I h... Nov 19 2009, 09:17
GeorgeFP QUOTE (flacflac @ Nov 19 2009, 09:17) 1) ... Nov 19 2009, 10:10
GeorgeFP Here is a screenshot how to configure EAC to use f... Nov 23 2009, 10:34
howesz For ease of integration with EAC (i.e. so you can ... Dec 2 2009, 03:14

GeorgeFP QUOTE (howesz @ Dec 2 2009, 03:14) How ha... Dec 4 2009, 21:37
jamesbaud QUOTE (GeorgeFP @ Nov 23 2009, 01:34) Her... Dec 2 2009, 11:00
JacksonGrey QUOTE (jamesbaud @ Dec 2 2009, 10:00) Cou... Dec 2 2009, 13:40
GeorgeFP QUOTE (jamesbaud @ Dec 2 2009, 11:00) Cou... Dec 3 2009, 09:50
gottkaiser Wow, I'm impressed.
Thanks for all the work ef... Dec 3 2009, 12:26
Wombat You may use it together with metaflac with linking... Dec 2 2009, 03:36
Chinch interesting project you have going here. i know th... Dec 2 2009, 06:25
GeorgeFP QUOTE (Chinch @ Dec 2 2009, 06:25) 1) the... Dec 4 2009, 22:02
Glenda Such a nice upgrade to EAC, thankyou Dec 3 2009, 14:14
Glenda QUOTE (Glenda @ Dec 3 2009, 09:14) Such a... Dec 3 2009, 14:22
Glenda QUOTE (Glenda @ Dec 3 2009, 09:22) QUOTE ... Dec 3 2009, 14:36
GeorgeFP Hi!
The new version can be downloaded here:
... Dec 4 2009, 12:27
gottkaiser QUOTE (GeorgeFP @ Dec 4 2009, 12:27) To u... Dec 4 2009, 13:08

jamesbaud QUOTE (gottkaiser @ Dec 4 2009, 04:08) QU... Dec 5 2009, 14:32
johnsonlam QUOTE (GeorgeFP @ Dec 4 2009, 19:27) 64-B... Dec 4 2009, 13:25
GeorgeFP QUOTE (johnsonlam @ Dec 4 2009, 13:25) QU... Dec 4 2009, 14:03
GeorgeFP And here is the screenshot for foobar2000:
You s... Dec 4 2009, 12:47
greynol Considering that EAC only passes one file at a tim... Dec 4 2009, 18:12
Gregory S. Chudov This encoder is useful, because it can use all the... Dec 4 2009, 20:04
GeorgeFP QUOTE (greynol @ Dec 4 2009, 18:12) Consi... Dec 4 2009, 22:21
pdq So are you saying that it is pointless to use this... Dec 4 2009, 19:51
greynol I know I'm usually a sarcastic cynic, but this... Dec 4 2009, 19:57
greynol So it's a departure from this?
http://www.hydr... Dec 4 2009, 20:10
pdq Wouldn't the time to compress a single image f... Dec 4 2009, 20:20
greynol EAC doesn't start encoding with an external co... Dec 4 2009, 20:36
pdq I'm just saying that the time to encode after ... Dec 4 2009, 21:25
greynol On my system it still takes longer to encode @ -8 ... Dec 4 2009, 21:29
greynol Perhaps you could have made it a little more clear... Dec 4 2009, 22:29
GeorgeFP QUOTE (greynol @ Dec 4 2009, 22:29) Perha... Dec 4 2009, 22:43
greynol Well no. Why didn't you provide that link in ... Dec 4 2009, 22:50
GeorgeFP A new version with two bug fixes is available for ... Dec 7 2009, 19:55
JacksonGrey I keep getting an error that a number of files ... Dec 8 2009, 00:59
GeorgeFP QUOTE (JacksonGrey @ Dec 8 2009, 00:59) I... Dec 8 2009, 07:14
GeorgeFP I've found the problem with the installer: Sev... Dec 8 2009, 13:12
greynol I'd love to see this done with metaflac so tha... Dec 8 2009, 17:34
NuSkooler I cannot wait for this to be ready for production ... Dec 23 2009, 18:16
GeorgeFP QUOTE (NuSkooler @ Dec 23 2009, 18:16) I ... Dec 24 2009, 12:47
Bylie QUOTE (GeorgeFP @ Dec 24 2009, 12:47) Wel... Dec 24 2009, 14:59

GeorgeFP QUOTE (Bylie @ Dec 24 2009, 14:59) But, p... Dec 25 2009, 13:33

Bylie QUOTE (GeorgeFP @ Dec 25 2009, 13:33) Bel... Dec 25 2009, 18:43

GeorgeFP QUOTE (Bylie @ Dec 25 2009, 18:43) I real... Dec 25 2009, 22:11
_mē_ QUOTE (GeorgeFP @ Dec 24 2009, 12:47) QUO... Dec 25 2009, 00:56
NuSkooler QUOTE (_mē_ @ Dec 24 2009, 16:56) 1. For ... Dec 25 2009, 01:03

GeorgeFP QUOTE (NuSkooler @ Dec 25 2009, 01:03) QU... Dec 25 2009, 20:51

NuSkooler QUOTE (GeorgeFP @ Dec 25 2009, 12:51) My ... Dec 26 2009, 03:24

GeorgeFP QUOTE (NuSkooler @ Dec 26 2009, 03:24) Th... Dec 26 2009, 09:27

NuSkooler QUOTE (GeorgeFP @ Dec 26 2009, 01:27) Ano... Dec 26 2009, 17:17

GeorgeFP QUOTE (NuSkooler @ Dec 26 2009, 17:17) QU... Dec 26 2009, 20:05
flacflac QUOTE (_mē_ @ Dec 24 2009, 18:56) Well, t... Feb 6 2010, 12:11
GeorgeFP QUOTE (flacflac @ Feb 6 2010, 12:11) Is i... Feb 6 2010, 19:04
Gregory S. Chudov Agree. Josh, if you are interested, i'm ready ... Dec 24 2009, 15:20
skamp QUOTE (Gregory S. Chudov @ Dec 24 2009, 15... Dec 24 2009, 16:30
Qest It would be outstanding if the defacto flac tools ... Dec 25 2009, 01:02
Zarggg Will this program yield any benefit to a (single c... Dec 25 2009, 05:02
GeorgeFP QUOTE (Zarggg @ Dec 25 2009, 05:02) Will ... Dec 25 2009, 22:20
Fandango QUOTE (GeorgeFP @ Dec 25 2009, 22:20) QUO... Dec 25 2009, 23:05
Fandango Uhm, I would happily replace all single-threaded c... Dec 25 2009, 19:29
skamp Encoding two files at once on my Intel Atom with h... Dec 25 2009, 22:44
GeorgeFP BTW, I've decided to add some missing command-... Dec 26 2009, 20:18
howesz QUOTE (GeorgeFP @ Dec 26 2009, 14:18) BTW... Jul 10 2010, 02:24
Glenda QUOTE (howesz @ Jul 9 2010, 21:24) QUOTE ... Aug 7 2010, 09:36

GeorgeFP QUOTE (Glenda @ Aug 7 2010, 09:36) Same h... Aug 29 2010, 11:14
GeorgeFP QUOTE (howesz @ Jul 10 2010, 03:24) QUOTE... Sep 3 2010, 11:11
gimp QUOTE (GeorgeFP @ Sep 3 2010, 02:11) QUOT... Sep 16 2010, 22:09
GeorgeFP QUOTE (gimp @ Sep 16 2010, 23:09) Removed... Sep 17 2010, 07:16
Meeko So I'm guessing a multicore FLAC encoder would... Dec 28 2009, 13:52
Fandango You are right, multi-threaded encoders are for fas... Dec 28 2009, 15:22
clintb Any chance someone could whip up a batch file for ... Jan 29 2010, 16:06
Synthetic Soul QUOTE (clintb @ Jan 29 2010, 15:06) Any c... Feb 6 2010, 14:29
GeorgeFP An updated version is now available on my site.
I... Sep 19 2010, 09:05
Glenda The encoder flags errors on every attempt with EAC... Jan 17 2011, 08:47
GeorgeFP QUOTE (Glenda @ Jan 17 2011, 08:47) The e... Jan 17 2011, 18:48
Glenda QUOTE (GeorgeFP @ Jan 17 2011, 12:48) QUO... Jan 18 2011, 11:02
GeorgeFP It seems that the libraries are of mixed type (32 ... Jan 18 2011, 12:47![]() ![]() |
|
Lo-Fi Version | Time is now: 26th May 2013 - 02:12 |