Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 20 Jan 2014 21:04:20 +0100
From:      Dimitry Andric <dim@FreeBSD.org>
To:        freebsd-toolchain@freebsd.org
Subject:   Re: [CFT] Update to clang 3.4
Message-ID:  <D9BD82DC-5DB8-41B4-B983-AF2E6A0365B4@FreeBSD.org>
In-Reply-To: <541C998A-071A-4917-9D91-DD00CB0E2689@FreeBSD.org>
References:  <541C998A-071A-4917-9D91-DD00CB0E2689@FreeBSD.org>

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

--Apple-Mail=_25AFC3CB-4FF1-4539-BCF5-0DFA390DFE40
Content-Transfer-Encoding: quoted-printable
Content-Type: text/plain;
	charset=us-ascii

On 01 Jan 2014, at 23:32, Dimitry Andric <dim@freebsd.org> wrote:
> I have almost completed the preliminary work to import clang 3.4 into
> FreeBSD 11-CURRENT.  The official clang 3.4 release has not yet been
> announced, but I do not expect any more changes from upstream for now.
>=20
> However, since this version introduces a bunch of new warnings, and a
> more strict options parser, I would like to call for some additional
> testing by anyone who is interested.
>=20
> Specifically, the following:
> * Building and installing world with non-standard settings in =
make.conf
>  and/or src.conf.
> * Compiling your favorite set of ports.  (I will request a ports
>  exp-run too).
> * Fixing any kernel source with LINT that has not yet been fixed.  (I
>  am still working on some of the things that are not in GENERIC.)
> * Any other problems you may encounter with optimization,
>  incompatibilities, and so on.
>=20
> One thing to look out for, in particular with ports, is the more =
strict
> option parsing introduced with clang 3.4.  In earlier releases, =
unknown
> or unsupported command line options were ignored, with just a =
"argument
> unused during compilation" warning.  =46rom 3.4 onwards, such options =
will
> result in a "unknown argument" error.
>=20
> Another important new issue is that clang 3.4 now outputs DWARF4 as
> default format when using -g.  Our ancient version of gdb in base does
> not support this, so you must either install the gdb port, or build =
lldb
> and use it (very experimental at this time!).
>=20
> Moreover, our CTF tools such as ctfconvert use a quite old version of
> libdwarf in our base system, which also does not support DWARF4.  So
> ctfconvert processing of kernel objects doe not work at the moment.

This particular problem has now been fixed, thanks to Kai Wang.  With
his fix, the CTF tools now work correctly on a kernel compiled with
clang 3.4, and DTrace works again.  (However, see footnote [1].)

I have rebased the patch against head r260893, and included Kai's fix.
It is located here:

  http://www.andric.com/freebsd/clang/head-r260893-clang34-2.diff.xz

  SHA256 (head-r260893-clang34-2.diff.xz) =3D =
d9b5316d701f6b52d9563c025ce9fb81f6e5aa3c0881ee36a895d14cc8744014

To apply, unxz the file into a fresh head checkout, and run:

  svn patch head-r260893-clang34-2.diff

-Dimitry

[1] Note that there is still an open issue with the CTF tools: they are
not yet built as part of the kernel-tools stage, so any fixes to them
are only effective after installing world.  See also:

=
http://lists.freebsd.org/pipermail/freebsd-hackers/2014-January/044103.htm=
l


--Apple-Mail=_25AFC3CB-4FF1-4539-BCF5-0DFA390DFE40
Content-Transfer-Encoding: 7bit
Content-Disposition: attachment;
	filename=signature.asc
Content-Type: application/pgp-signature;
	name=signature.asc
Content-Description: Message signed with OpenPGP using GPGMail

-----BEGIN PGP SIGNATURE-----
Version: GnuPG/MacGPG2 v2.0.22 (Darwin)

iEYEARECAAYFAlLdgVMACgkQsF6jCi4glqOjHwCgq4+yZ5+AlpVB4EoL459yOuQZ
il4AoMtrydZnklS26VxIoz4pkdzbtIV5
=HDWJ
-----END PGP SIGNATURE-----

--Apple-Mail=_25AFC3CB-4FF1-4539-BCF5-0DFA390DFE40--



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?D9BD82DC-5DB8-41B4-B983-AF2E6A0365B4>