Commit Graph

6702 Commits

Author SHA1 Message Date
Dimitry Andric
a8bcc4d878 Update llvm, clang and lldb to release_38 branch r260756. 2016-02-13 15:58:51 +00:00
Dimitry Andric
4156ce4fed Merge ^/head r295351 through r295543. 2016-02-11 20:07:09 +00:00
Dimitry Andric
5529affd65 For now, disable shrink-wrapping (a new optimization pass that computes
the safe point to insert the prologue and epilogue of the function) on
X86.  This prevents problems with some functions using TLS, such as in
jemalloc, and which was the cause for Address Sanitizer crashes.  The
correct fix is still being discussed upstream.
2016-02-11 20:00:22 +00:00
Dag-Erling Smørgrav
0de4f1bf64 Use the new insecure-lan-zones option instead of listing each AS112 zone
separately.

MFC after:	3 days
2016-02-11 17:37:02 +00:00
Dimitry Andric
a49d8b6ecc Merge ^/head r294961 through r295350. 2016-02-06 14:07:17 +00:00
Dimitry Andric
f8ca070d3a Merge compiler-rt release_38 branch r258968.
Note that there is still a problem on amd64, causing SIGBUS in the early
startup of Address Sanitizer.  This is being investigated.
2016-02-06 13:39:20 +00:00
Ed Maste
baed4bab22 readelf: decode AArch64 TLS descriptor relocations
From ELF for the ARM(R) 64-bit Architecture, table 4-19.

Obtained from:	ELF Tool Chain r3386
Sponsored by:	The FreeBSD Foundation
2016-02-05 20:57:21 +00:00
Ed Maste
03a5ea47c0 readelf: report value of unknown relocation types
Obtained from:	ELF Tool Chain r3387
Sponsored by:	The FreeBSD Foundation
2016-02-05 20:56:11 +00:00
Ed Maste
23541160bb readelf: avoid accidental fallthrough in RISC-V relocations
This would have printed an unknown RISC-V relocation type as a SPARC
relocation.

CID:		1331398
Obtained from:	ELF Tool Chain r3283
Sponsored by:	The FreeBSD Foundation
2016-02-05 20:54:51 +00:00
Bjoern A. Zeeb
ce42ce038e Try to fix a bug introduced in r228623. We started to copy the ifa_msghdr
as otherwise platforms with strict alignment would break.  It's unclear
to me if there's also a problem with access to the address list following
the structure.  However we never copied the address list after the structure
and thus are pointing at random memory.  For now just use a pointer to the
original memory for accessing the address list making it at least work on
platforms with weak memory access.

PR:			195445
Reported by:		wolfgang lyxys.ka.sub.org
Tested by:		wolfgang lyxys.ka.sub.org (x86)
MFC after:		3 days
2016-02-03 11:03:44 +00:00
Pedro F. Giffuni
2d004dd5bc MFV r295109:
Update openresolve to version 3.7.2

Relnotes:	yes
2016-02-02 21:10:43 +00:00
Maxim Sobolev
1d854f3d3e Root out files that don't really belong here and could in fact screw
you over if you happen to use git for FreeBSD development, as it is
the case with the unbound/.gitignore, which lits files that are
actually required for the buildworld.

MFC after:	1 day
2016-02-02 19:04:40 +00:00
Hans Petter Selasky
b340491939 Use LIBADD instead of LDADD.
Sponsored by:	Mellanox Technologies
2016-02-02 11:36:58 +00:00
Enji Cooper
833525a88a Add #include <string.h> to mute warning from clang/gcc about implicitly
declaring strcmp(3)

