History log of /external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
Revision Date Author Comments (<<< Hide modified files) (Show modified files >>>)
cd81d94322a39503e4a3e87b6ee03d4fcb3465fb 21-Jul-2014 Stephen Hines <srhines@google.com> Update LLVM for rebase to r212749.

Includes a cherry-pick of:
r212948 - fixes a small issue with atomic calls

Change-Id: Ib97bd980b59f18142a69506400911a6009d9df18
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
dce4a407a24b04eebc6a376f8e62b41aaa7b071f 29-May-2014 Stephen Hines <srhines@google.com> Update LLVM for 3.5 rebase (r209712).

Change-Id: I149556c940fb7dc92d075273c87ff584f400941f
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
36b56886974eae4f9c5ebc96befd3e7bfe5de338 24-Apr-2014 Stephen Hines <srhines@google.com> Update to LLVM 3.5a.

Change-Id: Ifadecab779f128e62e430c2b4f6ddd84953ed617
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
354362524a72b3fa43a6c09380b7ae3b2380cbba 19-Nov-2013 Juergen Ributzka <juergen@apple.com> [weak vtables] Remove a bunch of weak vtables

This patch removes most of the trivial cases of weak vtables by pinning them to
a single object file. The memory leaks in this version have been fixed. Thanks
Alexey for pointing them out.

Differential Revision: http://llvm-reviews.chandlerc.com/D2068

Reviewed by Andy

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@195064 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
b21ab43cfc3fa0dacf5c95f04e58b6d804b59a16 18-Nov-2013 Alexey Samsonov <samsonov@google.com> Revert r194865 and r194874.

This change is incorrect. If you delete virtual destructor of both a base class
and a subclass, then the following code:
Base *foo = new Child();
delete foo;
will not cause the destructor for members of Child class. As a result, I observe
plently of memory leaks. Notable examples I investigated are:
ObjectBuffer and ObjectBufferStream, AttributeImpl and StringSAttributeImpl.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@194997 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
5a364c5561ec04e33a6f5d52c14f1bac6f247ea0 15-Nov-2013 Juergen Ributzka <juergen@apple.com> [weak vtables] Remove a bunch of weak vtables

This patch removes most of the trivial cases of weak vtables by pinning them to
a single object file.

Differential Revision: http://llvm-reviews.chandlerc.com/D2068

Reviewed by Andy

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@194865 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
48079e0fef9301442eb787d2234ea99ba3f06fa8 15-Nov-2013 Andrew Kaylor <andrew.kaylor@intel.com> Don't try to initialize memory for a global if the allocation failed in ExecutionEngine.

Patch by Dale Martin!



git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@194831 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
d0acc84b2b98d7c4ba5057cfb004ecf9f9db6a3d 07-Oct-2013 Rafael Espindola <rafael.espindola@gmail.com> Remove dead code.

Support for exception handling in the legacy JIT was removed in r181354 and
this code was dead since then.

Thanks to Yaron Keren for noticing it.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@192101 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
3c5ce29cad9b8fab1a280ffd3bd1dbdb4b53ff5e 12-Sep-2013 Elena Demikhovsky <elena.demikhovsky@intel.com> LLVM Interpreter: implementation of "insertvalue" and "extractvalue";
undef constatnt for structure and test for these functions.

done by Yuri Veselov (mailto:Yuri.Veselov@intel.com)


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@190599 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
6227d5c690504c7ada5780c00a635b282c46e275 04-Jul-2013 Craig Topper <craig.topper@gmail.com> Use SmallVectorImpl::iterator/const_iterator instead of SmallVector to avoid specifying the vector size.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@185606 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
13a3cf192887233fb9452ec5b7f841e4652c33c7 14-May-2013 Filip Pizlo <fpizlo@apple.com> SectionMemoryManager shouldn't be a JITMemoryManager. Previously, the
EngineBuilder interface required a JITMemoryManager even if it was being used
to construct an MCJIT. But the MCJIT actually wants a RTDyldMemoryManager.
Consequently, the SectionMemoryManager, which is meant for MCJIT, derived
from the JITMemoryManager and then stubbed out a bunch of JITMemoryManager
methods that weren't relevant to the MCJIT.

This patch fixes the situation: it teaches the EngineBuilder that
RTDyldMemoryManager is a supertype of JITMemoryManager, and that it's
appropriate to pass a RTDyldMemoryManager instead of a JITMemoryManager if
we're using the MCJIT. This allows us to remove the stub methods from
SectionMemoryManager, and make SectionMemoryManager a direct subtype of
RTDyldMemoryManager.



git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@181820 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
21a01d1ea89dba97c4f9e1f9f41485729a4046bc 15-Apr-2013 Rafael Espindola <rafael.espindola@gmail.com> Make the host endianness check an integer constant expression.

I will remove the isBigEndianHost function once I update clang.

The ifdef logic is designed to
* not use configure/cmake to avoid breaking -arch i686 -arch ppc.
* default to little endian
* be as small as possible

It looks like sys/endian.h is the preferred header on most modern BSD systems,
but it is better to change this in a followup patch as machine/endian.h is
available on FreeBSD, OpenBSD, NetBSD and OS X.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@179527 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
953783e00c9934bc41077108fffeb1e2a17b00df 01-Apr-2013 Nadav Rotem <nrotem@apple.com> Add support for vector data types in the LLVM interpreter.

Patch by:
Veselov, Yuri <Yuri.Veselov@intel.com>



git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@178469 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
0a29cb045444c13160e90fe7942a9d7c720185ed 22-Jan-2013 Tim Northover <Tim.Northover@arm.com> Make APFloat constructor require explicit semantics.

Previously we tried to infer it from the bit width size, with an added
IsIEEE argument for the PPC/IEEE 128-bit case, which had a default
value. This default value allowed bugs to creep in, where it was
inappropriate.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@173138 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
c2680bef3b4994017d83293bc1337b26be54ac77 14-Jan-2013 David Greene <greened@obbligato.org> Fix Casting

Do proper casting to eliminate a const-away-cast compiler warning.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@172470 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
0b8c9a80f20772c3793201ab5b251d3520b9cea3 02-Jan-2013 Chandler Carruth <chandlerc@gmail.com> 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
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
98281a20503896349bd152e2dfe87435d3a6aada 30-Dec-2012 Nuno Lopes <nunoplopes@sapo.pt> convert a bunch of callers from DataLayout::getIndexedOffset() to GEP::accumulateConstantOffset().
The later API is nicer than the former, and is correct regarding wrap-around offsets (if anyone cares).
There are a few more places left with duplicated code, which I'll remove soon.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@171259 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
d04a8d4b33ff316ca4cf961e06c9e312eff8e64f 03-Dec-2012 Chandler Carruth <chandlerc@gmail.com> 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
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
426c2bf5cdd2173e4a33aea8cb92cf684a724f4b 01-Nov-2012 Chandler Carruth <chandlerc@gmail.com> Revert the majority of the next patch in the address space series:

r165941: Resubmit the changes to llvm core to update the functions to
support different pointer sizes on a per address space basis.

Despite this commit log, this change primarily changed stuff outside of
VMCore, and those changes do not carry any tests for correctness (or
even plausibility), and we have consistently found questionable or flat
out incorrect cases in these changes. Most of them are probably correct,
but we need to devise a system that makes it more clear when we have
handled the address space concerns correctly, and ideally each pass that
gets updated would receive an accompanying test case that exercises that
pass specificaly w.r.t. alternate address spaces.

However, from this commit, I have retained the new C API entry points.
Those were an orthogonal change that probably should have been split
apart, but they seem entirely good.

In several places the changes were very obvious cleanups with no actual
multiple address space code added; these I have not reverted when
I spotted them.

In a few other places there were merge conflicts due to a cleaner
solution being implemented later, often not using address spaces at all.
In those cases, I've preserved the new code which isn't address space
dependent.

This is part of my ongoing effort to clean out the partial address space
code which carries high risk and low test coverage, and not likely to be
finished before the 3.2 release looms closer. Duncan and I would both
like to see the above issues addressed before we return to these
changes.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@167222 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
bbc6e671b1a902c96aff152cc524a5ee6e253907 30-Oct-2012 Eli Friedman <eli.friedman@gmail.com> Fix regression in old-style JIT.



git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@167057 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
b52fb876171e3670e7307fda4459ca005d49d9f5 24-Oct-2012 Micah Villmow <villmow@gmail.com> Add some cleanup to the DataLayout changes requested by Chandler.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@166607 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
2c39b15073db81d93bb629303915b7d7e5d088dc 15-Oct-2012 Micah Villmow <villmow@gmail.com> Resubmit the changes to llvm core to update the functions to support different pointer sizes on a per address space basis.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@165941 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
fb384d61c78b60787ed65475d8403aee65023962 11-Oct-2012 Micah Villmow <villmow@gmail.com> Revert 165732 for further review.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@165747 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
f3840d2c16a4ec4c879a8ded402835746de380f8 11-Oct-2012 Micah Villmow <villmow@gmail.com> Add in the first iteration of support for llvm/clang/lldb to allow variable per address space pointer sizes to be optimized correctly.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@165726 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
3574eca1b02600bac4e625297f4ecf745f4c4f32 08-Oct-2012 Micah Villmow <villmow@gmail.com> Move TargetData to DataLayout.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@165402 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
59324297650c12a8dccf1a7ad650a9e895fdc17e 06-Sep-2012 Roman Divacky <rdivacky@freebsd.org> Stop casting away const qualifier needlessly.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@163258 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
8005bcd5e0c923881d82afcb813a7e537cd1b241 21-Aug-2012 Jim Grosbach <grosbach@apple.com> MCJIT: Tidy up the constructor.

The MCJIT doesn't need or want a TargetJITInfo. That's vestigal from the old
JIT, so just remove it.

