Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 21 Apr 2010 18:58:26 +0100
From:      Rui Paulo <rpaulo@lavabit.com>
To:        Alexander Best <alexbestms@wwu.de>
Cc:        Roman Divacky <rdivacky@FreeBSD.org>, freebsd-current@FreeBSD.org
Subject:   Re: [CFT]: ClangBSD is selfhosting, we need testers now
Message-ID:  <034542FD-3BAD-4ACA-B085-17F575409DAF@lavabit.com>
In-Reply-To: <permail-201004211722001e86ffa800003aa3-a_best01@message-id.uni-muenster.de>
References:  <permail-201004211722001e86ffa800003aa3-a_best01@message-id.uni-muenster.de>

next in thread | previous in thread | raw e-mail | index | archive | help

On 21 Apr 2010, at 18:22, Alexander Best wrote:

> Roman Divacky schrieb am 2010-04-21:
>> On Wed, Apr 21, 2010 at 05:20:57PM +0200, Alexander Best wrote:
>>> i might have stumbled upon a problem with clang. i've compiled a
>>> kernel from
>>> the clang branch using `make kernel INSTKERNNAME=clang` and booted
>>> from it.
>>> i'm now experiencing audio problems with mp3s and certain video
>>> files.
>>> playback is awfully slow and the audio output gets distorted
>>> massively. `top`
>>> however reports no high cpu load and `vmstat -i` doesn't report
>>> anything
>>> unusual either.
> 
>>> this problem doesn't occur with a regular gcc-kernel.
> 
>>> both kernels are running under a regular (gcc) world.
> 
>>> i thought it might be a problem with acpi, but disabling acpi
>>> (hint.acpi.0.disabled=1) gives me a system freeze.
> 
>> I've heard about this problem but did not manage to reproduce that.
> 
>> can you try to bisect what file is being miscompiled? ie. compile
>> half of the kernel with gcc and half with clang and bisect this
>> way to a single file.
> 
>> we can work from there...
> 
> i've identified the problem to be somewhere in sys/dev/sound. i've removed
> "device sound" and "device hda_snd" from my kernel config and
> rebuild/reinstalled both kernels (gcc and clang). i then booted the clang
> kernel and loaded various sound.ko and snd_hda.ko combination. here're the
> results:
> 
> sound.ko (clang) snd_hda.ko (clang) => BROKEN
> sound.ko (clang) snd_hda.ko (gcc)   => BROKEN
> sound.ko (gcc) snd_hda.ko (gcc)     => OK
> sound.ko (gcc) snd_hda.ko (clang)   => OK
> 
> i've attached a log documenting all clang warnings that get issued when
> building sys/modules/sound.
> 
> in addition to those warnings i get a lot of these, but i guess they aren't
> harmful:
> 
> clang: warning: argument unused during compilation: '-funroll-loops'
> clang: warning: argument unused during compilation: '-finline-limit=8000'
> clang: warning: argument unused during compilation: '--param
> inline-unit-growth=100'
> clang: warning: argument unused during compilation: '--param
> large-function-growth=1000'
> clang: warning: argument unused during compilation: '-mfpmath=387'
> clang: warning: argument unused during compilation: '-fformat-extensions'
> clang: warning: argument unused during compilation: '-funroll-loops'
> clang: warning: argument unused during compilation: '-finline-limit=8000'
> clang: warning: argument unused during compilation: '--param
> inline-unit-growth=100'
> clang: warning: argument unused during compilation: '--param
> large-function-growth=1000'
> clang: warning: argument unused during compilation: '-mfpmath=387'

There's some assembly in feeder_rate.c. Can you check if it's being used?

Regards,
--
Rui Paulo





Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?034542FD-3BAD-4ACA-B085-17F575409DAF>