Commit Graph

17 Commits

Author SHA1 Message Date
Eric Christopher
1cf9e7ff96 Fix typo.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@196434 91177308-0d34-0410-b5e6-96231b3b80d8
2013-12-04 23:55:09 +00:00
Chandler Carruth
0b8c9a80f2 Move all of the header files which are involved in modelling the LLVM IR
into their new header subdirectory: include/llvm/IR. This matches the
directory structure of lib, and begins to correct a long standing point
of file layout clutter in LLVM.

There are still more header files to move here, but I wanted to handle
them in separate commits to make tracking what files make sense at each
layer easier.

The only really questionable files here are the target intrinsic
tablegen files. But that's a battle I'd rather not fight today.

I've updated both CMake and Makefile build systems (I think, and my
tests think, but I may have missed something).

I've also re-sorted the includes throughout the project. I'll be
committing updates to Clang, DragonEgg, and Polly momentarily.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@171366 91177308-0d34-0410-b5e6-96231b3b80d8
2013-01-02 11:36:10 +00:00
Chandler Carruth
d04a8d4b33 Use the new script to sort the includes of every file under lib.
Sooooo many of these had incorrect or strange main module includes.
I have manually inspected all of these, and fixed the main module
include to be the nearest plausible thing I could find. If you own or
care about any of these source files, I encourage you to take some time
and check that these edits were sensible. I can't have broken anything
(I strictly added headers, and reordered them, never removed), but they
may not be the headers you'd really like to identify as containing the
API being implemented.

Many forward declarations and missing includes were added to a header
files to allow them to parse cleanly when included first. The main
module rule does in fact have its merits. =]

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@169131 91177308-0d34-0410-b5e6-96231b3b80d8
2012-12-03 16:50:05 +00:00
Craig Topper
e329810482 Mark some static arrays as const.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@157377 91177308-0d34-0410-b5e6-96231b3b80d8
2012-05-24 06:35:32 +00:00
Eli Friedman
e6109828d7 Fix a stupid typo in MemDepPrinter.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@146549 91177308-0d34-0410-b5e6-96231b3b80d8
2011-12-14 02:54:39 +00:00
Eli Friedman
b414142036 Enhance the memdep interface so that users can tell the difference between a dependency which cannot be calculated and a path reaching the entry point of the function. This patch introduces isNonFuncLocal, which replaces isUnknown in some cases.
Patch by Xiaoyi Guo.



git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@141896 91177308-0d34-0410-b5e6-96231b3b80d8
2011-10-13 22:14:57 +00:00
Eli Friedman
667ccf231b Misc analysis passes that need to be aware of atomic load/store.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@137650 91177308-0d34-0410-b5e6-96231b3b80d8
2011-08-15 20:54:19 +00:00
Eli Friedman
a990e071f2 Add "unknown" results for memdep, which mean "I don't know whether a dependence for the given instruction exists in the given block". This cleans up all the existing hacks in memdep which represent this concept by returning clobber with various unrelated instructions.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@133031 91177308-0d34-0410-b5e6-96231b3b80d8
2011-06-15 00:47:34 +00:00
Dan Gohman
6d8eb156e6 Add helper functions for computing the Location of load, store,
and vaarg instructions.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@118845 91177308-0d34-0410-b5e6-96231b3b80d8
2010-11-11 21:50:19 +00:00
Dan Gohman
075fb5d68f Enhance GVN to do more precise alias queries for non-local memory
references. For example, this allows gvn to eliminate the load in
this example:

  void foo(int n, int* p, int *q) {
    p[0] = 0;
    p[1] = 1;
    if (n) {
      *q = p[0];
    }
  }


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@118714 91177308-0d34-0410-b5e6-96231b3b80d8
2010-11-10 20:37:15 +00:00
Dan Gohman
adb30d211b Memdep says that an instruction clobbers itself
when it means there is no specific clobber instruction.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@116960 91177308-0d34-0410-b5e6-96231b3b80d8
2010-10-20 22:37:41 +00:00
Owen Anderson
081c34b725 Get rid of static constructors for pass registration. Instead, every pass exposes an initializeMyPassFunction(), which
must be called in the pass's constructor.  This function uses static dependency declarations to recursively initialize
the pass's dependencies.

Clients that only create passes through the createFooPass() APIs will require no changes.  Clients that want to use the
CommandLine options for passes will need to manually call the appropriate initialization functions in PassInitialization.h
before parsing commandline arguments.

I have tested this with all standard configurations of clang and llvm-gcc on Darwin.  It is possible that there are problems
with the static dependencies that will only be visible with non-standard options.  If you encounter any crash in pass
registration/creation, please send the testcase to me directly.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@116820 91177308-0d34-0410-b5e6-96231b3b80d8
2010-10-19 17:21:58 +00:00
Owen Anderson
2ab36d3502 Begin adding static dependence information to passes, which will allow us to
perform initialization without static constructors AND without explicit initialization
by the client.  For the moment, passes are required to initialize both their
(potential) dependencies and any passes they preserve.  I hope to be able to relax
the latter requirement in the future.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@116334 91177308-0d34-0410-b5e6-96231b3b80d8
2010-10-12 19:48:12 +00:00
Owen Anderson
ce665bd2e2 Now with fewer extraneous semicolons!
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@115996 91177308-0d34-0410-b5e6-96231b3b80d8
2010-10-07 22:25:06 +00:00
Dan Gohman
8945db73d1 Add an #include of raw_ostream.h. Previously, this only compiled
because it was using Twine.h's declaration of operator<<(const Twine &).


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@114141 91177308-0d34-0410-b5e6-96231b3b80d8
2010-09-17 00:33:43 +00:00
Dan Gohman
a627e9bfcd Rename a variable to avoid a declaration conflict.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@114126 91177308-0d34-0410-b5e6-96231b3b80d8
2010-09-16 22:50:09 +00:00
Dan Gohman
ead0109f5b Add a pass which prints out all the memdep dependencies.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@114121 91177308-0d34-0410-b5e6-96231b3b80d8
2010-09-16 22:08:32 +00:00