rdar://12119347

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@162280 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
0f554492467064b3198df509227a3e902cf7cf1f 08-Apr-2012 Benjamin Kramer <benny.kra@googlemail.com> EngineBuilder::create is expected to take ownership of the TargetMachine passed to it. Delete it on error or when we create an interpreter that doesn't need it.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@154288 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
8e1fc56b2496270d1d6040cb648eef5d5aeb6079 23-Mar-2012 Owen Anderson <resistor@mac.com> Make it feasible for clients using EngineBuilder to capture the TargetMachine that is created as part of selecting the appropriate target.
This is necessary if the client wants to be able to mutate TargetOptions (for example, fast FP math mode) after the initial creation of the ExecutionEngine.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@153342 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
858143816d43e58b17bfd11cb1b57afbd7f0f893 07-Feb-2012 Craig Topper <craig.topper@gmail.com> Convert assert(0) to llvm_unreachable

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@149967 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
1ee0ecf84a07693c3a517ba030fac8ac1f9f3fbc 24-Jan-2012 Chris Lattner <sabre@nondot.org> add more support for ConstantDataSequential


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@148802 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
9ea47179e647e806a2c67639bfead9d254514e59 12-Dec-2011 Dylan Noblesmith <nobled@dreamwidth.org> ExecutionEngine: refactor interface

The OptLevel is now redundant with the TargetMachine*.
And selectTarget() isn't really JIT-specific and could probably
get refactored into one of the lower level libraries.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@146355 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
d40e103ea5bca8a223fc8261b3322b9454e9af12 08-Dec-2011 Peter Collingbourne <peter@pcc.me.uk> EngineBuilder: support for custom TargetOptions. Fixes the
ExceptionDemo example.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@146108 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
d95e67dac029d48984b72889a96a1bb389b8ac71 01-Dec-2011 Dylan Noblesmith <nobled@dreamwidth.org> ExecutionEngine: honor optimization level

It was getting ignored after r144788.

Also fix an accidental implicit cast from the OptLevel enum
to an optional bool argument. MSVC warned on this, but gcc
didn't.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@145633 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
34ad6db8b958fdc0d38e122edf753b5326e69b03 20-Jul-2011 Evan Cheng <evan.cheng@apple.com> - Move CodeModel from a TargetMachine global option to MCCodeGenInfo.
- Introduce JITDefault code model. This tells targets to set different default
code model for JIT. This eliminates the ugly hack in TargetMachine where
code model is changed after construction.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@135580 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
8fbbb3980755d74539a0aed02bc18842ed2bd18d 19-Jul-2011 Jay Foad <jay.foad@gmail.com> Convert TargetData::getIndexedOffset to use ArrayRef.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@135478 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
439661395fd2a2a832dba01c65bc88718528313c 19-Jul-2011 Evan Cheng <evan.cheng@apple.com> Introduce MCCodeGenInfo, which keeps information that can affect codegen
(including compilation, assembly). Move relocation model Reloc::Model from
TargetMachine to MCCodeGenInfo so it's accessible even without TargetMachine.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@135468 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
3ba292dbc2acee2d1052fb7ffe332e2164147b47 18-Jul-2011 Jeffrey Yasskin <jyasskin@google.com> Add APInt(numBits, ArrayRef<uint64_t> bigVal) constructor to prevent future ambiguity
errors like the one corrected by r135261. Migrate all LLVM callers of the old
constructor to the new one.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@135431 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
db125cfaf57cc83e7dd7453de2d509bc8efd0e5e 18-Jul-2011 Chris Lattner <sabre@nondot.org> land David Blaikie's patch to de-constify Type, with a few tweaks.



git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@135375 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
f5895e95926c96574888d7eb20b62d2cffe86193 14-May-2011 Dylan Noblesmith <nobled@dreamwidth.org> ExecutionEngine: move createJIT() definition (v2)

As an ExecutionEngine class function, its definition
really belongs in ExecutionEngine.cpp, not JIT.cpp.



git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@131320 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
c5b28580a94e247300e5d3ccf532e153f2ae6f12 13-May-2011 Dylan Noblesmith <nobled@dreamwidth.org> ExecutionEngine: push TargetMachine creation into clients (v2)

In particular, into EngineBuilder. This should only impact
the private API between the EE and EB classes, not external
clients, since JITCtor and MCJITCtor are both protected members.



git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@131317 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
701529b2488477d1887c2975677a574d1e90389f 07-May-2011 Jakob Stoklund Olesen <stoklund@2pi.dk> Revert ExecutionEngine patches, they either failed to build or broke unit tests.

Please ensure the build is clean and tests are passing when recommitting.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@131044 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
bfb8705d979e910133c8c6637e5a3fa2de6659ee 07-May-2011 Dylan Noblesmith <nobled@dreamwidth.org> ExecutionEngine: move createJIT() definition

As an ExecutionEngine class function, its definition
really belongs in ExecutionEngine.cpp, not JIT.cpp.



git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@131027 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
c06b511eba8a0f7c6dd01c067836168cc33d7801 07-May-2011 Dylan Noblesmith <nobled@dreamwidth.org> ExecutionEngine: push TargetMachine creation into clients

In particular, into EngineBuilder. This should only impact
the private API between the EE and EB classes, not external
clients, since JITCtor and MCJITCtor are both protected members.



git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@131026 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
80d9e072625bc49dab4fa2da6c21bdd202509ee3 28-Apr-2011 Chandler Carruth <chandlerc@gmail.com> Fix the last -Wnon-pod-memset I'm seeing. This is benign, but appears
a bit more sinister as the memset doesn't do what the constructor does.
There seems to be a cleaner solution than a cast here though, instead we
can point the memset destination into the union its actually trying to
clear.

An alternative is to point to the Untyped member of this union. Review
appreciated, and if that is cleaner I'm happy to switch. All of these
should be functionally equivalent to the original code.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@130395 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
5ea5c61589e62a1068746ddcc52c6aa39ec0f8b0 12-Apr-2011 Nick Lewycky <nicholas@mxc.ca> Just because a GlobalVariable's initializer is [N x { i32, void ()* }] doesn't
mean that it has to be ConstantArray of ConstantStruct. We might have
ConstantAggregateZero, at either level, so don't crash on that.

Also, semi-deprecate the sentinal value. The linker isn't aware of sentinals so
we end up with the two lists appended, each with their "sentinals" on them.
Different parts of LLVM treated sentinals differently, so make them all just
ignore the single entry and continue on with the rest of the list.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@129307 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
2c44a80d991df258a45e2f5fa76d5ada9e99015c 08-Apr-2011 Nick Lewycky <nicholas@mxc.ca> llvm.global_[cd]tor is defined to be either external, or appending with an array
of { i32, void ()* }. Teach the verifier to verify that, deleting copies of
checks strewn about.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@129128 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
a040d47c74341327997a50e88bb8ad4ceda6989f 06-Apr-2011 Nick Lewycky <nicholas@mxc.ca> Fix comment to use llvm 2.x syntax.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@129025 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
515c67ee77f8d9c417efc0fe04615d269bfb70e4 05-Mar-2011 Eric Christopher <echristo@apple.com> Support unregistering exception frames of functions when they are removed.

Patch by Johannes Schaub!

Fixes PR8548


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@127047 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
3069cbf7b3ef9a31bbb8e434686b7259052c364a 04-Dec-2010 Benjamin Kramer <benny.kra@googlemail.com> Remove unneeded zero arrays.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120910 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
1f6efa3996dd1929fbc129203ce5009b620e6969 29-Nov-2010 Michael J. Spencer <bigcheesegs@gmail.com> Merge System into Support.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120298 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
e4d19c9eb22899c9a555395d446a9ceef3bea7eb 28-Nov-2010 Jay Foad <jay.foad@gmail.com> PR5207: change APInt::doubleToBits() and APInt::floatToBits() to be
static methods that return a new APInt.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120261 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
6d135972bf4e7fdc4de6b0538d6a3b91a06e3a5d 17-Nov-2010 Daniel Dunbar <daniel@zuster.org> lli: Add stub -use-mcjit option, which doesn't currently do anything.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@119508 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
48dd875be12006060260526e4a1df0bae48dd5c9 13-Nov-2010 Daniel Dunbar <daniel@zuster.org> JIT: More nitty style tweakage, aka territory marking.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@118973 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
ab19da4bc087e79550ebe448d9edd4d8ed248388 13-Nov-2010 Daniel Dunbar <daniel@zuster.org> Fix 80-col violation / non-sensicalness.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@118958 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
b35fd448cea32da671ecd3ecaad3cc637598c6e0 21-Oct-2010 Duncan Sands <baldrick@free.fr> Fix the cleanup process of exception information in JIT. Now JIT
deregisters registered by it FDE structures allowing consecutive
JIT runs to succeed. Patch by Yuri. Fixes PR8285.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@117004 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
87565c1d779a1903d10ddd11d886c0f79ee430b5 15-May-2010 Chris Lattner <sabre@nondot.org> improve portability to systems that don't have powf/modf (e.g. solaris 9)
patch by Evzen Muller!



git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@103876 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
75361b69f3f327842b9dad69fa7f28ae3b688412 08-Apr-2010 Chris Lattner <sabre@nondot.org> rename llvm::llvm_report_error -> llvm::report_fatal_error



git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@100709 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
47b7112418a8c6ca23039ad5239cbc16091911a0 27-Mar-2010 Jeffrey Yasskin <jyasskin@google.com> Avoid leaking the memory allocated for GlobalVariables in the interpreter, by
freeing that memory when the GV is destroyed.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@99706 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
b19383818bcaf65509f4050c81f75c8ee0624f8c 26-Mar-2010 Jeffrey Yasskin <jyasskin@google.com> Avoid leaking argv and env arrays from lli.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@99589 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
1df9859c40492511b8aa4321eb76496005d3b75b 16-Feb-2010 Duncan Sands <baldrick@free.fr> There are two ways of checking for a given type, for example isa<PointerType>(T)
and T->isPointerTy(). Convert most instances of the first form to the second form.
Requested by Chris.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@96344 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
b0bc6c361da9009e8414efde317d9bbff755f6c0 15-Feb-2010 Duncan Sands <baldrick@free.fr> Uniformize the names of type predicates: rather than having isFloatTy and
isInteger, we now have isFloatTy and isIntegerTy. Requested by Chris!


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@96223 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
4688261c20735f5ead2f08695acdeb727db31894 05-Feb-2010 Jeffrey Yasskin <jyasskin@google.com> Move --march, --mcpu, and --mattr from JIT/TargetSelect.cpp to lli.cpp.
llc.cpp also defined these flags, meaning that when I linked all of LLVM's
libraries into a single shared library, llc crashed on startup with duplicate
flag definitions. This patch passes them through the EngineBuilder into
JIT::selectTarget().


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@95390 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
3a813dc7079135fa417d22f7b234e902a20c93ce 03-Feb-2010 Jeffrey Yasskin <jyasskin@google.com> r94686 changed all ModuleProvider parameters to Modules, which made the
1-argument ExecutionEngine::create(Module*) ambiguous with the signature that
used to be ExecutionEngine::create(ModuleProvider*, defaulted_params). Fixed
by removing the 1-argument create(). Fixes PR6221.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@95236 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
f0356fe140af1a30587b9a86bcfb1b2c51b8ce20 27-Jan-2010 Jeffrey Yasskin <jyasskin@google.com> Kill ModuleProvider and ghost linkage by inverting the relationship between
Modules and ModuleProviders. Because the "ModuleProvider" simply materializes
GlobalValues now, and doesn't provide modules, it's renamed to
"GVMaterializer". Code that used to need a ModuleProvider to materialize
Functions can now materialize the Functions directly. Functions no longer use a
magic linkage to record that they're materializable; they simply ask the
GVMaterializer.

