Commit Graph

6426 Commits

Author SHA1 Message Date
Reid Kleckner
36850aafe2 Fix some remaining documentation references to MSVC 2013
MSVC 2015 has been the minimum supported version of VS since October.

Differential Revision: https://reviews.llvm.org/D25710

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@289854 91177308-0d34-0410-b5e6-96231b3b80d8
2016-12-15 19:08:02 +00:00
Kostya Serebryany
94ab0f2699 [libFuzzer] doc update
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@289849 91177308-0d34-0410-b5e6-96231b3b80d8
2016-12-15 18:47:22 +00:00
Pavel Labath
2ef2a887ad Simplify format member detection in FormatVariadic
Summary:
This replaces the format member search, which was quite complicated, with a more
direct approach to detecting whether a class should be formatted using the
format-member method. Instead we use a special type llvm::format_adapter, which
every adapter must inherit from. Then the search can be simply implemented with
the is_base_of type trait.

Aside from the simplification, I like this way more because it makes it more
explicit that you are supposed to use this type only for adapter-like
formattings, and the other approach (format_provider overloads) should be used
as a default (a mistake I made when first trying to use this library).

The only slight change in behaviour here is that now choose the format-adapter
branch even if the format member invocation will fail to compile (e.g. because it is a
non-const member function and we are passing a const adapter), whereas
previously we would have gone on to search for format_providers for the type.
However, I think that is actually a good thing, as it probably means the
programmer did something wrong.

Reviewers: zturner, inglorion

Subscribers: llvm-commits

Differential Revision: https://reviews.llvm.org/D27679

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@289795 91177308-0d34-0410-b5e6-96231b3b80d8
2016-12-15 09:40:27 +00:00
Hal Finkel
fe647d2183 Make processing @llvm.assume more efficient by using operand bundles
There was an efficiency problem with how we processed @llvm.assume in
ValueTracking (and other places). The AssumptionCache tracked all of the
assumptions in a given function. In order to find assumptions relevant to
computing known bits, etc. we searched every assumption in the function. For
ValueTracking, that means that we did O(#assumes * #values) work in InstCombine
and other passes (with a constant factor that can be quite large because we'd
repeat this search at every level of recursion of the analysis).

Several of us discussed this situation at the last developers' meeting, and
this implements the discussed solution: Make the values that an assume might
affect operands of the assume itself. To avoid exposing this detail to
frontends and passes that need not worry about it, I've used the new
operand-bundle feature to add these extra call "operands" in a way that does
not affect the intrinsic's signature. I think this solution is relatively
clean. InstCombine adds these extra operands based on what ValueTracking, LVI,
etc. will need and then those passes need only search the users of the values
under consideration. This should fix the computational-complexity problem.

At this point, no passes depend on the AssumptionCache, and so I'll remove
that as a follow-up change.

Differential Revision: https://reviews.llvm.org/D27259

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@289755 91177308-0d34-0410-b5e6-96231b3b80d8
2016-12-15 02:53:42 +00:00
Kostya Serebryany
68f637f244 [libFuzzer] document one more desired feature of a fuzz target
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@289622 91177308-0d34-0410-b5e6-96231b3b80d8
2016-12-14 01:31:21 +00:00
Peter Collingbourne
b29976c54b IR, X86: Understand !absolute_symbol metadata on global variables.
Summary:
Attaching !absolute_symbol to a global variable does two things:
1) Marks it as an absolute symbol reference.
2) Specifies the value range of that symbol's address.
Teach the X86 backend to allow absolute symbols to appear in place of
immediates by extending the relocImm and mov64imm32 matchers. Start using
relocImm in more places where it is legal.

As previously proposed on llvm-dev:
http://lists.llvm.org/pipermail/llvm-dev/2016-October/105800.html