MFC after: 1 month
Reported by: Jenkins
Sponsored by: EMC / Isilon Storage Division
2016-02-01 07:09:08 +00:00
Dimitry Andric
752d00608c Merge ^/head r294777 through r294960. 2016-01-27 22:52:20 +00:00
Dimitry Andric
21cf1fd41c Update llvm, clang and lldb to release_38 branch r258968. 2016-01-27 22:48:52 +00:00
Alan Somers
eaae77f810 Fix grep_test:recurse with ZFS and TMPFS tmpdirs
contrib/netbsd-tests/usr.bin/grep/t_grep.sh
	Fix grep_test:recurse when /tmp is either zfs or tmpfs. The test was
	relying on an implicit ordering of directory recursion which happens
	to be true when using UFS. grep's specification requires no such
	ordering. The solution is to ignore the order of grep's results.

Reviewed by:	ngie
MFC after:	32 days
Sponsored by:	Spectra Logic Corp
Differential Revision:	https://reviews.freebsd.org/D4925
2016-01-27 16:13:10 +00:00
Enji Cooper
6144b07f9b Add debug output via ATF_REQUIRE_MSG when the first call to
mlock(2) fails

This helps identify the problem with running this test on my VM
hosts (ENOMEM)

MFC after: 3 days
Sponsored by: EMC / Isilon Storage Division
2016-01-27 07:06:49 +00:00
Enji Cooper
8e62f8414e Adjust vm.max_wired in order to avoid hitting EAGAIN artificially
Set vm.max_wired to INT_MAX in :mlock_err, :mlock_mmap, and :mlock_nested to
avoid hitting EAGAIN artificially on the system when running the tests

Require root privileges in order to set the sysctl

Add allow_sysctl_side_effects to require.config as this test is now adjusting
sysctls that can affect the global system state

Unlike the version submitted by cem in OneFS, this version uses a scratch file
to save/restore the previous value of the sysctl. I _really_, _really_ wish
there were better hooks in atf/kyua for per test suite setup/teardown -- using
a file is kludgy, but it's the best I can do to avoid situations where (for
instance), sysctl(3) may fail and drop a core outside the kyua sandbox.

Based on a patch submitted by cem, but modified to take business logic out of
ATF_TP_ADD_TCS(3).

Differential Revision: https://reviews.freebsd.org/D4779
MFC after: 1 month
Sponsored by: EMC / Isilon Storage Division
2016-01-27 06:24:19 +00:00
Gleb Smirnoff
a781766836 Grab value for LEAF_tcpCurrEstab from net.inet.tcp.stats instead of
net.inet.tcp.pcblist, which is much cheaper.
2016-01-27 00:50:27 +00:00
Dimitry Andric
14d5c08ba8 Merge ^/head r294599 through r294776. 2016-01-26 07:49:11 +00:00
Navdeep Parhar
361e428888 Use LIBADD instead of LDADD in rping's Makefile and add libcxgb4 (the
userspace iWARP library for cxgbe) to the list of libraries.

rping using the libcxgb4 + iw_cxgbe combo was tested with T5 hardware.

Obtained from:	Chelsio Communications
2016-01-26 01:02:19 +00:00
Ruslan Bukin
4f0a4502a1 Add config for RISC-V ISA.
Reviewed by:	emaste
Sponsored by:	DARPA, AFRL
Sponsored by:	HEIF5
Differential Revision:	https://reviews.freebsd.org/D5046
2016-01-24 15:12:49 +00:00
Ruslan Bukin
a3e762571c Add a minimal gcc config for RISC-V.
This is required to build csu.