Because the C ABI must never change, we can't remove LLVMModuleProviderRef or
the functions that refer to it. Instead, because Module now exposes the same
functionality ModuleProvider used to, we store a Module* in any
LLVMModuleProviderRef and translate in the wrapper methods. The bindings to
other languages still use the ModuleProvider concept. It would probably be
worth some time to update them to follow the C++ more closely, but I don't
intend to do it.

Fixes http://llvm.org/PR5737 and http://llvm.org/PR5735.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@94686 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
5b3701256c6706182ebfaeed8d50a66c6afe2a40 15-Jan-2010 Jay Foad <jay.foad@gmail.com> Fix http://llvm.org/PR6028, an assertion failure when an UndefValue of
integer type is used.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@93509 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
8c65f6e71c1d46d823b9a884819992a9255edd54 05-Jan-2010 Benjamin Kramer <benny.kra@googlemail.com> Move remaining stuff to the isInteger predicate.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@92771 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
f012705c7e4ca8cf90b6b734ce1d5355daca5ba5 05-Jan-2010 Benjamin Kramer <benny.kra@googlemail.com> Avoid going through the LLVMContext for type equality where it's safe to dereference the type pointer.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@92726 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
ae7c59a01286a3babbc6245dcb1049c7bcde2573 05-Jan-2010 David Greene <greened@obbligato.org> Change errs() to dbgs().

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@92621 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
88b5aca20a6dd0a8b15ff620bdee59aae567d245 17-Nov-2009 Eric Christopher <echristo@apple.com> Add ability to set code model within the execution engine builders
and creation interfaces.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@89151 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
6f348e458660063a40052b208bab96895c822877 09-Nov-2009 Jeffrey Yasskin <jyasskin@google.com> Remove dlsym stubs, with Nate Begeman's permission.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@86606 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
f32a6a3091e0b01d17926f4b1cf78972854b8cb5 29-Oct-2009 Chris Lattner <sabre@nondot.org> add interpreter support for indirect goto / blockaddress. The interpreter
now correctly runs clang's test/CodeGen/indirect-goto.c. The JIT will abort
on it until someone feels compelled to implement this.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@85488 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
dc85724f703bddf6988b6b3f20203beab775f32b 27-Oct-2009 Jeffrey Yasskin <jyasskin@google.com> Change the JIT to compile eagerly by default as agreed in
http://llvm.org/PR5184, and beef up the comments to describe what both options
do and the risks of lazy compilation in the presence of threads.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@85295 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
23e5fcfec4640955fec41dc8348f467adf1a3e56 24-Oct-2009 Jeffrey Yasskin <jyasskin@google.com> Fix http://llvm.org/PR4822: allow module deletion after a function has been
compiled.

When functions are compiled, they accumulate references in the JITResolver's
stub maps. This patch removes those references when the functions are
destroyed. It's illegal to destroy a Function when any thread may still try to
call its machine code.

This patch also updates r83987 to use ValueMap instead of explicit CallbackVHs
and fixes a couple "do stuff inside assert()" bugs from r84522.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@84975 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
4c5b23b24f230607fa18a162519875a91a5e89e0 13-Oct-2009 Jeffrey Yasskin <jyasskin@google.com> Make the ExecutionEngine automatically remove global mappings on when their
GlobalValue is destroyed. Function destruction still leaks machine code and
can crash on leaked stubs, but this is some progress.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@83987 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
c89d27a440370455336202b2a8f25eb9c73e67bc 10-Oct-2009 Jeffrey Yasskin <jyasskin@google.com> ExecutionEngine::clearGlobalMappingsFromModule failed to remove reverse
mappings, which could cause errors and assert-failures. This patch fixes that,
adds a test, and refactors the global-mapping-removal code into a single place.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@83678 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
ac53a0b272452013124bfc70480aea5e41b60f40 06-Oct-2009 Duncan Sands <baldrick@free.fr> Introduce and use convenience methods for getting pointer types
where the element is of a basic builtin type. For example, to get
an i8* use getInt8PtrTy.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@83379 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
cf0fe8d813727383d630055bb9d1cde21b00b7e7 05-Oct-2009 Chris Lattner <sabre@nondot.org> strength reduce a ton of type equality tests to check the typeid (Through
the new predicates I added) instead of going through a context and doing a
pointer comparison. Besides being cheaper, this allows a smart compiler
to turn the if sequence into a switch.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@83297 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
c72efbeb42a9eaa0a83b8bba4954dcaf9ae64103 23-Sep-2009 Chris Lattner <sabre@nondot.org> errorstr can be null, don't unconditionally set it. Only report that
"the jit has not been linked in" if the interpreter failed.

This fixes a unit test failure.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@82601 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
fbd39762e9db897ffd8e30ce7d387715cba6d4c1 23-Sep-2009 Chris Lattner <sabre@nondot.org> Make EngineBuilder return more error codes, by KS Sreeram.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@82600 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
3bc14202abb27a256e9aa05e697a792b679cdb16 24-Aug-2009 Chris Lattner <sabre@nondot.org> just remove interpreter support for endianness mismatches. This was
really old code from when we were running sparcv9 bc files on x86
(before I ported llvm-gcc 3 to work on x86) :)


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@79871 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
9f3ff92ca81fbceaa8ba805893f64f2a39f525d7 24-Aug-2009 Chris Lattner <sabre@nondot.org> remove use of alloca.h


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@79870 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
bbbfa99d3d18fe9f20265305e833666645ada528 23-Aug-2009 Chris Lattner <sabre@nondot.org> remove a few DOUTs here and there.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@79832 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
79c5d3f9717756dc3ff56cfcaa3ae1a5930c457a 23-Aug-2009 Chris Lattner <sabre@nondot.org> remove the std::ostream version of module and type printing.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@79823 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
1d0be15f89cb5056e20e2d24faa8d6afb1573bca 13-Aug-2009 Owen Anderson <resistor@mac.com> Push LLVMContexts through the IntegerType APIs.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@78948 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
0d5bd59553375dc85ac04c81ef48ef74c9e7193e 07-Aug-2009 Jeffrey Yasskin <jyasskin@google.com> To catch bugs like the one fixed in
http://llvm.org/viewvc/llvm-project?view=rev&revision=78127, I'm changing the
ExecutionEngine's global mappings to hold AssertingVH<const GlobalValue>. That
way, if unregistering a mapping fails to actually unregister it, we'll get an
assert. Running the jit nightly tests didn't uncover any actual instances of
the problem.

This also uncovered the fact that AssertingVH<const X> didn't work, so I fixed
that too.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@78400 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
0a962314fb5b3e9654ad9ab50b7d1b684f154270 05-Aug-2009 Jeffrey Yasskin <jyasskin@google.com> Make ExecutionEngine::updateGlobalMapping(GV, NULL) properly remove GV's old
address from the reverse mapping, and add a test that this works now.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@78127 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
93b67e40de356569493c285b86b138a3f11b5035 26-Jul-2009 Daniel Dunbar <daniel@zuster.org> Eliminate some uses of DOUT, cerr, and getNameStart().


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@77145 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
fbee579ed46016166d88b4defb81a2e7e253062d 21-Jul-2009 Daniel Dunbar <daniel@zuster.org> Simplify / normalize some uses of Value::getName.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@76553 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
4b1511b027ce0b648b3379f2891816c25b46f515 18-Jul-2009 Reid Kleckner <reid@kleckner.net> Add EngineBuilder to ExecutionEngine in favor of the five optional argument EE::create().

Also a test commit.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@76276 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
c23197a26f34f559ea9797de51e187087c039c42 14-Jul-2009 Torok Edwin <edwintorok@gmail.com> llvm_unreachable->llvm_unreachable(0), LLVM_UNREACHABLE->llvm_unreachable.
This adds location info for all llvm_unreachable calls (which is a macro now) in
!NDEBUG builds.
In NDEBUG builds location info and the message is off (it only prints
"UREACHABLE executed").


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@75640 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
c25e7581b9b8088910da31702d4ca21c4734c6d7 11-Jul-2009 Torok Edwin <edwintorok@gmail.com> assert(0) -> LLVM_UNREACHABLE.
Make llvm_unreachable take an optional string, thus moving the cerr<< out of
line.
LLVM_UNREACHABLE is now a simple wrapper that makes the message go away for
NDEBUG builds.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@75379 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
7d696d80409aad20bb5da0fc4eccab941dd371d4 11-Jul-2009 Torok Edwin <edwintorok@gmail.com> Convert more assert(0)+abort() -> LLVM_UNREACHABLE,
and abort()/exit() -> llvm_report_error().


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@75363 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
489393d7b92107cc3de17d8dbe7dd11ab7395fdc 08-Jul-2009 Jeffrey Yasskin <jyasskin@google.com> Add an option to allocate JITed global data separately from code. By
default, this option is not enabled to support clients who rely on
this behavior.

Fixes http://llvm.org/PR4483

A patch to allocate additional memory for globals after we run out is
forthcoming.

