Problems in FLAC 0.9: - On alpha, flac immediately dumps core for both encoding and decoding (FreeBSD/alpha). - The distribution Makefile.in files haven't been generated with "automake --include-deps". The resulting Makefiles aren't fully portable; in particular they break with BSD make. In the future, care should be taken to use "--include-deps". - What is the obj directory for? "obj" is magic to BSD make, and unless removed this directory breaks building on BSD. - I question the wisdom of forcing CFLAGS to a particular set of (gcc-specific) optimizations options. -- Christian "naddy" Weisgerber naddy@mips.inka.de
On Sat, May 19, 2001 at 12:55:08AM -0400, Matt Zimmerman wrote:> On Sat, May 19, 2001 at 02:05:14AM +0000, Christian Weisgerber wrote: > > > Problems in FLAC 0.9: > > > > - On alpha, flac immediately dumps core for both encoding and > > decoding (FreeBSD/alpha). > > I have reproduced this on Debian/alpha as well. I will spend some time > debugging it tonight.I am doing my testing with an 8-bit mono sample, so that should hopefully rule out any endianness issues related to the audio data itself, and with all objects compiled using -g -O0 -DDEBUG -DFLAC_OVERFLOW_DETECT. Here is the stack trace for the crash when encoding: #0 0x200000e7304 in FLAC__fixed_compute_residual (data=0x1202b9c54, data_len=4607, order=1, residual=0x1202e6cc0) at fixed.c:165 #1 0x200000e1f44 in encoder_evaluate_fixed_subframe_ (signal=0x1202b9c50, residual=0x1202e6cc0, abs_residual=0x1202fd510, blocksize=4608, subframe_bps=8, order=1, rice_parameter=1, max_partition_order=4, subframe=0x200002aa2b0) at encoder.c:1028 #2 0x200000e1764 in encoder_process_subframe_ (encoder=0x1202b9bf0, max_partition_order=4, verbatim_only=0, frame_header=0x11ffff850, subframe_bps=8, integer_signal=0x1202b9c50, real_signal=0x1202be460, subframe=0x2000050b940, residual=0x2000028a0e0, best_subframe=0x2000050b9e0, best_bits=0x2000050ba08) at encoder.c:917 #3 0x200000e08d4 in encoder_process_subframes_ (encoder=0x1202b9bf0, is_last_frame=0) at encoder.c:727 #4 0x200000dffb4 in encoder_process_frame_ (encoder=0x1202b9bf0, is_last_frame=0) at encoder.c:595 #5 0x200000dfa14 in FLAC__encoder_process (encoder=0x1202b9bf0, buf=0x1202b96d8, samples=2048) at encoder.c:523 #6 0x120005d08 in encode_wav (infile=0x11ffffe26 "/home/mdz/english.wav", outfile=0x11ffffe3c "/home/mdz/english.flac", verbose=1, skip=0, verify=0, lax=0, do_mid_side=1, loose_mid_side=0, do_exhaustive_model_search=0, do_qlp_coeff_prec_search=0, rice_optimization_level=4, max_lpc_order=8, blocksize=4608, qlp_coeff_precision=0, padding=0) at encode.c:280 #7 0x12000a208 in main (argc=3, argv=0x11ffffc38) at main.c:293 and when decoding: #0 0x200000e7830 in FLAC__fixed_restore_signal (residual=0x1202ce480, data_len=4606, order=2, data=0x1202c9c78) at fixed.c:209 #1 0x200000ef25c in stream_decoder_read_subframe_fixed_ (decoder=0x1202b9c30, channel=0, bps=8, order=2) at stream_decoder.c:1158 #2 0x200000eeb34 in stream_decoder_read_subframe_ (decoder=0x1202b9c30, channel=0, bps=8) at stream_decoder.c:1069 #3 0x200000ed3a4 in stream_decoder_read_frame_ (decoder=0x1202b9c30, got_a_frame=0x11ffff9e8) at stream_decoder.c:673 #4 0x200000eb810 in FLAC__stream_decoder_process_whole_stream ( decoder=0x1202b9c30) at stream_decoder.c:240 #5 0x200000e5434 in FLAC__file_decoder_process_whole_file ( decoder=0x1202b9990) at file_decoder.c:181 #6 0x1200030cc in decode_wav (infile=0x11ffffe25 "/home/mdz/english.flac", outfile=0x11ffffe3c "/home/mdz/english2.wav", analysis_mode=0, aopts={ do_residual_text = 0, do_residual_gnuplot = 0}, verbose=1, skip=0) at decode.c:119 #7 0x12000a098 in main (argc=4, argv=0x11ffffc28) at main.c:288 It's not obvious at first glance where the fault is being triggered; residual and data both appear valid. -- - mdz
Christian Weisgerber <naddy@mips.inka.de> wrote:> Problems in FLAC 0.9:Also: ===> Building for flac-0.9 cd . && aclocal aclocal: configure.in: 7: macro `AM_PROG_LIBTOOL' not found in library aclocal: configure.in: 22: macro `AM_PATH_XMMS' not found in library gmake: *** [aclocal.m4] Error 1 That is, if I touch configure.in I must have libtool and XMMS installed. This doesn't seem right. Should AM_PROG_LIBTOOL and AM_PATH_XMMS be shipped in acinclude.m4? -- Christian "naddy" Weisgerber naddy@mips.inka.de
On Sat, May 19, 2001 at 12:19:39PM +0000, Christian Weisgerber wrote:> Christian Weisgerber <naddy@mips.inka.de> wrote: > > > Problems in FLAC 0.9: > > Also: > > ===> Building for flac-0.9 > cd . && aclocal > aclocal: configure.in: 7: macro `AM_PROG_LIBTOOL' not found in library > aclocal: configure.in: 22: macro `AM_PATH_XMMS' not found in library > gmake: *** [aclocal.m4] Error 1 > > That is, if I touch configure.in I must have libtool and XMMS > installed. This doesn't seem right. Should AM_PROG_LIBTOOL and > AM_PATH_XMMS be shipped in acinclude.m4?These macros are supplied by aclocal.m4, which is automatically generated by aclocal(1) from automake. If you modify configure.in, automake will re-run aclocal to pull in any new macros that might be referenced in configure.in. This is a good thing, as it keeps the macros in aclocal.m4 fresh, and ensures that newly used ones will be included there. In my opinion, the bug is that aclocal is failing when the required macros are already defined in the current aclocal.m4. You should be able to work around this by touching aclocal.m4 after editing configure.in. Off to file a bug against automake... -- - mdz
> > - I question the wisdom of forcing CFLAGS to a particular set of > > (gcc-specific) optimizations options. > > Agreed. autoconf already knows whether cc is gcc, so it's a simple > matter to > conditionally set CFLAGS. >OK, this is fixed in configure.in now. Josh __________________________________________________ Do You Yahoo!? Get personalized email addresses from Yahoo! Mail - only $35 a year! http://personal.mail.yahoo.com/
On Sat, May 19, 2001 at 02:05:14AM +0000, Christian Weisgerber wrote:> Problems in FLAC 0.9: > > - On alpha, flac immediately dumps core for both encoding and > decoding (FreeBSD/alpha).I have reproduced this on Debian/alpha as well. I will spend some time debugging it tonight.> - The distribution Makefile.in files haven't been generated with > "automake --include-deps". The resulting Makefiles aren't fully > portable; in particular they break with BSD make. In the future, > care should be taken to use "--include-deps".This should happen automatically if the tarball is created with "make dist".> - What is the obj directory for? "obj" is magic to BSD make, and > unless removed this directory breaks building on BSD.I believe this is used by the non-automake makefiles.> - I question the wisdom of forcing CFLAGS to a particular set of > (gcc-specific) optimizations options.Agreed. autoconf already knows whether cc is gcc, so it's a simple matter to conditionally set CFLAGS. -- - mdz