Reviewed by:	andrew
Sponsored by:	DARPA, AFRL
Sponsored by:	HEIF5
Differential Revision:	https://reviews.freebsd.org/D5039
2016-01-23 15:33:11 +00:00
Dimitry Andric
8c24ff90c4 Update llvm and clang to release_38 branch r258549. 2016-01-22 21:50:08 +00:00
Dimitry Andric
d9b9dae1a9 Merge ^/head r294169 through r294598. 2016-01-22 20:41:56 +00:00
Ruslan Bukin
e79b31967d Add support for RISC-V ISA.
Reviewed by:	emaste
Sponsored by:	DARPA, AFRL
Sponsored by:	HEIF5
Differential Revision:	https://reviews.freebsd.org/D5021
2016-01-22 16:59:06 +00:00
Ruslan Bukin
bdffadedf5 Add stubs for RISC-V ISA so libunwind can be compiled.
Reviewed by:	emaste
Sponsored by:	DARPA, AFRL
Sponsored by:	HEIF5
Differential Revision:	https://reviews.freebsd.org/D5035
2016-01-22 16:42:06 +00:00
Ruslan Bukin
47f9f6eb3a Add configuration for RISC-V ISA.
Reviewed by:	emaste
Sponsored by:	DARPA, AFRL
Sponsored by:	HEIF5
Differential Revision:	https://reviews.freebsd.org/D5020
2016-01-22 16:37:26 +00:00
Bjoern A. Zeeb
54902c0a6a Change the variable to a #define in order to make gcc happy which
otherwise will complain about "variably modified 'alias' at file scope".
Unbreaks the build on gcc platforms.
2016-01-22 15:03:22 +00:00
Xin LI
68ba7e87e7 MFV r294491: ntp 4.2.8p6.
Security:	CVE-2015-7973, CVE-2015-7974, CVE-2015-7975
Security:	CVE-2015-7976, CVE-2015-7977, CVE-2015-7978
Security:	CVE-2015-7979, CVE-2015-8138, CVE-2015-8139
Security:	CVE-2015-8140, CVE-2015-8158
With hat:	so
2016-01-22 07:32:39 +00:00
Hartmut Brandt
5edd0d3a4d Fill the ifAlias leaf of the ifXTable with the interface description
if there is one available and it fits into the maximum size (64 characters).
2016-01-21 16:11:20 +00:00
Dimitry Andric
5e23bfeb2d Pull in r258110 from upstream clang trunk, by Faisal Vali:
Fix PR26134: When substituting into default template arguments, keep
  CurContext unchanged.

  Or, do not set Sema's CurContext to the template declaration's when
  substituting into default template arguments of said template
  declaration.
  If we do push the template declaration context on to Sema, and the
  template declaration is at namespace scope, Sema can get confused and
  try and do odr analysis when substituting into default template
  arguments, even though the substitution could be occurring within a
  dependent context.
  I'm not sure why this was being done, perhaps there was concern that
  if a default template argument referred to a previous template
  parameter, it might not be found during substitution - but all
  regression tests pass, and I can't craft a test that would cause it
  to fails (if some one does, please inform me, and i'll craft a
  different fix for the PR).

  This patch removes a single line of code, but unfortunately adds more
  than it removes, because of the tests.  Some day I still hope to
  commit a patch that removes far more lines than it adds, while
  leaving clang better for it ;)

  Sorry that r253590 ("Change the expression evaluation context from
  Unevaluated to ConstantEvaluated while substituting into non-type
  template argument defaults") caused the PR!

This fix will be merged to the upstream release_38 branch soon, but we
need it now, to fix a failure in the databases/sfcgal port.
2016-01-19 18:57:37 +00:00
Xin LI
9123584634 MFV r294260:
Fix a wrong assertion in mandoc by applying OpenBSD
main.c,v 1.170 (florian):

Unbreak reading from stdin after recent parse() restructuring.
OK schwarze@
2016-01-18 08:52:09 +00:00
Dimitry Andric
47d45e347a Pull in r257977 from upstream llvm trunk, by Keno Fischer:
[DwarfDebug] Move MergeValues to .cpp, NFC

Pull in r257979 from upstream llvm trunk, by Keno Fischer:

  [DwarfDebug] Don't merge DebugLocEntries if their pieces overlap

  Summary:
  Later in DWARF emission we check that DebugLocEntries have
  non-overlapping pieces, so we should create any such entries
  by merging here.

  Fixes PR26163.

  Reviewers: aprantl
  Differential Revision: http://reviews.llvm.org/D16249

Again, these will be merged to the official release_38 branch soon, but
we need them ASAP.
2016-01-16 18:04:22 +00:00
Dimitry Andric
cdd9644c82 Pull in r257902 from upstream llvm trunk, by James Y Knight (this will
be merged to the official release_38 branch soon, but we need it ASAP):

  Stop increasing alignment of externally-visible globals on ELF
  platforms.

  With ELF, the alignment of a global variable in a shared library will
  get copied into an executables linked against it, if the executable even
  accesss the variable. So, it's not possible to implicitly increase
  alignment based on access patterns, or you'll break existing binaries.

  This happened to affect libc++'s std::cout symbol, for example. See
  thread: http://thread.gmane.org/gmane.comp.compilers.clang.devel/45311

  (This is a re-commit of r257719, without the bug reported in
  PR26144. I've tweaked the code to not assert-fail in
  enforceKnownAlignment when computeKnownBits doesn't recurse far enough
  to find the underlying Alloca/GlobalObject value.)

  Differential Revision: http://reviews.llvm.org/D16145
2016-01-16 18:00:58 +00:00
Dimitry Andric
5673a0f918 Undo r289072, which reverted upstream llvm trunk r240144. This is going
to be fixed for real by importing upstream llvm trunk r257902.
2016-01-16 17:57:54 +00:00
Dimitry Andric
98665a5875 Update llvm, clang and lldb to release_38 branch r257836. 2016-01-16 17:48:57 +00:00
Dimitry Andric
7aa11cde7e Merge ^head r294090 through r294168. 2016-01-16 17:33:09 +00:00
Baptiste Daroussin
2b774394cc Update mandoc to 20160116 2016-01-15 23:28:12 +00:00
Dimitry Andric
444ed5c5eb Update llvm, clang and lldb to trunk r257626, and update build glue. 2016-01-14 17:42:46 +00:00
Dimitry Andric
89d3f0ea4e Merge ^/head r293430 through r293685. 2016-01-11 19:36:44 +00:00
Dimitry Andric
c5f07d2cb6 After upstream llvm trunk r252903 and clang trunk r252904, -mcpu=xscale
was not recognized anymore for arm targets.  Fix this by adding the
correct sub-arch to the xscale definition in ARMTargetParser.def.  This
fix (from Andrew Turner) has also been submitted upstream.
2016-01-11 19:29:12 +00:00
Sepherosa Ziehau
868a59a7e2 hyperv/kvp_daemon: Make poll(2) block indefinitely
Submitted by:	Jun Su <junsu microsoft com>
Reviewed by:	Dexuan Cui <decui microsoft com>, me, adrain
Approved by:	adrian
Sponsored by:	Microsoft OSTC
Differential Revision:	https://reviews.freebsd.org/D4762
2016-01-11 03:30:16 +00:00
Dimitry Andric
8d93ab88a9 Reduce diffs between upstream lldb and ours. 2016-01-09 17:33:13 +00:00
Dimitry Andric
58df0addff Remove a few files missed in the last lldb import. 2016-01-09 17:31:16 +00:00
Dimitry Andric
b229c1a0b0 Merge ^/head r293280 through r293429. 2016-01-08 17:42:14 +00:00
Dimitry Andric
fdd1590a42 As submitted upstream in a review, avoid using undefined behavior in
llvm's LinkAllPasses.h.  This caused some of the calls not to be
emitted, if the optimization level was -O2 or higher.

Conversely, if you used -O1 or lower, calls to e.g.  RunningOnValgrind()
would be emitted, leading to link failures, because we did not include
Valgrind.cpp into libllvmsupport.  Therefore, add it unconditionally.

Noticed by:	ian
2016-01-08 17:32:42 +00:00
Xin LI
3311ff84ea MFV r293415:
ntp 4.2.8p5

Reviewed by:	cy, roberto
Relnotes:	yes
Differential Revision:	https://reviews.freebsd.org/D4828
2016-01-08 15:53:48 +00:00
Dimitry Andric
7d04351452 As a quick fix, import r257103 from upstream llvm trunk, and r257104
from upstream clang trunk, which sets the default debug tuning back to
gdb.  The lldb debug tuning is not yet grokked completely by our ELF
manipulation tools.
2016-01-07 22:47:27 +00:00