Patch by Reid Kleckner!


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@75059 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
31e2466f159a887fed9139067a676f65adf2a8c3 07-Jul-2009 Torok Edwin <edwintorok@gmail.com> Introduce new error handling API.
This will replace exit()/abort() style error handling with an API
that allows clients to register custom error handling hooks.
The default is to call exit(1) when no error handler is provided.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@74922 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
ae3a0be92e33bc716722aa600983fc1535acb122 05-Jun-2009 Dan Gohman <gohman@apple.com> Split the Add, Sub, and Mul instruction opcodes into separate
integer and floating-point opcodes, introducing
FAdd, FSub, and FMul.

For now, the AsmParser, BitcodeReader, and IRBuilder all preserve
backwards compatability, and the Core LLVM APIs preserve backwards
compatibility for IR producers. Most front-ends won't need to change
immediately.

This implements the first step of the plan outlined here:
http://nondot.org/sabre/LLVMNotes/IntegerOverflow.txt


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@72897 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
777d2306b36816a53bc1ae1244c0dc7d998ae691 09-May-2009 Duncan Sands <baldrick@free.fr> Rename PaddedSize to AllocSize, in the hope that this
will make it more obvious what it represents, and stop
it being confused with the StoreSize.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@71349 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
98a366d547772010e94609e4584489b3e5ce0043 30-Apr-2009 Bill Wendling <isanbard@gmail.com> Instead of passing in an unsigned value for the optimization level, use an enum,
which better identifies what the optimization is doing. And is more flexible for
future uses.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@70440 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
5e5cb7985de2508ecd707568afbcbb39e8a688fc 29-Apr-2009 Bill Wendling <isanbard@gmail.com> The second part of the change from -fast to -O#. This changes the JIT to accept
an optimization level instead of a simple boolean telling it to generate code
"fast" or the other type of "fast".


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@70347 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
1f8c564d7df985082d7e728330979781f384d0e9 24-Mar-2009 Dale Johannesen <dalej@apple.com> fix one more fp80 case (used only by Interpreter)
and streamline code here a bit.



git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@67636 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
e330ae5b32fa5f798894cec207fd9e4fcc578382 24-Mar-2009 Dale Johannesen <dalej@apple.com> Change JIT for different layout of fp80.



git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@67629 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
d6b7a242d345fd79a337afd384bb586c5619cfe7 18-Feb-2009 Nate Begeman <natebegeman@mac.com> Add support to the JIT for true non-lazy operation. When a call to a function
that has not been JIT'd yet, the callee is put on a list of pending functions
to JIT. The call is directed through a stub, which is updated with the address
of the function after it has been JIT'd. A new interface for allocating and
updating empty stubs is provided.

Add support for removing the ModuleProvider the JIT was created with, which
would otherwise invalidate the JIT's PassManager, which is initialized with the
ModuleProvider's Module.

Add support under a new ExecutionEngine flag for emitting the infomration
necessary to update Function and GlobalVariable stubs after JITing them, by
recording the address of the stub and the name of the GlobalValue. This allows
code to be copied from one address space to another, where libraries may live
at different virtual addresses, and have the stubs updated with their new
correct target addresses.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@64906 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
45f36835470dd95908d579c30ec05b923ec46fe6 04-Feb-2009 Chris Lattner <sabre@nondot.org> allow main to have any integer type.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@63743 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
60789e419e04c260e36af9a1add5ad316313e490 23-Jan-2009 Nate Begeman <natebegeman@mac.com> Add support for deleting a module provider from a JIT in such a way that it does not cause the owned module to be fully materialized.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@62864 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
b67c95834226fc44c435ca97dc5a536bccb30bbf 22-Jan-2009 Chris Lattner <sabre@nondot.org> rename methods in System/Host to be more consistent.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@62776 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
bb46f52027416598a662dc1c58f48d9d56b1a65b 15-Jan-2009 Rafael Espindola <rafael.espindola@gmail.com> Add the private linkage.



git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@62279 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
ceb4d1aecb9deffe59b3dcdc9a783ffde8477be9 12-Jan-2009 Duncan Sands <baldrick@free.fr> Rename getABITypeSize to getTypePaddedSize, as
suggested by Chris.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@62099 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
366cf29ca537057341ecbad03ab8f9bc52f731e7 07-Nov-2008 Evan Cheng <evan.cheng@apple.com> More debug output.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@58868 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
eb5d95a22df7ab88815f35bdc8b6e5d3a6a1119d 06-Nov-2008 Evan Cheng <evan.cheng@apple.com> Improve JIT debugging outputs format consistency.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@58807 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
4e20c5c30b35146ef37d7fc86d6872f147952256 05-Nov-2008 Evan Cheng <evan.cheng@apple.com> Debugging output tweak.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@58737 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
89687e3e4ac4aa602de7cce4a7fbc5f514e86615 04-Nov-2008 Evan Cheng <evan.cheng@apple.com> 80 col violation.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@58684 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
46fa139e26be6ebc00be2fb45820c2560dd22a32 25-Oct-2008 Nicolas Geoffray <nicolas.geoffray@lip6.fr> Support for allocation of TLS variables in the JIT. Allocation of a global
variable is moved to the execution engine. The JIT calls the TargetJITInfo
to allocate thread local storage. Currently, only linux/x86 knows how to
allocate thread local global variables.



git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@58142 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
c8ed902298b79e8a740e4f707f13089cf5ce1295 14-Oct-2008 Nuno Lopes <nunoplopes@sapo.pt> little optimization: reuse getPointerToGlobalIfAvailable(CGV) value in emitGlobals()

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@57484 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
23a98551ab65eeb8fe5019df8b7db4891582a4bd 10-Oct-2008 Dale Johannesen <dalej@apple.com> Add a "loses information" return value to APFloat::convert
and APFloat::convertToInteger. Restore return value to
IEEE754. Adjust all users accordingly.



git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@57329 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
7111b02c734c992b8c97d9918118768026dad79e 09-Oct-2008 Dale Johannesen <dalej@apple.com> Rename APFloat::convertToAPInt to bitcastToAPInt to
make it clearer what the function does. No functional
change.



git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@57325 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
18314dc741ab7dc4db02b199af77f43bd8551fd2 30-Sep-2008 Evan Cheng <evan.cheng@apple.com> Add runStaticConstructorsDestructors which runs ctors / dtors of a single module. Patch by David Chisnall.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@56849 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
446531e7bb4355117b070493ca8e81e4b123ef18 24-Sep-2008 Evan Cheng <evan.cheng@apple.com> Add DisableGVCompilation which forces the JIT to assert when it tries to allocate space for a GlobalVariable.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@56557 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
bc4707a2554ac04ba006bf70035e7bc7270236a9 18-Sep-2008 Evan Cheng <evan.cheng@apple.com> Preliminary support for systems which require changing JIT memory regions privilege from read / write to read / executable.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@56303 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
b6e3d6ce709e9ed57df055b026e55d19e50df772 26-Aug-2008 Dan Gohman <gohman@apple.com> Avoid a warning about isTargetNullPtr being unused in release builds.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@55350 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
502f20b17ede40de84503010b7699b328a4f2867 08-Aug-2008 Evan Cheng <evan.cheng@apple.com> Add new parameter Fast to createJIT to enable the fast codegen path.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@54523 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
dd947ea3c5e020c33c58a31939561265b980a3ad 07-Aug-2008 Dale Johannesen <dalej@apple.com> Rewrite JIT handling of GlobalVariables so they
are allocated in the same buffer as the code,
jump tables, etc.

The default JIT memory manager does not handle buffer
overflow well. I didn't introduce this and I'm not
attempting to fix it here, but it is more likely to
be hit now since we're putting more stuff in the
buffer. This affects one test that I know of so far,
MultiSource/Benchmarks/NPB-serial/is.



git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@54442 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
1b088f33107798c544e0a872df4cc1921581eb66 17-Jun-2008 Evan Cheng <evan.cheng@apple.com> Don't forget to initialize SymbolSearchingDisabled.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@52414 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
f049e07eb8930214941c72f8e4409df394de1567 21-May-2008 Nate Begeman <natebegeman@mac.com> Fix a couple issues with the JIT and multiple modules:

1. The "JITState" object creates a PassManager with the ModuleProvider that the
jit is created with. If the ModuleProvider is removed and deleted, the
PassManager is invalid.

2. The Global maps in the JIT were not invalidated with a ModuleProvider was
removed. This could lead to a case where the Module would be freed, and a
new Module with Globals at the same addresses could return invalid results.



git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@51384 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
638e378f2cb62c34f306f8eadd43039e20caede4 20-May-2008 Dan Gohman <gohman@apple.com> Fix ExecutionEngine's constant code to work properly when structs and arrays
will become first-class types.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@51293 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
aafce77b17d340aace52bcd49d1944109d82f14a 14-May-2008 Dale Johannesen <dalej@apple.com> Add CommonLinkage; currently tentative definitions
are represented as "weak", but there are subtle differences
in some cases on Darwin, so we need both. The intent
is that "common" will behave identically to "weak" unless
somebody changes their target to do something else.
No functional change as yet.



git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@51118 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
f4cc3096fd893cdef5b5c2664ebff8c13a07ad51 04-Apr-2008 Chris Lattner <sabre@nondot.org> Make ExecutionEngine::updateGlobalMapping return the old mapping.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@49206 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
08bfe26f5a06bf9b0d6f8d2ceb5cb991d0d61842 10-Mar-2008 Duncan Sands <baldrick@free.fr> Fix formatting.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@48151 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
6456d8639b6f3ede1bb1a90a5d33fe4e719ad4ac 08-Mar-2008 Nick Lewycky <nicholas@mxc.ca> Load the symbols first so that the interpreter constructor can find them when
it tries to initialize them.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@48046 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
628240649267597f3f27a51ab046b5841c24a953 29-Feb-2008 Dan Gohman <gohman@apple.com> Simplify code using convertFromZeroExtendedInteger with an APInt
by using the new convertFromAPInt directly.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@47739 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
ae9f3a3b7c915f725aef5a7250e88eaeddda03c6 20-Feb-2008 Anton Korobeynikov <asl@math.spbu.ru> Unbreak build with gcc 4.3: provide missed includes and silence most annoying warnings.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@47367 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
b6e1dd70750d9b761779a00512e69c64a06ddfde 15-Feb-2008 Chris Lattner <sabre@nondot.org> Support vector constant zeros, thanks to Zack Rusin for the testcase.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@47148 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
afe6c2b001a924cd74bd0aacfed5984d9af004b0 13-Feb-2008 Nicolas Geoffray <nicolas.geoffray@lip6.fr> Enable exception handling int JIT