Differential Revision: https://reviews.llvm.org/D25878

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@289087 91177308-0d34-0410-b5e6-96231b3b80d8
2016-12-08 19:01:00 +00:00
Keno Fischer
3f98c183ca Revert "[CodeGen] Fix invalid DWARF info on Win64"
Appears to break on build bots. Reverting pending investigation.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@289014 91177308-0d34-0410-b5e6-96231b3b80d8
2016-12-08 01:56:23 +00:00
Keno Fischer
94c20c0a62 [CodeGen] Fix invalid DWARF info on Win64
The relocations for `DIEEntry::EmitValue` were wrong for Win64
(emitting FK_Data_4 instead of FK_SecRel_4). This corrects that
oversight so that the DWARF data is correct in Win64 COFF files.

Fixes PR15393.

Patch by Jameson Nash <jameson@juliacomputing.com> based on a patch
by David Majnemer.

Differential Revision: https://reviews.llvm.org/D21731

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@289013 91177308-0d34-0410-b5e6-96231b3b80d8
2016-12-08 01:40:21 +00:00
Mehdi Amini
bb4cc15a59 [doc] Add .arcconfig setup to the "how to work with a monorepo" section
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@288562 91177308-0d34-0410-b5e6-96231b3b80d8
2016-12-03 01:04:40 +00:00
Peter Collingbourne
a705e0edef IR: Move NumElements field from {Array,Vector}Type to SequentialType.
Now that PointerType is no longer a SequentialType, all SequentialTypes
have an associated number of elements, so we can move that information to
the base class, allowing for a number of simplifications.

Differential Revision: https://reviews.llvm.org/D27122

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@288464 91177308-0d34-0410-b5e6-96231b3b80d8
2016-12-02 03:20:58 +00:00
Peter Collingbourne
9c9ec72b63 IR: Change PointerType to derive from Type rather than SequentialType.
As proposed on llvm-dev:
http://lists.llvm.org/pipermail/llvm-dev/2016-October/106640.html

This is for a couple of reasons:

- Values of type PointerType are unlike the other SequentialTypes (arrays
  and vectors) in that they do not hold values of the element type. By moving
  PointerType we can unify certain aspects of how the other SequentialTypes
  are handled.
- PointerType will have no place in the SequentialType hierarchy once
  pointee types are removed, so this is a necessary step towards removing
  pointee types.

Differential Revision: https://reviews.llvm.org/D26595

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@288462 91177308-0d34-0410-b5e6-96231b3b80d8
2016-12-02 03:05:41 +00:00
Jonas Devlieghere
fc89a6a1e9 Revert 'Test commit as per developer policy'
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@288233 91177308-0d34-0410-b5e6-96231b3b80d8
2016-11-30 08:24:43 +00:00
Jonas Devlieghere
bc02eec1d3 Test commit as per developer policy
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@288232 91177308-0d34-0410-b5e6-96231b3b80d8
2016-11-30 08:06:23 +00:00
Zachary Turner
29916a15c8 Add documentation for the PDB Module Info stream.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@288205 91177308-0d34-0410-b5e6-96231b3b80d8
2016-11-29 22:14:56 +00:00
Mehdi Amini
c72d18a2cb [docs] Typos and whitespace fixed in LTO docs.
While reading the LTO docs I fixed few small typos and whitespace issues.

Patch by: Jonas Devlieghere <jonas@devlieghere.com>

Differential Revision: https://reviews.llvm.org/D27196

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@288171 91177308-0d34-0410-b5e6-96231b3b80d8
2016-11-29 18:00:31 +00:00
Yichao Yu
3806d81f86 Fix doc of llvm.bitreverse.iN
Summary:
The return type is `iN` rather than always `i16`

Seems to be a typo in https://reviews.llvm.org/rL252878 .

Reviewers: jmolloy

Subscribers: llvm-commits

Differential Revision: https://reviews.llvm.org/D27047

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@287769 91177308-0d34-0410-b5e6-96231b3b80d8
2016-11-23 16:25:31 +00:00
Justin Lebar
ac4f8e1d52 [CUDA] Note in docs that you need to build with -lcudart on MacOS
-lcudart_static doesn't work.  We don't know why.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@287715 91177308-0d34-0410-b5e6-96231b3b80d8
2016-11-22 23:13:29 +00:00
Matthias Braun
9262f00f1a Timer: Track name and description.
The previously used "names" are rather descriptions (they use multiple
words and contain spaces), use short programming language identifier
like strings for the "names" which should be used when exporting to
machine parseable formats.

