Your message dated Tue, 09 Apr 2013 17:48:51 +0000
with message-id <e1upcf5-0007e1...@franck.debian.org>
and subject line Bug#704111: fixed in llvm-toolchain-3.2 1:3.2repack-1~exp4
has caused the Debian Bug report #704111,
regarding clang fails to correctly implement hard float ABI during default
compiles due to rediculously low default CPU setting.
to be marked as done.
This means that you claim that the problem has been dealt with.
If this is not the case it is now your responsibility to reopen the
Bug report if necessary, and/or fix the problem forthwith.
(NB: If you are a system administrator and have no idea what this
message is talking about, this may indicate a serious mail system
misconfiguration somewhere. Please contact ow...@bugs.debian.org
immediately.)
--
704111: http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=704111
Debian Bug Tracking System
Contact ow...@bugs.debian.org with problems
--- Begin Message ---
Package: clang
Version: 1:3.0-6.1
Severity: grave
x-debbugs-cc: debian-...@lists.debian.org; cfe-...@cs.uiuc.edu
(note for non-debian people reading this, the version of clang in debian
wheezy is a 3.0 based version which already has patches to make it
invoke the linker with appropriate arguments. The llvm version also
appears to be 3.0 again somewhat patched by debian)
I recently discovered that the version of clang in debian wheezy and
raspbian wheezy does not work correctly on either debian armhf or
raspbian. It seems the problem is that clang can't work out what CPU
type it should be using and defaults to something very low (specifically
arm7tdmi). With this CPU selected clang silently fails to properly use
the hard float ABI and as such any armhf code it generates is broken and
won't call floating point routines correctly. It also causes an
assertion failure in the bfd linker (but links successfully with the
gold linker). Setting the CPU type to something sensible makes it
implement the hard float ABI correctly and also stops the assertion
failure in the bfd linker.
I have managed to figure out how to patch clang to change the default
CPU for armhf (patch attatched). However i'm not sure what it is best to
set it to for debian armhf*. In particular this block of code from just
below where my patch is applied seems to map all armv7 variants to a CPU
type of "coretex-a8".
return llvm::StringSwitch<const char
*>(MArch)
.Cases("armv2",
"armv2a","arm2")
.Case("armv3",
"arm6")
.Case("armv3m",
"arm7m")
.Cases("armv4", "armv4t",
"arm7tdmi")
.Cases("armv5", "armv5t",
"arm10tdmi")
.Cases("armv5e", "armv5te",
"arm1026ejs")
.Case("armv5tej",
"arm926ej-s")
.Cases("armv6", "armv6k",
"arm1136jf-s")
.Case("armv6j",
"arm1136j-s")
.Cases("armv6z", "armv6zk",
"arm1176jzf-s")
.Case("armv6t2",
"arm1156t2-s")
.Cases("armv7", "armv7a", "armv7-a",
"cortex-a8")
.Cases("armv7r", "armv7-r",
"cortex-r4")
.Cases("armv7m", "armv7-m",
"cortex-m3")
.Case("ep9312",
"ep9312")
.Case("iwmmxt",
"iwmmxt")
.Case("xscale",
"xscale")
.Cases("armv6m", "armv6-m",
"cortex-m0")
// If all else failed, return the most base CPU LLVM
supports.
.Default("arm7tdmi");
Now it is my understanding that "traditional cortex a8" includes CPU
features not required by debian armhf. Specifically neon and the extra
vfp registers. The questions I have are
1: What does the "coretex-a8" CPU setting imply for clang/llvm? in
particular does it imply neon and the extra vfp registers?
2: If noone can provide an answer to the above question then taking into
the account how late we are in the freeze should we play it safe and
specify a lower (armv6) CPU version to make sure that neon and the extra
vfp registers don't get accidently used. I personally think that the
answer is yes but I'm open to arguments.
If I get no response to this within about a weak I intend to attach a
nmu diff containing a version of the patch that sets the default set to
armv6. Then file a pre-approval request with the release team. Finally
if the release team approves and noone objects I intend to upload the NMU.
Description: Fix CPU type default for armhf
Without this patch clang defaults to a CPU type of "arm7tdmi" which
does not work correctly with -mfloat-abi=hard leading to broken
code.
Author: Peter Michael Green <plugw...@debian.org>
---
The information above should follow the Patch Tagging Guidelines, please
checkout http://dep.debian.net/deps/dep3/ to learn about the format. Here
are templates for supplementary fields that you might want to add:
Origin: <vendor|upstream|other>, <url of original patch>
Bug: <url in upstream bugtracker>
Bug-Debian: http://bugs.debian.org/<bugnumber>
Bug-Ubuntu: https://launchpad.net/bugs/<bugnumber>
Forwarded: <no|not-needed|url proving that it has been forwarded>
Reviewed-By: <name and email of someone who approved the patch>
Last-Update: <YYYY-MM-DD>
Index: clang-3.0/tools/clang/lib/Driver/Tools.cpp
===================================================================
--- clang-3.0.orig/tools/clang/lib/Driver/Tools.cpp 2013-03-27 19:50:18.000000000 +0000
+++ clang-3.0/tools/clang/lib/Driver/Tools.cpp 2013-03-27 19:53:28.000000000 +0000
@@ -442,6 +442,9 @@
if (Arg *A = Args.getLastArg(options::OPT_march_EQ)) {
// Otherwise, if we have -march= choose the base CPU for that arch.
MArch = A->getValue(Args);
+ } else if (Triple.getEnvironment() == llvm::Triple::GNUEABIHF) {
+ // Use armv7-a for armhf
+ MArch = "armv7-a";
} else {
// Otherwise, use the Arch from the triple.
MArch = Triple.getArchName();
--- End Message ---
--- Begin Message ---
Source: llvm-toolchain-3.2
Source-Version: 1:3.2repack-1~exp4
We believe that the bug you reported is fixed in the latest version of
llvm-toolchain-3.2, which is due to be installed in the Debian FTP archive.
A summary of the changes between this version and the previous one is
attached.
Thank you for reporting the bug, which will now be closed. If you
have further comments please address them to 704...@bugs.debian.org,
and the maintainer will reopen the bug report if appropriate.
Debian distribution maintenance software
pp.
Sylvestre Ledru <sylves...@debian.org> (supplier of updated llvm-toolchain-3.2
package)
(This message was generated automatically at their request; if you
believe that there is a problem with it please contact the archive
administrators by mailing ftpmas...@debian.org)
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
Format: 1.8
Date: Thu, 14 Mar 2013 17:47:12 +0100
Source: llvm-toolchain-3.2
Binary: clang-3.2 clang-3.2-doc libclang1 libclang1-dbg libclang-dev
libclang-common-dev libllvm3.2 libllvm3.2-dbg llvm-3.2 llvm-3.2-runtime
llvm-3.2-dev libllvm-3.2-ocaml-dev llvm-3.2-doc llvm-3.2-examples lldb-3.2
Architecture: source amd64 all
Version: 1:3.2repack-1~exp4
Distribution: experimental
Urgency: low
Maintainer: LLVM Packaging Team <pkg-llvm-t...@lists.alioth.debian.org>
Changed-By: Sylvestre Ledru <sylves...@debian.org>
Description:
clang-3.2 - C, C++ and Objective-C compiler (LLVM based)
clang-3.2-doc - C, C++ and Objective-C compiler (LLVM based) - Documentation
libclang-common-dev - clang library - Common development package
libclang-dev - clang library - Development package
libclang1 - clang library
libclang1-dbg - clang library
libllvm-3.2-ocaml-dev - Low-Level Virtual Machine (LLVM), bindings for OCaml
libllvm3.2 - Low-Level Virtual Machine (LLVM), runtime library
libllvm3.2-dbg - Low-Level Virtual Machine (LLVM), debugging symbols library
lldb-3.2 - Next generation, high-performance debugger
llvm-3.2 - Low-Level Virtual Machine (LLVM)
llvm-3.2-dev - Low-Level Virtual Machine (LLVM), libraries and headers
llvm-3.2-doc - Low-Level Virtual Machine (LLVM), documentation
llvm-3.2-examples - Low-Level Virtual Machine (LLVM), examples
llvm-3.2-runtime - Low-Level Virtual Machine (LLVM), bytecode interpreter
Closes: 697356 698352 701587 703671 704111
Changes:
llvm-toolchain-3.2 (1:3.2repack-1~exp4) experimental; urgency=low
.
* Build using binutls-gold to improve the quality of the binaries.
See: http://allievi.sssup.it/techblog/?p=791
* Detect the vendor (Debian or Ubuntu) and update the configuration
* Port to powerpcspe. Thanks to Roland Stigge (Closes: #701587)
See: 31-powerpcspe.diff
* Fix the path detection of scan-build (Closes: #698352)
See: 32-scan-build-path.diff
* debian/patches/r600-snapshot.diff: Move backports into individual patches.
* debian/patches/r600-snapshot.diff: Update to mesa-9.1 git tag.
(Closes: #703671, #697356)
* Fix a typo in the detection of the vendor
.
[ Peter Michael Green ]
* Use binutils-gold only on architectures where it is actually available
* 33-armhf-defaults.diff Fix defaults to use correct CPU and FPU for
debian armhf (Closes: #704111)
* 34-powerpc-no-altivec.diff disable altivec by default on powerpc because
debian powerpc does not require altivec (patch cherry picked from ubuntu)
Checksums-Sha1:
49e15da46eb1ffaa8ef0a13b80a52a06bb742362 3783
llvm-toolchain-3.2_3.2repack-1~exp4.dsc
55320ffdc7fc95decdf26e2b21d5f050e31a6559 198863
llvm-toolchain-3.2_3.2repack-1~exp4.debian.tar.gz
f367d97d62539f49c9510265464e4652496c931f 10153306
clang-3.2_3.2repack-1~exp4_amd64.deb
5a55b19872b51a52eb78d9e6acca74431e210f31 376496
clang-3.2-doc_3.2repack-1~exp4_all.deb
82b2d5265a0e997f3085301a4b4093ea60d5fca4 4226774
libclang1_3.2repack-1~exp4_amd64.deb
feaba16ebc5fea940231843c8ee7d856bfa1808a 80159518
libclang1-dbg_3.2repack-1~exp4_amd64.deb
20447e45b9840787e18b257a39e78381bb234362 10719844
libclang-dev_3.2repack-1~exp4_amd64.deb
4d8835e715cfa6dfc1a3b4d593c90b7bf79b1b97 311124
libclang-common-dev_3.2repack-1~exp4_amd64.deb
7770be8a33281b1f15cf36019298011e55b9efd0 7858538
libllvm3.2_3.2repack-1~exp4_amd64.deb
893b62a428da14583d80f1df1afc05c6f70afd33 100976040
libllvm3.2-dbg_3.2repack-1~exp4_amd64.deb
0ade68787b34dbc08f567326e31ab2018162cf84 1470614
llvm-3.2_3.2repack-1~exp4_amd64.deb
facd8490dd176ef40622f3e4e5efbd1846de804f 39786
llvm-3.2-runtime_3.2repack-1~exp4_amd64.deb
a545bf57808b2edc1e41e61adc46595ed0f02652 14307394
llvm-3.2-dev_3.2repack-1~exp4_amd64.deb
c2eb6a74f718517cf37e4cc427ce20bf74dfd408 270260
libllvm-3.2-ocaml-dev_3.2repack-1~exp4_amd64.deb
954ce216ce3ec9c738457e9322591f0c47b76088 1163364
llvm-3.2-doc_3.2repack-1~exp4_all.deb
debcd7c6a1407a474f1f2923502588978af3d328 102394
llvm-3.2-examples_3.2repack-1~exp4_all.deb
227cf4b8579dea74125ebc90c800cda1280034a3 7651950
lldb-3.2_3.2repack-1~exp4_amd64.deb
Checksums-Sha256:
aa3ffb26a8db2c4460c00205cba58cbb8a26835718354067d9d7564ddf7d0332 3783
llvm-toolchain-3.2_3.2repack-1~exp4.dsc
2757dd9cf795b983cdd6ae9da82e991e37481b70b2b9b2e936693ec301dbf412 198863
llvm-toolchain-3.2_3.2repack-1~exp4.debian.tar.gz
ac3127ce0eec1f3290f4d3bd873a28c9da77dce4ca177ef9a922a23f482b1050 10153306
clang-3.2_3.2repack-1~exp4_amd64.deb
22ca22fee8eab591ce60c69ca0c49afcb045f4d6218f6646a9172c4e9e1aea65 376496
clang-3.2-doc_3.2repack-1~exp4_all.deb
a8195fc7cebf9501fe7cac75a6605e74c2ebad1bf19e97052e089904f187af49 4226774
libclang1_3.2repack-1~exp4_amd64.deb
27128888e3748d0660f7a27b23a0f8472ec479a54c1ccea87456c57880c6bd62 80159518
libclang1-dbg_3.2repack-1~exp4_amd64.deb
39f78ae72ad954fcc1f43582b871172120c6107f078f7a9355c0ceed574fc032 10719844
libclang-dev_3.2repack-1~exp4_amd64.deb
4e2b5fb47b0f49bcb384f029ee6fffdb1461aa78d5b051ec9bda5e8e54e8d6af 311124
libclang-common-dev_3.2repack-1~exp4_amd64.deb
e2d8ae9dc415c4a2806da370aca512c9bdbd786bcb40e9d5d512a5eff9abe9bd 7858538
libllvm3.2_3.2repack-1~exp4_amd64.deb
5f8465e6dc5490626c80043f8d9d7a245347007004c9a3be821e914076542623 100976040
libllvm3.2-dbg_3.2repack-1~exp4_amd64.deb
64107142a94bebe4418ff316323b5958ef2d45b183f974c572118c82ffcae1e4 1470614
llvm-3.2_3.2repack-1~exp4_amd64.deb
d3c725b30596decca956eb5f21bb2a51915fb9d95f2d2e963978903f2e68f9cf 39786
llvm-3.2-runtime_3.2repack-1~exp4_amd64.deb
e9b199c55992179c1dbcccccab9f7764fce716a521ac91010f3396843375a84f 14307394
llvm-3.2-dev_3.2repack-1~exp4_amd64.deb
519346dfb8ba22a208dd0959f1fd9f867c856655eabbd1eac242dccc6bc2ee3e 270260
libllvm-3.2-ocaml-dev_3.2repack-1~exp4_amd64.deb
4c9348c80c26b331619a1c7631ebabfedc3f27148d2a376d84ec58ce55d1bd1a 1163364
llvm-3.2-doc_3.2repack-1~exp4_all.deb
5e2cac536f1448b917ca30629962a13a9ca3ac272a59bf2cf0d894e9a3231350 102394
llvm-3.2-examples_3.2repack-1~exp4_all.deb
182ed9aa15ef7e8222f398799f47db23c2edf03d00bc6d9d35c7a3f258b6133c 7651950
lldb-3.2_3.2repack-1~exp4_amd64.deb
Files:
3814a38deae7d1c7c951c8afd43e0f87 3783 devel optional
llvm-toolchain-3.2_3.2repack-1~exp4.dsc
6546a687a0223a350c9f072f21a29dc8 198863 devel optional
llvm-toolchain-3.2_3.2repack-1~exp4.debian.tar.gz
040a73cfa5a20fd76d2c75fded1bd36f 10153306 devel optional
clang-3.2_3.2repack-1~exp4_amd64.deb
bd959bb9fbff68ae64c7490185446a1e 376496 doc optional
clang-3.2-doc_3.2repack-1~exp4_all.deb
3e079df83ab1e8b1117186c9a0d8347a 4226774 devel optional
libclang1_3.2repack-1~exp4_amd64.deb
ea15a529752927f8a5ceb497659abe6c 80159518 debug extra
libclang1-dbg_3.2repack-1~exp4_amd64.deb
5f46e1f13e60fd3b7fe6f0039f878a03 10719844 libdevel optional
libclang-dev_3.2repack-1~exp4_amd64.deb
a9aa49b40dad04998a426f93bc3e8898 311124 libdevel optional
libclang-common-dev_3.2repack-1~exp4_amd64.deb
d52c6985b1f4201cdbe898fb36a037d0 7858538 libs optional
libllvm3.2_3.2repack-1~exp4_amd64.deb
c99cd1fd9999697dc25e45c166db58ae 100976040 debug extra
libllvm3.2-dbg_3.2repack-1~exp4_amd64.deb
7be9a8ccd428d192c270510c7b1ee690 1470614 devel optional
llvm-3.2_3.2repack-1~exp4_amd64.deb
1c58693341a1491c4b03f344135a18e1 39786 devel optional
llvm-3.2-runtime_3.2repack-1~exp4_amd64.deb
8b4efa15a290baf4124c716f39f333fc 14307394 devel optional
llvm-3.2-dev_3.2repack-1~exp4_amd64.deb
efe7738a11f4962891809b42d7422660 270260 ocaml optional
libllvm-3.2-ocaml-dev_3.2repack-1~exp4_amd64.deb
b3ba3f30aff8fcc616e743d746d2de18 1163364 doc optional
llvm-3.2-doc_3.2repack-1~exp4_all.deb
770eef5e8d76a63996350f71f4ed27ab 102394 doc optional
llvm-3.2-examples_3.2repack-1~exp4_all.deb
c723c9e4165804aafd1f8078822c27e3 7651950 devel optional
lldb-3.2_3.2repack-1~exp4_amd64.deb
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.12 (GNU/Linux)
iEYEARECAAYFAlFkT3AACgkQiOXXM92JlhDgvQCgjdVhWBipH7nTu81hNX4Qh1G3
0tAAn0UiMQiYASNadPjvxuhnvHUYxf0n
=KbWi
-----END PGP SIGNATURE-----
--- End Message ---