git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@47079 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
4ee451de366474b9c228b4e5fa573795a715216d 29-Dec-2007 Chris Lattner <sabre@nondot.org> Remove attribution from file headers, per discussion on llvmdev.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@45418 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
43ad6b3e0d6ada51e9b23aab3e061187f1f5710c 17-Dec-2007 Christopher Lamb <christopher.lamb@gmail.com> Change the PointerType api for creating pointer types. The old functionality of PointerType::get() has become PointerType::getUnqual(), which returns a pointer in the generic address space. The new prototype of PointerType::get() requires both a type and an address space.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@45082 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
9e4635a5b8f56db607df2aca9cae1fc8d5a8bd36 15-Dec-2007 Duncan Sands <baldrick@free.fr> These are more correctly called signaling NaNs.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@45059 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
8a43e9e5d751ab827ba3ff0cf862787d3263a484 14-Dec-2007 Duncan Sands <baldrick@free.fr> Teach the interpreter to read and write memory in the
endianness of the target not of the host. Done by the
simple expedient of reversing bytes for primitive types
if the host and target endianness don't match. This is
correct for integer and pointer types. I don't know if
it is correct for floating point types.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@45039 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
67f1c493d105fdfb8ffa980ff82ff7d9e3fafefc 13-Dec-2007 Duncan Sands <baldrick@free.fr> Remove host endianness info from TargetData and
put it in a new header System/Host.h instead.
Instead of getting the endianness from configure,
calculate it directly.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@44959 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
1eff70451fbb079c1d5b8f45ff8c8a2b8f74d7ba 10-Dec-2007 Duncan Sands <baldrick@free.fr> Fix PR1836: in the interpreter, read and write apints
using the minimum possible number of bytes. For little
endian targets run on little endian machines, apints are
stored in memory from LSB to MSB as before. For big endian
targets on big endian machines they are stored from MSB to
LSB which wasn't always the case before (if the target and
host endianness doesn't match values are stored according
to the host's endianness). Doing this requires knowing the
endianness of the host, which is determined when configuring -
thanks go to Anton for this. Only having access to little
endian machines I was unable to properly test the big endian
part, which is also the most complicated...


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@44796 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
9f2f142d255bc96f109dd5c6524a485937b1f3a1 06-Dec-2007 Chris Lattner <sabre@nondot.org> simplify creation of the interpreter, make ExecutionEngine ctor protected,
delete one ExecutionEngine ctor, minor cleanup.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@44646 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
dd65a73af480b727de6f7ceb925c5f7ea75bdc13 28-Nov-2007 Duncan Sands <baldrick@free.fr> My compiler complains that "x always evaluates to true"
in this call:

Result.IntVal = APInt(80, 2, x);

What is x?

uint16_t x[8];

I deduce that the APInt constructor being used is this one:

APInt(uint32_t numBits, uint64_t val, bool isSigned = false);

rather than this one:

APInt(uint32_t numBits, uint32_t numWords, const uint64_t bigVal[]);

That doesn't seem right! This fix compiles but is otherwise completely
untested.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@44400 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
514ab348fddcdffa8367685dc608b2f8d5de986d 01-Nov-2007 Duncan Sands <baldrick@free.fr> Executive summary: getTypeSize -> getTypeStoreSize / getABITypeSize.
The meaning of getTypeSize was not clear - clarifying it is important
now that we have x86 long double and arbitrary precision integers.
The issue with long double is that it requires 80 bits, and this is
not a multiple of its alignment. This gives a primitive type for
which getTypeSize differed from getABITypeSize. For arbitrary precision
integers it is even worse: there is the minimum number of bits needed to
hold the type (eg: 36 for an i36), the maximum number of bits that will
be overwriten when storing the type (40 bits for i36) and the ABI size
(i.e. the storage size rounded up to a multiple of the alignment; 64 bits
for i36).

This patch removes getTypeSize (not really - it is still there but
deprecated to allow for a gradual transition). Instead there is:

(1) getTypeSizeInBits - a number of bits that suffices to hold all
values of the type. For a primitive type, this is the minimum number
of bits. For an i36 this is 36 bits. For x86 long double it is 80.
This corresponds to gcc's TYPE_PRECISION.

(2) getTypeStoreSizeInBits - the maximum number of bits that is
written when storing the type (or read when reading it). For an
i36 this is 40 bits, for an x86 long double it is 80 bits. This
is the size alias analysis is interested in (getTypeStoreSize
returns the number of bytes). There doesn't seem to be anything
corresponding to this in gcc.

(3) getABITypeSizeInBits - this is getTypeStoreSizeInBits rounded
up to a multiple of the alignment. For an i36 this is 64, for an
x86 long double this is 96 or 128 depending on the OS. This is the
spacing between consecutive elements when you form an array out of
this type (getABITypeSize returns the number of bytes). This is
TYPE_SIZE in gcc.

Since successive elements in a SequentialType (arrays, pointers
and vectors) need to be aligned, the spacing between them will be
given by getABITypeSize. This means that the size of an array
is the length times the getABITypeSize. It also means that GEP
computations need to use getABITypeSize when computing offsets.
Furthermore, if an alloca allocates several elements at once then
these too need to be aligned, so the size of the alloca has to be
the number of elements multiplied by getABITypeSize. Logically
speaking this doesn't have to be the case when allocating just
one element, but it is simpler to also use getABITypeSize in this
case. So alloca's and mallocs should use getABITypeSize. Finally,
since gcc's only notion of size is that given by getABITypeSize, if
you want to output assembler etc the same as gcc then getABITypeSize
is the size you want.

Since a store will overwrite no more than getTypeStoreSize bytes,
and a read will read no more than that many bytes, this is the
notion of size appropriate for alias analysis calculations.

In this patch I have corrected all type size uses except some of
those in ScalarReplAggregates, lib/Codegen, lib/Target (the hard
cases). I will get around to auditing these too at some point,
but I could do with some help.

Finally, I made one change which I think wise but others might
consider pointless and suboptimal: in an unpacked struct the
amount of space allocated for a field is now given by the ABI
size rather than getTypeStoreSize. I did this because every
other place that reserves memory for a type (eg: alloca) now
uses getABITypeSize, and I didn't want to make an exception
for unpacked structs, i.e. I did it to make things more uniform.
This only effects structs containing long doubles and arbitrary
precision integers. If someone wants to pack these types more
tightly they can always use a packed struct.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@43620 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
d958a5a9feea7239a73c2068f43f237db550f46e 22-Oct-2007 Chris Lattner <sabre@nondot.org> add a mechanism for the JIT to invoke a function to lazily create functions as they are referenced.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@43210 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
c6185038b88588929a8d69309abe8bebadad345d 22-Oct-2007 Chris Lattner <sabre@nondot.org> LoadLibraryPermanently doesn't throw.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@43207 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
8b5295b7bb8bf44f13df7fc8e38069d1218b1f94 22-Oct-2007 Chris Lattner <sabre@nondot.org> Add a convenience method for creating EE's.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@43206 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
73d0e211a39650fc7562e0f15ed21440dde2243a 15-Oct-2007 Devang Patel <dpatel@apple.com> Add removeModuleProvider()


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@43002 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
ccf596a53e16ea221a9bf8b3874a7d6afa71f1f4 07-Oct-2007 Neil Booth <neil@daikokuya.co.uk> convertFromInteger, as originally written, expected sign-extended
input. APInt unfortunately zero-extends signed integers, so Dale
modified the function to expect zero-extended input. Make this
assumption explicit in the function name.



git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@42732 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
88216af3ea4bb1c68a8793ed1d3b30308b64ab0e 30-Sep-2007 Dale Johannesen <dalej@apple.com> Constant fold int-to-long-double conversions;
use APFloat for int-to-float/double; use
round-to-nearest for these (implementation-defined,
seems to match gcc).


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@42484 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
910993e8dc49a25d9da3b53de4a82568c14e91cc 22-Sep-2007 Dale Johannesen <dalej@apple.com> Change APFloat::convertFromInteger to take the incoming
bit width instead of number of words allocated, which
makes it actually work for int->APF conversions.
Adjust callers. Add const to one of the APInt constructors
to prevent surprising match when called with const
argument.



git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@42210 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
1abac0d725374cb6e527d2a735a5272a4f7913fa 17-Sep-2007 Dale Johannesen <dalej@apple.com> Implement x86 long double in jit (not really
complete, but common cases work)