Also removed a unused TimerGroup from Hexxagon.

Differential Revision: https://reviews.llvm.org/D25583

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@287369 91177308-0d34-0410-b5e6-96231b3b80d8
2016-11-18 19:43:18 +00:00
Craig Topper
3d85988107 [Docs][TableGen] Remove reference to tablegen supporting octal integers. It doesn't and hasn't for at least 9 years.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@287299 91177308-0d34-0410-b5e6-96231b3b80d8
2016-11-18 02:28:50 +00:00
Justin Lebar
e65e5ddefe [CUDA] Update docs to indicate that MacOS is now supported.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@287290 91177308-0d34-0410-b5e6-96231b3b80d8
2016-11-18 00:42:00 +00:00
Justin Lebar
46f85978dc [CUDA] Update docs; CUDA 8.0 is supported as of a while ago.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@287289 91177308-0d34-0410-b5e6-96231b3b80d8
2016-11-18 00:41:40 +00:00
Dylan McKay
b28b8f21ef [ReleaseNotes] Mention the completion of the upstreaming of the AVR backend
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@287273 91177308-0d34-0410-b5e6-96231b3b80d8
2016-11-17 22:26:09 +00:00
Kostya Serebryany
f6d63ccc90 [libFuzzer] better documentation for -fsanitize-coverage=trace-cmp
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@287240 91177308-0d34-0410-b5e6-96231b3b80d8
2016-11-17 17:31:54 +00:00
Justin Lebar
38b5ba060c [CUDA] Update docs to indicate that clang now supports std::complex in CUDA mode.
The last remaining necessary change was D25403, landed as r287012.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@287184 91177308-0d34-0410-b5e6-96231b3b80d8
2016-11-17 01:03:42 +00:00
Dean Michael Berris
30d8d0833f [XRay][docs] Define requirements on installed log handlers.
Summary:
We update the documentation to define what the requirements are for the
provided XRay log handler. This is to make it clear that the function
pointer provided must do internal synchronisation and that there are no
guarantees provided by XRay on when the function shall be invoked once
it has been installed as a log handler.

Reviewers: rSerge, rengolin

Subscribers: llvm-commits

Differential Revision: https://reviews.llvm.org/D26651

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@287073 91177308-0d34-0410-b5e6-96231b3b80d8
2016-11-16 02:18:23 +00:00
Matt Arsenault
ee23318db7 TableGen: Add operator !or
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@286936 91177308-0d34-0410-b5e6-96231b3b80d8
2016-11-15 06:49:28 +00:00
Zachary Turner
576eea861d [PDB] Add documentation for the DBI Stream.
Differential Revision: https://reviews.llvm.org/D26552

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@286853 91177308-0d34-0410-b5e6-96231b3b80d8
2016-11-14 17:59:28 +00:00
Zachary Turner
3b7c9b9cdb [PDB] Add documentation for the PDB Stream.
https://reviews.llvm.org/D26516

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@286852 91177308-0d34-0410-b5e6-96231b3b80d8
2016-11-14 17:59:21 +00:00
Sanjoy Das
00eb18da3b [LangRef] Drop misleading anecdote
`shl nsw i8 1, i8 8` is poison, but `mul i8 1, i8 128` is not.