git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@42043 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
43421b3dd70af5b70e71816521f37502c397cc65 06-Sep-2007 Dale Johannesen <dalej@apple.com> Next round of APFloat changes.
Use APFloat in UpgradeParser and AsmParser.
Change all references to ConstantFP to use the
APFloat interface rather than double. Remove
the ConstantFP double interfaces.
Use APFloat functions for constant folding arithmetic
and comparisons.
(There are still way too many places APFloat is
just a wrapper around host float/double, but we're
getting there.)


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@41747 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
ba28cb91c9df52d1b5b2b7238ab7576a995bf563 11-Aug-2007 Reid Spencer <rspencer@reidspencer.com> Fix a comment typo noticed by Sandro Magi.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@41018 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
fb4508602726c47f7517f79a7a4d7e178c26e98e 03-Jun-2007 Anton Korobeynikov <asl@math.spbu.ru> Add comments to fallsthrough cases. Also, this fixes PR1492


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@37405 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
499d8f0c3b212819515cdbcb98146fff6f9d877b 03-Jun-2007 Anton Korobeynikov <asl@math.spbu.ru> Check arguments & return types of main(). Abort in case of no match.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@37404 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
849c5b45379af00348ecf785e52fedeab83995a2 24-May-2007 Zhou Sheng <zhousheng00@gmail.com> Compute the correct word number.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@37322 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
2b7d7b57ae8334687d6d4fea045fbfbea4864db0 12-Mar-2007 Jeff Cohen <jeffc@jolt-lang.org> Unbreak C++ build.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@35067 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
bce30f1887631d606c44b8fdd185dcc42096ca60 06-Mar-2007 Reid Spencer <rspencer@reidspencer.com> Fix all of last night's JIT failures in Prolangs-C++ by finishing the
implementation of getConstantValue().


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@34988 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
415c1f7438619434d74b76223674228779930ae3 06-Mar-2007 Reid Spencer <rspencer@reidspencer.com> 1. Make StoreValueToMemory a little more efficient by not requiring caller
to make a copy of the GenericValue.
2. Fix a copy & paste bug in StoreValueToMemory where 64-bit values were
truncated to 32


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@34958 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
8fb0f190a90f34b9d94d027ed8daf5f537e4b891 06-Mar-2007 Reid Spencer <rspencer@reidspencer.com> Simplify things significantly because GenericValue now has a single integer
field, of type APInt, instead of multiple integer fields. Also, get rid of
the special endianness code in StoreValueToMemory and LoadValueToMemory.
ExecutionEngine is always used to execute on the host platform so this is
now unnecessary.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@34946 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
d4c0e62413ac4c81467ce59025c81210ea431752 03-Mar-2007 Reid Spencer <rspencer@reidspencer.com> Deal with error handling better.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@34887 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
f0f09a96f3610f716f8b9da78ec1b30a4c2a75ec 03-Mar-2007 Reid Spencer <rspencer@reidspencer.com> Avoid memory leakage by having caller construct the APInt for the
destination value of LoadValueFromMemory.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@34883 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
93a2875456a61f072f74a2b6b5c37bc2463a43ca 03-Mar-2007 Reid Spencer <rspencer@reidspencer.com> Implement loading and storing of APInt values from memory.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@34874 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
9d6565a5b1fbc4286d6ee638d8f47a3171a9ed7e 15-Feb-2007 Reid Spencer <rspencer@reidspencer.com> For PR1195:
Rename PackedType -> VectorType, ConstantPacked -> ConstantVector, and
PackedTyID -> VectorTyID. No functional changes.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@34293 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
64f150fa92180c4176d64522158c4c643184b17c 14-Feb-2007 Chris Lattner <sabre@nondot.org> From Dan Gohman:

While preparing http://llvm.org/PR1198 I noticed several asserts
protecting unprepared code from i128 types that weren't actually failing
when they should because they were written as assert("foo") instead of
something like assert(0 && "foo"). This patch fixes all the cases that a
quick grep found.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@34267 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
829621c59e9e4e2f4e15cd562688fae9f82ea549 10-Feb-2007 Chris Lattner <sabre@nondot.org> eliminate use of TargetData::getIndexedOffset that takes a vector


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@34163 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
b1919e2f08ecb37140af676fd2916f8d5ed7df3d 10-Feb-2007 Chris Lattner <sabre@nondot.org> Privatize StructLayout::MemberOffsets, adding an accessor


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@34156 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
688b0490e22eb67623f5aaa24406209be74efcb2 05-Feb-2007 Reid Spencer <rspencer@reidspencer.com> For PR411:
Adjust to changes in Module interface:
getMainFunction() -> getFunction("main")
getNamedFunction(X) -> getFunction(X)


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@33922 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
5cbf985dcbc89fba3208e7baf8b6f488b06d3ec9 30-Jan-2007 Reid Spencer <rspencer@reidspencer.com> For PR1136: Rename GlobalVariable::isExternal as isDeclaration to avoid
confusion with external linkage types.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@33663 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
c10305743c313558405079452138f03124e87581 19-Jan-2007 Reid Spencer <rspencer@reidspencer.com> For PR1043:
This is the final patch for this PR. It implements some minor cleanup
in the use of IntegerType, to wit:
1. Type::getIntegerTypeMask -> IntegerType::getBitMask
2. Type::Int*Ty changed to IntegerType* from Type*
3. ConstantInt::getType() returns IntegerType* now, not Type*

This also fixes PR1120.

Patch by Sheng Zhou.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@33370 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
8205972a5a62a9e80c4772bf7ba3197a125c12f1 18-Jan-2007 Reid Spencer <rspencer@reidspencer.com> Fix a regression in the last patch. When constructing a BitMask, be careful
not to overflow 64-bits and end up with a 0 mask. This caused i64 values to
always be stored as 0 with lots of consequential damage to nightly test.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@33335 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
f89aec655f220fdd70e39fcb8d16943694b85903 18-Jan-2007 Reid Spencer <rspencer@reidspencer.com> Make sure we truncate stored values to their bit width.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@33317 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
a54b7cbd452b3adb2f51346140d996b29c2cdb30 12-Jan-2007 Reid Spencer <rspencer@reidspencer.com> For PR1064:
Implement the arbitrary bit-width integer feature. The feature allows
integers of any bitwidth (up to 64) to be defined instead of just 1, 8,
16, 32, and 64 bit integers.

This change does several things:
1. Introduces a new Derived Type, IntegerType, to represent the number of
bits in an integer. The Type classes SubclassData field is used to
store the number of bits. This allows 2^23 bits in an integer type.
2. Removes the five integer Type::TypeID values for the 1, 8, 16, 32 and
64-bit integers. These are replaced with just IntegerType which is not
a primitive any more.
3. Adjust the rest of LLVM to account for this change.

Note that while this incremental change lays the foundation for arbitrary
bit-width integers, LLVM has not yet been converted to actually deal with
them in any significant way. Most optimization passes, for example, will
still only deal with the byte-width integer types. Future increments
will rectify this situation.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@33113 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
579dca12c2cfd60bc18aaadbd5331897d48fec29 12-Jan-2007 Reid Spencer <rspencer@reidspencer.com> Implement review feedback for the ConstantBool->ConstantInt merge. Chris
recommended that getBoolValue be replaced with getZExtValue and that
get(bool) be replaced by get(const Type*, uint64_t). This implements
those changes.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@33110 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
4fe16d607d11e29d742208894909733f5ad01f8f 11-Jan-2007 Reid Spencer <rspencer@reidspencer.com> Rename BoolTy as Int1Ty. Patch by Sheng Zhou.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@33076 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
6b6b6ef1677fa71b1072c2911b4c1f9524a558c9 11-Jan-2007 Zhou Sheng <zhousheng00@gmail.com> For PR1043:
Merge ConstantIntegral and ConstantBool into ConstantInt.
Remove ConstantIntegral and ConstantBool from LLVM.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@33073 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
e49661bdf5b7a913d4e368cf511381e524ae403a 31-Dec-2006 Reid Spencer <rspencer@reidspencer.com> For PR950:
Convert signed integer types to signless ones.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@32787 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
36343735cb23680c8f8675deafbbf825d46fd868 19-Dec-2006 Chris Lattner <sabre@nondot.org> remove static ctors from Statistic objects


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@32700 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
e81561909d128c6e2d8033cb5465a49b2596b26a 07-Dec-2006 Bill Wendling <isanbard@gmail.com> Changed llvm_ostream et all to OStream. llvm_cerr, llvm_cout, llvm_null, are
now cerr, cout, and NullStream resp.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@32298 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
ac0b6ae358944ae8b2b5a11dc08f52c3ed89f2da 06-Dec-2006 Chris Lattner <sabre@nondot.org> Detemplatize the Statistic class. The only type it is instantiated with
is 'unsigned'.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@32279 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
78ee7b78c3c47b71c4b7a1475438d6574216a64b 01-Dec-2006 Anton Korobeynikov <asl@math.spbu.ru> Introducing external weak linkage. Darwin codegen should be added later.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@32052 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
480f093dc2b6aff9b501cc56cf5728513e55be81 28-Nov-2006 Bill Wendling <isanbard@gmail.com> Removed #include <iostream> and replaced streams with llvm streams.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31949 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
3da59db637a887474c1b1346c1f3ccf53b6c4663 27-Nov-2006 Reid Spencer <rspencer@reidspencer.com> For PR950:
The long awaited CAST patch. This introduces 12 new instructions into LLVM
to replace the cast instruction. Corresponding changes throughout LLVM are
provided. This passes llvm-test, llvm/test, and SPEC CPUINT2000 with the
exception of 175.vpr which fails only on a slight floating point output
difference.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31931 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
3d6e33d2a3dcade0db9edc419857d0e266176460 09-Nov-2006 Chris Lattner <sabre@nondot.org> init ivar


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31601 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
b83eb6447ba155342598f0fabe1f08f5baa9164a 20-Oct-2006 Reid Spencer <rspencer@reidspencer.com> For PR950:
This patch implements the first increment for the Signless Types feature.
All changes pertain to removing the ConstantSInt and ConstantUInt classes
in favor of just using ConstantInt.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@31063 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
b74ed07bfd3af42331b1964c24c39912610a08f4 14-Sep-2006 Anton Korobeynikov <asl@math.spbu.ru> Adding dllimport, dllexport and external weak linkage types.
DLL* linkages got full (I hope) codegeneration support in C & both x86
assembler backends.
External weak linkage added for future use, we don't provide any
codegeneration, etc. support for it.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30374 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
fe854034677f59baca1e38075e71f6efca247a03 16-Aug-2006 Chris Lattner <sabre@nondot.org> initial changes to support JIT'ing from multiple module providers, implicitly
linking the program on the fly.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@29721 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
6f3ada51aa7a3816609967231befd58de4053e4c 14-May-2006 Chris Lattner <sabre@nondot.org> LoadLibraryPermanently can theoretically throw an exception. Do not propagate
it out of 'ExecutionEngine::create'. This fixes a problem reported by coverity.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@28293 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
e7fd553b3be8b95dc0946cd3267bc2db859cd3d8 09-May-2006 Chris Lattner <sabre@nondot.org> Move some methods out of line so that MutexGuard.h isn't needed in a public header.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@28179 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
a69571c7991813c93cba64e88eced6899ce93d81 03-May-2006 Owen Anderson <resistor@mac.com> Refactor TargetMachine, pushing handling of TargetData into the target-specific subclasses. This has one caller-visible change: getTargetData() now returns a pointer instead of a reference.

This fixes PR 759.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@28074 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
37efe6764568a3829fee26aba532283131d1a104 22-Apr-2006 Nate Begeman <natebegeman@mac.com> JumpTable support! What this represents is working asm and jit support for
x86 and ppc for 100% dense switch statements when relocations are non-PIC.
This support will be extended and enhanced in the coming days to support
PIC, and less dense forms of jump tables.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@27947 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
b003d76cb3cf353264f2f0b8cb658371dd7b3181 22-Apr-2006 Chris Lattner <sabre@nondot.org> Fix JIT support for static ctors, which was apparently completely broken!

This allows Prolangs-C++/city and probably a bunch of other stuff to work
well with the new front-end


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@27941 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
70a7b1b3815259083b26eadddbd83ef3a08b845e 23-Mar-2006 Chris Lattner <sabre@nondot.org> prune #includes


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@26975 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
726c1ef2bdd72975f41e3188371bb7d6f40401be 23-Mar-2006 Chris Lattner <sabre@nondot.org> remove the intrinsiclowering hook


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@26970 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
2fe4bb06c6c40d16b7a5ae9cdf6bb6fe94d51be0 22-Mar-2006 Chris Lattner <sabre@nondot.org> Eliminate the dependency of ExecutionEngine on the JIT/Interpreter libraries.

Now you can build a tool with just the JIT or just the interpreter.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@26946 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
9ca6cdaee91fddcd3ea57dedcd624c14c7a40f65 08-Mar-2006 Chris Lattner <sabre@nondot.org> Add a helper method for running static ctors/dtors in the module.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@26619 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
68835dd5119150383938c701fc223077d2bc1e25 07-Feb-2006 Jeff Cohen <jeffc@jolt-lang.org> Teach the interpreter to handle global variables that are added to a module after
interpretation has begun. The JIT already handles this situation correctly, and
the interpreter can already handle new functions being added.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@26030 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
7c2b7c7c75a3549b2d6933edf3110294a33ff2d4 20-Jan-2006 Robert Bocchino <bocchino@illinois.edu> Fixed InitializeMemory to handle ConstantPacked.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@25481 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
3db4b62c2fa43b23fa02d32a7d3253885acafb9f 24-Oct-2005 Chris Lattner <sabre@nondot.org> Fix a nasty bug that was causing miscompilation of global variables
on big endian 32-bit targets in some cases (e.g. PPC). This fixes several
PPC JIT failures.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@23914 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
ee448630bdf7eb6037fe2c50518d32010c433ca3 12-Jul-2005 Reid Spencer <rspencer@reidspencer.com> For PR540:
This patch completes the changes for making lli thread-safe. Here's the list
of changes:
* The Support/ThreadSupport* files were removed and replaced with the
MutexGuard.h file since all ThreadSupport* declared was a Mutex Guard.
The implementation of MutexGuard.h is now based on sys::Mutex which hides
its implementation and makes it unnecessary to have the -NoSupport.h and
-PThreads.h versions of ThreadSupport.

* All places in ExecutionEngine that previously referred to "Mutex" now
refer to sys::Mutex

* All places in ExecutionEngine that previously referred to "MutexLocker"
now refer to MutexGuard (this is frivolous but I believe the technically
correct name for such a class is "Guard" not a "Locker").

These changes passed all of llvm-test. All we need now are some test cases
that actually use multiple threads.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@22404 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
6e6308898a69088f0e4aec88f67f8828be37da1b 11-Jul-2005 Chris Lattner <sabre@nondot.org> fix long lines


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@22369 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
4b3141d3245d93a62b466818b94ba039a4e3202f 12-May-2005 Chris Lattner <sabre@nondot.org> Fix a really horrible problem that causes the JIT to miscompile any program
that use 64-bit integers on 32-bit hosts.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@21886 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
edf128a7fa90f2b0b7ee24741a04a7ae1ecd6f7e 22-Apr-2005 Misha Brukman <brukman+llvm@gmail.com> Remove trailing whitespace


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@21420 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
e4d5c441e04bdc00ccf1804744af670655123b07 15-Mar-2005 Chris Lattner <sabre@nondot.org> This mega patch converts us from using Function::a{iterator|begin|end} to
using Function::arg_{iterator|begin|end}. Likewise Module::g* -> Module::global_*.