This was discussed previously here:
http://lists.llvm.org/pipermail/llvm-dev/2015-April/084195.html.  From
the discussion, it was not clear which semantics we want for `shl`, but
for now at least make the language reference more accurate.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@286785 91177308-0d34-0410-b5e6-96231b3b80d8
2016-11-13 23:40:40 +00:00
Sylvestre Ledru
8a6ccbeaaa As we released 3.9, from the 4.0 release notes, points to version 3.9 instead of 3.8
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@286719 91177308-0d34-0410-b5e6-96231b3b80d8
2016-11-12 10:39:09 +00:00
whitequark
18c0ee2638 [OCaml] Adapt to the new attribute C API.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@286705 91177308-0d34-0410-b5e6-96231b3b80d8
2016-11-12 03:38:30 +00:00
Kostya Serebryany
be3001891b [libFuzzer] one more trophy
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@286703 91177308-0d34-0410-b5e6-96231b3b80d8
2016-11-12 02:55:45 +00:00
Zachary Turner
97dac2b41d [Support] Introduce llvm::formatv() function.
This introduces a new type-safe general purpose formatting
library.  It provides compile-time type safety, does not require
a format specifier (since the type is deduced), and provides
mechanisms for extending the format capability to user defined
types, and overriding the formatting behavior for existing types.

This patch additionally adds documentation for the API to the
LLVM programmer's manual.

Mailing List Thread:
http://lists.llvm.org/pipermail/llvm-dev/2016-October/105836.html

Differential Revision: https://reviews.llvm.org/D25587

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@286682 91177308-0d34-0410-b5e6-96231b3b80d8
2016-11-11 23:57:40 +00:00
Piotr Padlewski
797e9cdb75 NFC ProgrammersManual fix
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@286645 91177308-0d34-0410-b5e6-96231b3b80d8
2016-11-11 22:12:15 +00:00
Peter Collingbourne
ca668e1942 IR: Introduce inrange attribute on getelementptr indices.
If the inrange keyword is present before any index, loading from or
storing to any pointer derived from the getelementptr has undefined
behavior if the load or store would access memory outside of the bounds of
the element selected by the index marked as inrange.

This can be used, e.g. for alias analysis or to split globals at element
boundaries where beneficial.

As previously proposed on llvm-dev:
http://lists.llvm.org/pipermail/llvm-dev/2016-July/102472.html

Differential Revision: https://reviews.llvm.org/D22793

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@286514 91177308-0d34-0410-b5e6-96231b3b80d8
2016-11-10 22:34:55 +00:00
Zachary Turner
ab792ca2d9 [PDB] Begin adding documentation for the PDB file format.
Differential Revision: https://reviews.llvm.org/D26374

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@286491 91177308-0d34-0410-b5e6-96231b3b80d8
2016-11-10 19:24:21 +00:00
Sanjoy Das
40cc2d91fd [LangRef] Drop "experimental" caveat from operand bundles
I think we're past that point now.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@286428 91177308-0d34-0410-b5e6-96231b3b80d8
2016-11-10 06:21:10 +00:00
Dean Michael Berris
2adde22ecd [XRay][docs] Fix llvm snippets to be well-formed
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@286330 91177308-0d34-0410-b5e6-96231b3b80d8
2016-11-09 02:12:13 +00:00
Mehdi Amini
9e4483688b [doc] Remove explicit CMake version requirement for MSVC
The global minimum one is way past this version.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@286328 91177308-0d34-0410-b5e6-96231b3b80d8
2016-11-09 01:44:42 +00:00
Dean Michael Berris
f70da781a9 [XRay][Docs] Add documentation for XRay in LLVM
Summary:
This is the initial version of the documentation for how to use XRay as
it stands in LLVM, Clang, and compiler-rt. We leave some room for later
expansion mentioining what is work in progress and what could be
expected moving forward.

We also give a high level overview of future work that's both ongoing
and planned.

Reviewers: echristo, dblaikie, chandlerc

Subscribers: mehdi_amini, llvm-commits

Differential Revision: https://reviews.llvm.org/D26386

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@286319 91177308-0d34-0410-b5e6-96231b3b80d8
2016-11-09 00:24:58 +00:00
Kostya Serebryany
9a9bc142bf [libFuzzer] minor docs update
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@286299 91177308-0d34-0410-b5e6-96231b3b80d8
2016-11-08 21:57:37 +00:00
Sanjay Patel
a897799dc7 [docs] fix link to AMD manuals (PR30946)
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@286249 91177308-0d34-0410-b5e6-96231b3b80d8
2016-11-08 16:49:24 +00:00
Lang Hames
3fab9364ac [docs] Add a pointer to ExitOnError to the discussion of handleErrors in the
programmer's manual.