This patch is contributed by Gabor Greif, thanks!


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@20597 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
3e27952a8b3987b8dddef85dd00db07447575982 27-Feb-2005 Chris Lattner <sabre@nondot.org> Use const iterators where possible. Patch by Evan Jones!


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@20354 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
032ad0848a87375729e54443195ccc418fc5c979 02-Feb-2005 Chris Lattner <sabre@nondot.org> This is no longer needed. Global variables with undef initializers can be
initialized to anything, including garbage.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@20010 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
813c8152825db530a6ef4ee86e8038bbee16deb3 08-Jan-2005 Chris Lattner <sabre@nondot.org> Silence VS warnings.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@19391 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
df5a37efc997288da520ff4889443e3560d95387 29-Nov-2004 Reid Spencer <rspencer@reidspencer.com> Use System/DynamicLibrary instead of Support/DynamicLinker


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@18357 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
a98c5453b28b37c3fad118712ff4e634bfc36163 19-Nov-2004 Chris Lattner <sabre@nondot.org> This is a horrible hack to work around libstdc++ bugs :(


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@17988 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
6f335f905c76187a7baf70a227fa843061473afe 26-Oct-2004 Chris Lattner <sabre@nondot.org> Fix the interpreter crash that Michael McCracken found


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@17239 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
bd1d382cc47dfc43ee758714bc22ab5a750bad15 16-Oct-2004 Chris Lattner <sabre@nondot.org> Add support for undef


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@17055 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
551ccae044b0ff658fe629dd67edd5ffe75d10e8 02-Sep-2004 Reid Spencer <rspencer@reidspencer.com> Changes For Bug 352
Move include/Config and include/Support into include/llvm/Config,
include/llvm/ADT and include/llvm/Support. From here on out, all LLVM
public header files must be under include/llvm/.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@16137 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
f24d09933c0fa2dae141426f2c38c8925693c73f 16-Aug-2004 Chris Lattner <sabre@nondot.org> Don't pass too many arguments into runFunction


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@15801 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
15876bb28c9c0983279c30a123c13224648574c1 04-Aug-2004 Alkis Evlogimenos <alkis@evlogimenos.com> Stop using getValues().


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@15487 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
40cf2f954e7d554872f6eca42c844bc065b02c11 18-Jul-2004 Reid Spencer <rspencer@reidspencer.com> bug 122:
- Replace ConstantPointerRef usage with GlobalValue usage
- Correct isa<Constant> for GlobalValue subclass


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@14951 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
0a8e8e1a4ea46fa5da067369ac43d8a459d0cac0 15-Jul-2004 Chris Lattner <sabre@nondot.org> Fixes for PR341


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@14847 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
5f90cb8c9838ab03feef93c9dacd5ff652e5d8d2 11-Jul-2004 Chris Lattner <sabre@nondot.org> Make add constantexprs work with all types, fixing the regressions from last night


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@14760 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
e2947531280503a4e73e8d94a6161f68bea857a7 07-Jul-2004 Reid Spencer <rspencer@reidspencer.com> Fix for bug 391.
Improve exeception handling around bcreader invocations.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@14674 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
8f7f71b48a561ba0b1f07501f5a745a34220acbf 20-Jun-2004 Chris Lattner <sabre@nondot.org> Move the IntrinsicLowering header into the CodeGen directory


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@14265 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
f70c22b019494723d0e706f93d6542dfaa6e73a5 17-Jun-2004 Chris Lattner <sabre@nondot.org> Rename Type::PrimitiveID to TypeId and ::getPrimitiveID() to ::getTypeID()


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@14201 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
6f05f35a84d4251e7d1f6cc5beb69ddbfd3b79f9 27-May-2004 Chris Lattner <sabre@nondot.org> Remove long unused #includes


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@13857 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
7d1bd336abf32752d9dcb6993eca899fdfccff93 16-Mar-2004 Chris Lattner <sabre@nondot.org> Fix PR296: [execution engines] Unhandled cast constant expression


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@12435 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
dd2c82a427a089e7c704af44eeeb2a10a38e2519 15-Feb-2004 Chris Lattner <sabre@nondot.org> Make the JIT zero out globals with memset instead of an element at a time. This
should speed it up a bit on a lot of programs


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@11472 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
23c472436940aa7fc82ff99e8cca6788d08a8105 08-Feb-2004 Chris Lattner <sabre@nondot.org> Print out all globals as they are emitted, not just those emitted from
emitGlobals


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@11191 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
338733fdd2ba0d00ad2ace03836f3e0cbb3f8922 01-Feb-2004 Chris Lattner <sabre@nondot.org> Print an error message if we can't materialize the bytecode file


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@11043 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
55d86482bd9fac6f90a7f6fb35c2f4dec9569fdb 31-Dec-2003 Chris Lattner <sabre@nondot.org> Add new ExecutionEngine::getGlobalValueAtAddress method, which can efficiently
turn a memory address back into the LLVM global object that starts at that
address. Note that this won't cause any additional datastructures to be built
for clients of the EE that don't need this information.

Also modified some code to not access the GlobalAddress map directly.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@10674 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
7301178aac1baf1cc334e7c7a66bfe50a65fbf49 28-Dec-2003 Chris Lattner <sabre@nondot.org> Pass around IntrinsicLowering instances as appropriate.
Reimplement the Interpreters implementation of va_* to be more direct.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@10627 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
87f03108f282a9b5f172f91679bd89ddbb5a65be 26-Dec-2003 Chris Lattner <sabre@nondot.org> Factor code out of LLI


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@10616 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
c07ed1387503d25c0b93fcf617f69329d73fc589 20-Dec-2003 Chris Lattner <sabre@nondot.org> Implement PR135, lazy emission of global variables


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@10549 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
24b0a18c4357de0515c542e97edb2c2eacc543f2 20-Dec-2003 Chris Lattner <sabre@nondot.org> Simple refactorings to prepare for lazy global emission
Also, add a stat for the number of globals emitted


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@10547 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
61612df9cb596448b8310e479d568d6b2a8e8a4c 20-Dec-2003 Chris Lattner <sabre@nondot.org> Update for changes in the JIT


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@10543 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
38f0ebad9aff85786c1273cfb8aa1b4bd838100a 08-Dec-2003 Chris Lattner <sabre@nondot.org> Use the new method, though noone currently implements it any better than before


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@10320 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
c2ee9b9c7a6517f959aea31fa2c61631fe2f2903 19-Nov-2003 Chris Lattner <sabre@nondot.org> Fine grainify namespaceification


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@10093 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
d0fde30ce850b78371fd1386338350591f9ff494 11-Nov-2003 Brian Gaeke <gaeke@uiuc.edu> Put all LLVM code into the llvm namespace, as per bug 109.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@9903 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
20a277e162f971ec1b9c6f2c90a214c177d54f99 24-Oct-2003 Brian Gaeke <gaeke@uiuc.edu> ExecutionEngine::create no longer takes a TraceMode argument.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@9488 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
b576c94c15af9a440f69d9d03c2afead7971118c 20-Oct-2003 John Criswell <criswell@uiuc.edu> Added LLVM project notice to the top of every C++ source file.
Header files will be on the way.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@9298 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
05701573aac26e87a33e8aa58817e4dc5a40050a 17-Oct-2003 Misha Brukman <brukman+llvm@gmail.com> Don't release the Module, as that invalidates the Module* within the
ModuleProvider, which has bad consequences in lli::callAsMain() which tries to
access that same Module*.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@9205 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
19684164a7b695b9dc22d879675e8d2b286ef7e5 16-Oct-2003 Misha Brukman <brukman+llvm@gmail.com> * Reorder includes as per the style guide
* Move the constructors from .h file here
* Document ExecutionEngine::create()
* Catch exception possibly thrown by ModuleProvider::releaseModule()


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@9181 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
7b2b40f9ac21e7349735dd7a5096f29a35d8cd02 14-Oct-2003 Misha Brukman <brukman+llvm@gmail.com> Enabling incremental bytecode loading in the JIT:
* ExecutionEngine and VM can be constructed using a ModuleProvider.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@9124 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
4afac18fd4cae1b93907d7db03c5fdb7f2f66d64 10-Oct-2003 Misha Brukman <brukman+llvm@gmail.com> * Tabs to spaces
* Doxygenified function comments
* Added FIXMEs to solicit documentation for other functions


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@9022 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
322cdb2e63ef29d2c00c9aa3118482eda5fdf637 10-Oct-2003 Brian Gaeke <gaeke@uiuc.edu> Change to use GetAddressOfSymbol instead of dlsym.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@9012 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
fd13129bdf7324b2e8181a653897269aaaecc4e8 05-Sep-2003 Chris Lattner <sabre@nondot.org> Reorder #includes to follow LLVM conventions


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@8375 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
9722294d30fff2a432d8e171eb904f33956353e2 05-Sep-2003 Brian Gaeke <gaeke@uiuc.edu> ExecutionEngine.h, GenericValue.h --> include/llvm/ExecutionEngine/
Build ExecutionEngine as library.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@8370 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
70975eef572b9e132bbaade16ba9edb76f15f287 05-Sep-2003 Brian Gaeke <gaeke@uiuc.edu> Make CreateArgv part of lli rather than part of ExecutionEngine.
Switch Interpreter and JIT's "run" methods to take a Function and a vector of
GenericValues.
Move (almost all of) the stuff that constructs a canonical call to main()
into lli (new methods "callAsMain", "makeStringVector").
Nuke getCurrentExecutablePath(), enableTracing(), getCurrentFunction(),
isStopped(), and many dead decls from interpreter.
Add linux strdup() support to interpreter.
Make interpreter's atexit handler runner and JIT's runAtExitHandlers() look
more alike, in preparation for refactoring.
atexit() is spelled "atexit", not "at_exit".


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@8366 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
8e539488816c9e52bde0af475f72cd3e6407d558 05-Sep-2003 Brian Gaeke <gaeke@uiuc.edu> Move EE dtor where it belongs


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@8345 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
f58815e161c8c91075dd1af7a277314190ebc286 05-Sep-2003 Brian Gaeke <gaeke@uiuc.edu> Interpreter cleanups:

Get rid of support for DebugMode (make it always off).
Mung some comments.
Get rid of interpreter's PROFILE_STRUCTURE_FIELDS and PerformExitStuff
which have been disabled forever.
Get rid of -abort-on-exception (make it always on).
Get rid of user interaction stuff (debug mode innards).
Simplify Interpreter's callMainFunction().


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@8344 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
82d8277ad5862b54341808812bb4016e52347060 03-Sep-2003 Brian Gaeke <gaeke@uiuc.edu> ExecutionEngine.cpp: Move execution engine creation stuff into a new
static method here.
Remove some extra blank lines.
ExecutionEngine.h: Add its prototype.
lli.cpp: Call it.

Make creation method for each type of EE into a static method of its
own subclass.

Interpreter/Interpreter.cpp: ExecutionEngine::createInterpreter -->
Interpreter::create
Interpreter/Interpreter.h: Likewise.
JIT/JIT.cpp: ExecutionEngine::createJIT --> VM::create
JIT/VM.h: Likewise.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@8343 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
c879e8ffc477b466fba4c01dd8c5c5af5d8cabbb 24-Aug-2003 Chris Lattner <sabre@nondot.org> Consult the target data, not the module, about how large the current pointer
size is. This ensures that if the module has no specified pointer size that
things will work correctly.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@8136 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
1543e40cea50d244979f0667f453cf3466a6106c 24-Aug-2003 Chris Lattner <sabre@nondot.org> Add preliminary support for "any" pointersize/endianness. This will need
to change soon though.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@8123 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
c88a4ea0d6ba705a81401eda50796b15c994f6f9 18-Aug-2003 Chris Lattner <sabre@nondot.org> no really, implement it!


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@7955 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
74cf81919d3a44457bec1cbf01b655c80f4673b1 18-Aug-2003 Chris Lattner <sabre@nondot.org> Add support for casting any pointer to any integer type


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@7953 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
37df460874e8d9d28e6833e5fb66a9aa8e1ef50a 13-Aug-2003 Brian Gaeke <gaeke@uiuc.edu> In ExecutionEngine::getPointerToGlobal(), throw away const qualifier
on Function * when passing it to getPointerToFunction().


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@7818 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
3785fad56eb90284d4e930d40e9306391630deb1 05-Aug-2003 Chris Lattner <sabre@nondot.org> Specify DEBUG_TYPE's for the JIT debug messages


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@7604 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
c648dabf65c67d20c208ed0b39b9622387e636c7 02-Aug-2003 Chris Lattner <sabre@nondot.org> DEBUG got moved to Debug.h


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@7491 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
06dabfaed55d37cf40e811586ba06b5779e58ab9 18-Jul-2003 Misha Brukman <brukman+llvm@gmail.com> Cleaned up the code which chooses the appropriate value for the file descriptor
to pass to dlsym() -- Linux/x86 wants 0 while Sparc/Solaris wants RTLD_SELF,
which is not zero. Thanks to Chris for the suggestion.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@7204 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
859e09f06ea44b9182119fce4c75ba52baf429a6 15-Jul-2003 Misha Brukman <brukman+llvm@gmail.com> Clean up my last checkin: code is easier to read and explains the differences in
usage of the special file handle RTLD_SELF on Sparc/Solaris vs. 0 on Linux/x86.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@7177 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
291c2c59b011436087ba1982a6b5fe0609336f05 15-Jul-2003 Misha Brukman <brukman+llvm@gmail.com> On Sparc/Solaris, the special handle RTLD_SELF is used as a handle referring to
the program's executing image, not 0 as it is on Linux/x86 and possibly other
systems.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@7176 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
7a73b80b9052136c8cd2234eb3433a07df7cf38e 30-Jun-2003 John Criswell <criswell@uiuc.edu> Merged in autoconf branch. This provides configuration via the autoconf
system.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@7014 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
6b2125c62426190c4be63668e3116ecf3b25fc23 14-May-2003 Chris Lattner <sabre@nondot.org> Fix typeos


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@6204 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
9a23122b6a4decff3d3f10cb8d9b5ccebe5c7474 14-May-2003 Chris Lattner <sabre@nondot.org> Add support for more constant expressions


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@6203 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
7e527424fcc5e8931f9215e3a80bb266440ac613 13-May-2003 Chris Lattner <sabre@nondot.org> Clean up cast


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@6174 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
f88b9a639770327196b2a00f365155b954dd1d30 08-May-2003 Chris Lattner <sabre@nondot.org> Add a pointersize/endianness safe load routine to match the store routine


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@6042 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
b2abb5a586b50b0ac53618c181241d4c2e45b5f4 07-May-2003 Chris Lattner <sabre@nondot.org> Fix bug: Jello/2003-05-07-ArgumentTest.llx
Also fixes yacr2/ks benchmarks


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@6017 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
2be50797a1391278489fa698aa8e17d3f8b04a59 23-Apr-2003 Chris Lattner <sabre@nondot.org> Fix bug where pointers were assumed to always be 64 bits in size!


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@5890 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
d8c03bfa0a8cbcbf3ee31b0e9b52126c9dbafe2a 23-Apr-2003 Chris Lattner <sabre@nondot.org> * Implement access to external variables in LLI
* Implement GetElementPtr constant expressions when initializing global variables


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@5880 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
59ee0eeffd650adee31ea1f67649a0ee59dd2330 22-Apr-2003 Chris Lattner <sabre@nondot.org> Make stderr, stdout, stdin work with LLI


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@5832 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
92798d78498c72e9cf4f2ee7803c844888fa085b 13-Jan-2003 Chris Lattner <sabre@nondot.org> Add fixme


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@5251 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
623a2225103680f68e6aeaff6c25674da8357e1f 28-Dec-2002 Chris Lattner <sabre@nondot.org> Add diagnostic output


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@5157 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
d6840ac046715061d42e4dd5375cd9ed6dd3dca4 24-Dec-2002 Chris Lattner <sabre@nondot.org> Fixes to compile with GCC 3.2


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@5134 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp
bd199fb1148b9e16c4e6f3d0ee386c2505a55b71 24-Dec-2002 Chris Lattner <sabre@nondot.org> Initial checkin of new LLI with JIT compiler


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@5126 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/lib/ExecutionEngine/ExecutionEngine.cpp