ExitOnError is often a better alternative to handleErrors for tool code. This
patch makes it easier to find the ExitOnError discussion when reading the
handleErrors section.

Thanks to Peter Collingbourne for the suggestion.



git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@286167 91177308-0d34-0410-b5e6-96231b3b80d8
2016-11-07 22:33:13 +00:00
Mehdi Amini
d2b417a57c [doc] Add documentation about how to use a monorepo
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@286163 91177308-0d34-0410-b5e6-96231b3b80d8
2016-11-07 22:14:09 +00:00
Mehdi Amini
ffe516c55a Add experimental support for unofficial monorepo-like directory layout
Summary:
This allows to have clang and llvm and the other subprojects
side-by-side instead of nested. This can be used with the monorepo or
multiple repos.

It will help having a single set of sources checked out but allows to
have a build directory with llvm and another one with llvm+clang.
Basically it abstracts LLVM_EXTERNAL_xxxx_SOURCE_DIR making it more
convenient by adopting a convention.

Reviewers: bogner, beanz, jlebar

Subscribers: mgorny, llvm-commits

Differential Revision: https://reviews.llvm.org/D26365

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@286162 91177308-0d34-0410-b5e6-96231b3b80d8
2016-11-07 22:13:38 +00:00
Mehdi Amini
ad83acaba5 Revert "Add some facilities to work with a git monorepo (experimental setup)"
This reverts commit r286123, accidentally commited while testing itself...

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@286124 91177308-0d34-0410-b5e6-96231b3b80d8
2016-11-07 17:43:08 +00:00
Mehdi Amini
644ae71ae0 Add some facilities to work with a git monorepo (experimental setup)
Summary:
Some changes are made to cmake, especially the addition of a new
LLVM_ENABLE_PROJECTS option that makes the build system aware of
the monorepo directory structure.

Also a new script is added in llvm/utils/git-svn/. When present in
the $PATH, it enables a `git llvm` command. It is providing at this
point only the ability to push from the git monorepo: `git llvm push`.
It is intended to evolves with more features, for instance I plan on
features like `git llvm show r284955` to help working with sequential
revision numbers.
The push feature is taken from Justin Lebar's script available here:
https://github.com/jlebar/llvm-repo-tools/

Reviewers: jlebar

Subscribers: mgorny, modocache, llvm-commits

Differential Revision: https://reviews.llvm.org/D26334

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@286123 91177308-0d34-0410-b5e6-96231b3b80d8
2016-11-07 17:40:28 +00:00
Brian Gesiak
069db88a3b Update CommandLine.rst getRegisteredOptions example
Summary: Update the docs to match the changes in http://reviews.llvm.org/D7132

Reviewers: beanz, llvm-commits, modocache

Differential Revision: https://reviews.llvm.org/D26296

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@286094 91177308-0d34-0410-b5e6-96231b3b80d8
2016-11-07 02:43:01 +00:00
Amaury Sechet
4a6fc8bacf Kill deprecated attribute API
Summary:
This kill various depreacated API related to attribute :
 - The deprecated C API attribute based on LLVMAttribute enum.
 - The Raw attribute set format (planned to be removed in 4.0).

Reviewers: bkramer, echristo, mehdi_amini, void

Subscribers: mehdi_amini, llvm-commits

Differential Revision: https://reviews.llvm.org/D23039

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@286062 91177308-0d34-0410-b5e6-96231b3b80d8
2016-11-06 07:48:46 +00:00
Ahmed Bougacha
bbf0c3a5ae [docs] Add initial Global ISel documentation.
This reflects the current state of Global ISel.  As progress is
made, we'll document our design decisions in it.
Comments very welcome!

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@286002 91177308-0d34-0410-b5e6-96231b3b80d8
2016-11-04 17:57:34 +00:00