History log of /external/llvm/include/llvm/Target/TargetOptions.h
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/include/llvm/Target/TargetOptions.h
dce4a407a24b04eebc6a376f8e62b41aaa7b071f 29-May-2014 Stephen Hines <srhines@google.com> Update LLVM for 3.5 rebase (r209712).

Change-Id: I149556c940fb7dc92d075273c87ff584f400941f
/external/llvm/include/llvm/Target/TargetOptions.h
36b56886974eae4f9c5ebc96befd3e7bfe5de338 24-Apr-2014 Stephen Hines <srhines@google.com> Update to LLVM 3.5a.

Change-Id: Ifadecab779f128e62e430c2b4f6ddd84953ed617
/external/llvm/include/llvm/Target/TargetOptions.h
0de283dfa2686e30b44a3f6d7ce081588bf4910f 05-Nov-2013 Todd Fiala <tfiala@google.com> Fixes for LLDB build to work around host 4.6.2+ compiler issues.

These fixes to the LLVM source add manual copy constructor and operator=()
methods for classes that use member bitfields and are used in templated
containers.

The intent is to keep this change (and related LLDB and clang changes)
local to android only until we either fix the compiler or use a new one
for host executable builds.

Change-Id: I8c6b31be0b3cfc79cb89b591c41cbbfdf0157c6c
/external/llvm/include/llvm/Target/TargetOptions.h
61fc8d670f1e991804c2ab753e567981e60962cb 01-Aug-2013 Bill Wendling <isanbard@gmail.com> Use function attributes to indicate that we don't want to realign the stack.

Function attributes are the future! So just query whether we want to realign the
stack directly from the function instead of through a random target options
structure.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@187618 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/include/llvm/Target/TargetOptions.h
f245ae5a4a78d5a02b3b9e2dae819077a56d81e7 25-Jul-2013 Bill Wendling <isanbard@gmail.com> Replace the "NoFramePointerElimNonLeaf" target option with a function attribute.

There's no need to specify a flag to omit frame pointer elimination on non-leaf
nodes...(Honestly, I can't parse that option out.) Use the function attribute
stuff instead.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@187093 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/include/llvm/Target/TargetOptions.h
0dcba2fadb990ba2298ba43d76372c754b240cee 22-Jul-2013 Bill Wendling <isanbard@gmail.com> Recommit r186217 with testcase fix:

Use the function attributes to pass along the stack protector buffer size.

Now that we have robust function attributes, don't use a command line option to
specify the stack protecto buffer size.



git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@186863 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/include/llvm/Target/TargetOptions.h
12c74dc2c2ee306f60fb39a9b2a43000e23addcc 13-Jul-2013 Chandler Carruth <chandlerc@gmail.com> Revert commit r186217 -- this is breaking bots:

http://lab.llvm.org:8013/builders/clang-x86_64-darwin11-nobootstrap-RAincremental/builds/4328

Original commit log:
Use the function attributes to pass along the stack protector buffer
size.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@186234 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/include/llvm/Target/TargetOptions.h
8a50013cc23810aa3e1ac8da66764fbb2d96147e 13-Jul-2013 Bill Wendling <isanbard@gmail.com> Use the function attributes to pass along the stack protector buffer size.

Now that we have robust function attributes, don't use a command line option to
specify the stack protecto buffer size.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@186217 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/include/llvm/Target/TargetOptions.h
face8d901ebc2f3ac26e303603aae1b9304c4728 20-Jun-2013 Bill Wendling <isanbard@gmail.com> Remove static, because it was messing everything up.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@184400 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/include/llvm/Target/TargetOptions.h
3b6e067f56db88509d9254ecc70951d77d51a2d7 20-Jun-2013 Bill Wendling <isanbard@gmail.com> Make the '==' operator inline.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@184375 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/include/llvm/Target/TargetOptions.h
8623ecb263ef2b2e13e34608d90dca52f21fd6db 20-Jun-2013 Bill Wendling <isanbard@gmail.com> Make this static inline to avoid duplicates.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@184374 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/include/llvm/Target/TargetOptions.h
59aa54073848645cd20c828dfb1088127c541b36 20-Jun-2013 Bill Wendling <isanbard@gmail.com> Make the comparison operators non-member functions.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@184373 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/include/llvm/Target/TargetOptions.h
2e1dc2d2650c64f8fa57d12eb194dcf57e85ebb7 19-Jun-2013 Bill Wendling <isanbard@gmail.com> Add operator!= as the compliment to operator==. This is for a future change.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@184348 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/include/llvm/Target/TargetOptions.h
e4496548155ba6606f107fbdc10ea17e58fd3401 07-May-2013 Rafael Espindola <rafael.espindola@gmail.com> Remove exception handling support from the old JIT.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@181354 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/include/llvm/Target/TargetOptions.h
13bbe1f52e8d57151e2730db49094e1c62a4c793 05-Apr-2013 Bill Wendling <isanbard@gmail.com> Use the target options specified on a function to reset the back-end.

During LTO, the target options on functions within the same Module may
change. This would necessitate resetting some of the back-end. Do this for X86,
because it's a Friday afternoon.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@178917 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/include/llvm/Target/TargetOptions.h
b09350d9a5639f55c46659b30be12a0c938378ab 23-Jan-2013 Chad Rosier <mcrosier@apple.com> Initialize SSPBufferSize. PR14999. Patch by Vinson Lee.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@173285 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/include/llvm/Target/TargetOptions.h
33634833aa651cab5ea92b87822c038fb6e71778 29-Nov-2012 Chad Rosier <mcrosier@apple.com> Whitespace.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@168937 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/include/llvm/Target/TargetOptions.h
a04d6c948cd6f273f6146fdb95a76e3bc587b9d4 29-Nov-2012 Chad Rosier <mcrosier@apple.com> Fix 80-column violations.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@168936 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/include/llvm/Target/TargetOptions.h
b3235b128f383559a7a9b9119896e406b347879c 09-Nov-2012 Chad Rosier <mcrosier@apple.com> Revert r167620; this can be implemented using an existing CL option.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@167622 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/include/llvm/Target/TargetOptions.h
d054eda44114df411a2749e7b6b85d27509a0af1 09-Nov-2012 Chad Rosier <mcrosier@apple.com> Add support for -mstrict-align compiler option for ARM targets.
rdar://12340498


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@167620 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/include/llvm/Target/TargetOptions.h
35907e98626b33f6406dc498201fc59ced282c8a 21-Aug-2012 Chad Rosier <mcrosier@apple.com> Add support for the --param ssp-buffer-size= driver option.
PR9673

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@162284 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/include/llvm/Target/TargetOptions.h
769951f6cc6323821ce1e9f46a37817a541c884f 03-Jul-2012 Evan Cheng <evan.cheng@apple.com> Target option DisableJumpTables is a gross hack. Move it to TargetLowering instead.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@159611 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/include/llvm/Target/TargetOptions.h
e0231413225cf47aaf3238bf21afd0d59025028d 22-Jun-2012 Lang Hames <lhames@gmail.com> Rename -allow-excess-fp-precision flag to -fuse-fp-ops, and switch from a
boolean flag to an enum: { Fast, Standard, Strict } (default = Standard).

This option controls the creation by optimizations of fused FP ops that store
intermediate results in higher precision than IEEE allows (E.g. FMAs). The
behavior of this option is intended to match the behaviour specified by a
soon-to-be-introduced frontend flag: '-ffuse-fp-ops'.

Fast mode - allows formation of fused FP ops whenever they're profitable.

Standard mode - allow fusion only for 'blessed' FP ops. At present the only
blessed op is the fmuladd intrinsic. In the future more blessed ops may be
added.

Strict mode - allow fusion only if/when it can be proven that the excess
precision won't effect the result.

Note: This option only controls formation of fused ops by the optimizers. Fused
operations that are explicitly requested (e.g. FMA via the llvm.fma.* intrinsic)
will always be honored, regardless of the value of this option.

Internally TargetOptions::AllowExcessFPPrecision has been replaced by
TargetOptions::AllowFPOpFusion.



git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@158956 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/include/llvm/Target/TargetOptions.h
d693cafcfb9e67ba7040cb810e4409a166421482 20-Jun-2012 Lang Hames <lhames@gmail.com> Add DAG-combines for aggressive FMA formation.

This patch adds DAG combines to form FMAs from pairs of FADD + FMUL or
FSUB + FMUL. The combines are performed when:
(a) Either
AllowExcessFPPrecision option (-enable-excess-fp-precision for llc)
OR
UnsafeFPMath option (-enable-unsafe-fp-math)
are set, and
(b) TargetLoweringInfo::isFMAFasterThanMulAndAdd(VT) is true for the type of
the FADD/FSUB, and
(c) The FMUL only has one user (the FADD/FSUB).

If your target has fast FMA instructions you can make use of these combines by
overriding TargetLoweringInfo::isFMAFasterThanMulAndAdd(VT) to return true for
types supported by your FMA instruction, and adding patterns to match ISD::FMA
to your FMA instructions.



git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@158757 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/include/llvm/Target/TargetOptions.h
d6b43a317e71246380db55a50b799b062b53cdce 19-Jun-2012 Rafael Espindola <rafael.espindola@gmail.com> Move the support for using .init_array from ARM to the generic
TargetLoweringObjectFileELF. Use this to support it on X86. Unlike ARM,
on X86 it is not easy to find out if .init_array should be used or not, so
the decision is made via TargetOptions and defaults to off.

Add a command line option to llc that enables it.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@158692 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/include/llvm/Target/TargetOptions.h
21293ac192d84f51c0f75c37ba50d90becc3e008 11-Apr-2012 Duncan Sands <baldrick@free.fr> Comment typo fix.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@154488 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/include/llvm/Target/TargetOptions.h
253933ee9ef2c413ecd782efeacc5d7b9bcda09a 08-Apr-2012 Chandler Carruth <chandlerc@gmail.com> Teach LLVM about a PIE option which, when enabled on top of PIC, makes
optimizations which are valid for position independent code being linked
into a single executable, but not for such code being linked into
a shared library.

I discussed the design of this with Eric Christopher, and the decision
was to support an optional bit rather than a completely separate
relocation model. Fundamentally, this is still PIC relocation, its just
that certain optimizations are only valid under a PIC relocation model
when the resulting code won't be in a shared library. The simplest path
to here is to expose a single bit option in the TargetOptions. If folks
have different/better designs, I'm all ears. =]

I've included the first optimization based upon this: changing TLS
models to the *Exec models when PIE is enabled. This is the LLVM
component of PR12380 and is all of the hard work.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@154294 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/include/llvm/Target/TargetOptions.h
8dd26253f54247e77e5accfdd70e7b4bf27b39c2 10-Feb-2012 Andrew Trick <atrick@apple.com> RegAlloc superpass: includes phi elimination, coalescing, and scheduling.

Creates a configurable regalloc pipeline.

Ensure specific llc options do what they say and nothing more: -reglloc=... has no effect other than selecting the allocator pass itself. This patch introduces a new umbrella flag, "-optimize-regalloc", to enable/disable the optimizing regalloc "superpass". This allows for example testing coalscing and scheduling under -O0 or vice-versa.

When a CodeGen pass requires the MachineFunction to have a particular property, we need to explicitly define that property so it can be directly queried rather than naming a specific Pass. For example, to check for SSA, use MRI->isSSA, not addRequired<PHIElimination>.

CodeGen transformation passes are never "required" as an analysis

ProcessImplicitDefs does not require LiveVariables.

We have a plan to massively simplify some of the early passes within the regalloc superpass.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@150226 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/include/llvm/Target/TargetOptions.h
22de16dc7582dac43429ce0dcb374604020c01f5 19-Jan-2012 Nick Lewycky <nicholas@mxc.ca> Add a TargetOption for disabling tail calls.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@148442 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/include/llvm/Target/TargetOptions.h
c1b1c7b205589c9a081e1cbd33fb56506fc287b3 17-Jan-2012 Andrew Trick <atrick@apple.com> Moving options declarations around.

More short term hackery until we have a way to configure passes that work on LiveIntervals.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@148289 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/include/llvm/Target/TargetOptions.h
96f678f2d78ae9a2a8c99ca612bf59c056b36797 13-Jan-2012 Andrew Trick <atrick@apple.com> Added the MachineSchedulerPass skeleton.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@148105 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/include/llvm/Target/TargetOptions.h
b3fe88f8379c4c4193d5d84267ae1a304437f8fa 13-Jan-2012 Andrew Trick <atrick@apple.com> whitespace

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@148104 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/include/llvm/Target/TargetOptions.h
8a8d479214745c82ef00f08d4e4f1c173b5f9ce2 02-Dec-2011 Nick Lewycky <nicholas@mxc.ca> Move global variables in TargetMachine into new TargetOptions class. As an API
change, now you need a TargetOptions object to create a TargetMachine. Clang
patch to follow.

One small functionality change in PTX. PTX had commented out the machine
verifier parts in their copy of printAndVerify. That now calls the version in
LLVMTargetMachine. Users of PTX who need verification disabled should rely on
not passing the command-line flag to enable it.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@145714 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/include/llvm/Target/TargetOptions.h
84a61269370138b68ae2bcd6711a9ae8004fd77a 04-Nov-2011 Eli Friedman <eli.friedman@gmail.com> Add missing includes/decls.



git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@143722 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/include/llvm/Target/TargetOptions.h
0f9827cd9417c7385c92fa4a0d8d8b4242b3729d 30-Aug-2011 Rafael Espindola <rafael.espindola@gmail.com> Command line option to enable support for segmented stacks:
-segmented-stacks.
Patch by Sanjoy Das!

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@138811 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/include/llvm/Target/TargetOptions.h
f05589d0430a543e8158b912dcb8117bf5cb376e 23-Jun-2011 Evan Cheng <evan.cheng@apple.com> Rename TargetOptions::StackAlignment to StackAlignmentOverride.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@133739 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/include/llvm/Target/TargetOptions.h
fc2bb8c4448fa884d79e437cc2d2627a7d7740a8 25-May-2011 Rafael Espindola <rafael.espindola@gmail.com> Replace the -unwind-tables option with a per function flag. This is more
LTO friendly as we can now correctly merge files compiled with or without
-fasynchronous-unwind-tables.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@132033 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/include/llvm/Target/TargetOptions.h
c8578948c9b35080dedd6527abf4f48fc4de43d3 21-Apr-2011 Evan Cheng <evan.cheng@apple.com> Remove -use-divmod-libcall. Let targets opt in when they are available.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@129884 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/include/llvm/Target/TargetOptions.h
4da0c7c0c9081107bea5f6bac440f0f1eb47748f 08-Apr-2011 Evan Cheng <evan.cheng@apple.com> Change -arm-trap-func= into a non-arm specific option. Now Intrinsic::trap is lowered into a call to the specified trap function at sdisel time.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@129152 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/include/llvm/Target/TargetOptions.h
2c69f8eec6a51114799e3e80fa4903c5e3fc429c 07-Apr-2011 Evan Cheng <evan.cheng@apple.com> Change -arm-divmod-libcall to a target neutral option.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@129045 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/include/llvm/Target/TargetOptions.h
c728ad43497935c0ae292ffdb2776b15c7a9a5c5 29-Jul-2010 Eric Christopher <echristo@apple.com> Grammar.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@109775 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/include/llvm/Target/TargetOptions.h
60108e96bbc5432f4fe06ba313e64448e97a0e15 16-Jul-2010 Evan Cheng <evan.cheng@apple.com> Split -enable-finite-only-fp-math to two options:
-enable-no-nans-fp-math and -enable-no-infs-fp-math. All of the current codegen fp math optimizations only care whether the fp arithmetics arguments and results can never be NaN.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@108465 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/include/llvm/Target/TargetOptions.h
db20d257bcd246f17f250928221bf6449a004f6d 13-Jul-2010 Evan Cheng <evan.cheng@apple.com> Update comment.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@108272 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/include/llvm/Target/TargetOptions.h
57b6e9eb6ccb757b74beeb377c7c16d08468d3e8 02-May-2010 Duncan Sands <baldrick@free.fr> Remove the -enable-sjlj-eh option, which doesn't do anything.
Remove the -enable-eh option which is only used by the JIT,
and replace it with -jit-enable-eh.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@102865 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/include/llvm/Target/TargetOptions.h
e566763b1915c7a4821ce95937b763724d271fec 21-Apr-2010 Evan Cheng <evan.cheng@apple.com> Implement -disable-non-leaf-fp-elim which disable frame pointer elimination
optimization for non-leaf functions. This will be hooked up to gcc's
-momit-leaf-frame-pointer option. rdar://7886181


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@101984 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/include/llvm/Target/TargetOptions.h
b095ba439ddc9199d2340e55b29a93050fae7639 17-Mar-2010 Chris Lattner <sabre@nondot.org> remove dead variable, patch by Nathan Howell!


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@98704 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/include/llvm/Target/TargetOptions.h
1797ed50f488f2030f9f9a0ac7426262abf5220a 08-Feb-2010 Dan Gohman <gohman@apple.com> Rename the PerformTailCallOpt variable to GuaranteedTailCallOpt to reflect
its current purpose.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@95564 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/include/llvm/Target/TargetOptions.h
b4e6a5df5dada0cd919cc6e2717eb3118db9cc45 19-Dec-2009 Bill Wendling <isanbard@gmail.com> Changes from review:

- Move DisableScheduling flag into TargetOption.h
- Move SDNodeOrdering into its own header file. Give it a minimal interface that
doesn't conflate construction with storage.
- Move assigning the ordering into the SelectionDAGBuilder.

This isn't used yet, so there should be no functional changes.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@91727 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/include/llvm/Target/TargetOptions.h
2763217fbd2f1c54a7a25fd3ae9e997ea6ece0cb 21-Sep-2009 Reid Kleckner <reid@kleckner.net> Implement the JIT side of the GDB JIT debugging interface. To enable this
feature, either build the JIT in debug mode to enable it by default or pass
-jit-emit-debug to lli.

Right now, the only debug information that this communicates to GDB is call
frame information, since it's already being generated to support exceptions in
the JIT. Eventually, when DWARF generation isn't tied so tightly to AsmPrinter,
it will be easy to push that information to GDB through this interface.

Here's a step-by-step breakdown of how the feature works:

- The JIT generates the machine code and DWARF call frame info
(.eh_frame/.debug_frame) for a function into memory.
- The JIT copies that info into an in-memory ELF file with a symbol for the
function.
- The JIT creates a code entry pointing to the ELF buffer and adds it to a
linked list hanging off of a global descriptor at a special symbol that GDB
knows about.
- The JIT calls a function marked noinline that GDB knows about and has put an
internal breakpoint in.
- GDB catches the breakpoint and reads the global descriptor to look for new
code.
- When sees there is new code, it reads the ELF from the inferior's memory and
adds it to itself as an object file.
- The JIT continues, and the next time we stop the program, we are able to
produce a proper backtrace.

Consider running the following program through the JIT:

#include <stdio.h>
void baz(short z) {
long w = z + 1;
printf("%d, %x\n", w, *((int*)NULL)); // SEGFAULT here
}
void bar(short y) {
int z = y + 1;
baz(z);
}
void foo(char x) {
short y = x + 1;
bar(y);
}
int main(int argc, char** argv) {
char x = 1;
foo(x);
}

Here is a backtrace before this patch:
Program received signal SIGSEGV, Segmentation fault.
[Switching to Thread 0x2aaaabdfbd10 (LWP 25476)]
0x00002aaaabe7d1a8 in ?? ()
(gdb) bt
#0 0x00002aaaabe7d1a8 in ?? ()
#1 0x0000000000000003 in ?? ()
#2 0x0000000000000004 in ?? ()
#3 0x00032aaaabe7cfd0 in ?? ()
#4 0x00002aaaabe7d12c in ?? ()
#5 0x00022aaa00000003 in ?? ()
#6 0x00002aaaabe7d0aa in ?? ()
#7 0x01000002abe7cff0 in ?? ()
#8 0x00002aaaabe7d02c in ?? ()
#9 0x0100000000000001 in ?? ()
#10 0x00000000014388e0 in ?? ()
#11 0x00007fff00000001 in ?? ()
#12 0x0000000000b870a2 in llvm::JIT::runFunction (this=0x1405b70,
F=0x14024e0, ArgValues=@0x7fffffffe050)
at /home/rnk/llvm-gdb/lib/ExecutionEngine/JIT/JIT.cpp:395
#13 0x0000000000baa4c5 in llvm::ExecutionEngine::runFunctionAsMain
(this=0x1405b70, Fn=0x14024e0, argv=@0x13f06f8, envp=0x7fffffffe3b0)
at /home/rnk/llvm-gdb/lib/ExecutionEngine/ExecutionEngine.cpp:377
#14 0x00000000007ebd52 in main (argc=2, argv=0x7fffffffe398,
envp=0x7fffffffe3b0) at /home/rnk/llvm-gdb/tools/lli/lli.cpp:208

And a backtrace after this patch:
Program received signal SIGSEGV, Segmentation fault.
0x00002aaaabe7d1a8 in baz ()
(gdb) bt
#0 0x00002aaaabe7d1a8 in baz ()
#1 0x00002aaaabe7d12c in bar ()
#2 0x00002aaaabe7d0aa in foo ()
#3 0x00002aaaabe7d02c in main ()
#4 0x0000000000b870a2 in llvm::JIT::runFunction (this=0x1405b70,
F=0x14024e0, ArgValues=...)
at /home/rnk/llvm-gdb/lib/ExecutionEngine/JIT/JIT.cpp:395
#5 0x0000000000baa4c5 in llvm::ExecutionEngine::runFunctionAsMain
(this=0x1405b70, Fn=0x14024e0, argv=..., envp=0x7fffffffe3c0)
at /home/rnk/llvm-gdb/lib/ExecutionEngine/ExecutionEngine.cpp:377
#6 0x00000000007ebd52 in main (argc=2, argv=0x7fffffffe3a8,
envp=0x7fffffffe3c0) at /home/rnk/llvm-gdb/tools/lli/lli.cpp:208


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@82418 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/include/llvm/Target/TargetOptions.h
1b747ad8a0694b86e8d98a8b9a05ddfe74ec0cd3 11-Aug-2009 Jim Grosbach <grosbach@apple.com> SjLj based exception handling unwinding support. This patch is nasty, brutish
and short. Well, it's kinda short. Definitely nasty and brutish.

The front-end generates the register/unregister calls into the SjLj runtime,
call-site indices and landing pad dispatch. The back end fills in the LSDA
with the call-site information provided by the front end. Catch blocks are
not yet implemented.

Built on Darwin and verified no llvm-core "make check" regressions.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@78625 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/include/llvm/Target/TargetOptions.h
05e5fcab0910b7e0ebdd03cb4c1960ae8ba219fd 02-Aug-2009 Chris Lattner <sabre@nondot.org> move an enum from TM -> TargetOptions. This makes TargetOptions.h
be self contained, and it isn't used from TM.h


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@77857 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/include/llvm/Target/TargetOptions.h
0eebf653a7b2978e7761f8d068b6fbec22aea0f6 09-Jun-2009 Anton Korobeynikov <asl@math.spbu.ru> The attached patches implement most of the ARM AAPCS-VFP hard float
ABI. The missing piece is support for putting "homogeneous aggregates"
into registers.

Patch by Sandeep Patel!

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@73095 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/include/llvm/Target/TargetOptions.h
578efa920abd218ba75a0fb3c9b8398f4c0a774b 05-Jun-2009 Devang Patel <dpatel@apple.com> Add new function attribute - noimplicitfloat
Update code generator to use this attribute and remove NoImplicitFloat target option.
Update llc to set this attribute when -no-implicit-float command line option is used.



git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@72959 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/include/llvm/Target/TargetOptions.h
d18e31ae17390d9c6f6cf93d18badf962452031d 05-Jun-2009 Devang Patel <dpatel@apple.com> Add new function attribute - noredzone.
Update code generator to use this attribute and remove DisableRedZone target option.
Update llc to set this attribute when -disable-red-zone command line option is used.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@72894 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/include/llvm/Target/TargetOptions.h
a24d1b155831d25f543e0e4ece9b572cefda2f17 29-Apr-2009 Bill Wendling <isanbard@gmail.com> Correct comment.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@70340 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/include/llvm/Target/TargetOptions.h
c69d56f1154342a57c9bdd4c17a10333e3520127 28-Apr-2009 Bill Wendling <isanbard@gmail.com> r70270 isn't ready yet. Back this out. Sorry for the noise.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@70275 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/include/llvm/Target/TargetOptions.h
2e9d5f912a9841d3685ba0241abe1131943fed29 28-Apr-2009 Bill Wendling <isanbard@gmail.com> Massive check in. This changes the "-fast" flag to "-O#" in llc. If you want to
use the old behavior, the flag is -O0. This change allows for finer-grained
control over which optimizations are run at different -O levels.

Most of this work was pretty mechanical. The majority of the fixes came from
verifying that a "fast" variable wasn't used anymore. The JIT still uses a
"Fast" flag. I'm not 100% sure if it's necessary to change it there...


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@70270 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/include/llvm/Target/TargetOptions.h
42bf74be1402df7409efbea089310d4c276fde37 25-Mar-2009 Evan Cheng <evan.cheng@apple.com> CodeGen still defaults to non-verbose asm, but llc now overrides it and default to verbose.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@67668 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/include/llvm/Target/TargetOptions.h
bc65ca8de591e278fc613b5dc0e178b2ddcd215e 20-Mar-2009 Mon P Wang <wangmp@apple.com> Added option to enable generating less precise mad (multiply addition)
for those architectures that support the instruction.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@67363 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/include/llvm/Target/TargetOptions.h
f9abd7e33ea6e8f57176d0069d61595c1347a5ff 11-Mar-2009 Bill Wendling <isanbard@gmail.com> Add a -no-implicit-float flag. This acts like -soft-float, but may generate
floating point instructions that are explicitly specified by the user.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@66719 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/include/llvm/Target/TargetOptions.h
92f4f16a19c8d5edafad700a22e76eb2f22b4b31 26-Jan-2009 Dan Gohman <gohman@apple.com> Implement Red Zone utilization on x86-64. This is currently
disabled by default; I'll enable it when I hook it up with
the llvm-gcc flag which controls it.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@63056 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/include/llvm/Target/TargetOptions.h
95dad830bbf975cb4cea4e1ac685781a18676a7a 07-Oct-2008 Owen Anderson <resistor@mac.com> Add an option to enable StrongPHIElimination, for ease of testing.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@57259 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/include/llvm/Target/TargetOptions.h
4ae641f4d12c60ee1aaca5e42b6de231c6a02c40 02-Oct-2008 Devang Patel <dpatel@apple.com> Remove OptimizeForSize global. Use function attribute optsize.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@56937 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/include/llvm/Target/TargetOptions.h
2c4bf119be8aa05cdc3dc88c57006353f07f0d2c 25-Sep-2008 Dan Gohman <gohman@apple.com> Enable DeadMachineInstructionElim when Fast-ISel is enabled.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@56604 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/include/llvm/Target/TargetOptions.h
6ac8df7f611b5b129af7192ad931862fc8169aae 05-Aug-2008 Owen Anderson <resistor@mac.com> This option doesn't need to be a target option. It can be in SDISel instead.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@54336 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/include/llvm/Target/TargetOptions.h
bd3ba461eb5578a81ba09ff7bd7eb271d1130196 05-Aug-2008 Owen Anderson <resistor@mac.com> - Fix SelectionDAG to generate correct CFGs.
- Add a basic machine-level dead block eliminator.

These two have to go together, since many other parts of the code generator are unable to handle the unreachable blocks otherwise created.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@54333 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/include/llvm/Target/TargetOptions.h
7232464bdaae5e6e48986a1e3b9a95fac7aa7bdf 31-Jul-2008 Dale Johannesen <dalej@apple.com> Add a flag to disable jump table generation (all
switches use the binary search algorithm) for
environments that don't support it. PPC64 JIT
is such an environment; turn the flag on for that.



git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@54248 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/include/llvm/Target/TargetOptions.h
6547e406cf934346db7a206b61bcf09635afff0d 02-Jul-2008 Evan Cheng <evan.cheng@apple.com> Avoid creating expensive comment string if it's not going to be printed.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@52992 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/include/llvm/Target/TargetOptions.h
45709ae09b252a18efd342bbd56574a12437c81c 23-Apr-2008 Anton Korobeynikov <asl@math.spbu.ru> Make stack alignment options global for all targets


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@50157 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/include/llvm/Target/TargetOptions.h
3541af73b6b8a083cf2d7784438d60e8bcce3883 14-Apr-2008 Dale Johannesen <dalej@apple.com> Reverse sense of unwind-tables option. This means
stack tracebacks on Darwin x86-64 won't work by default;
nevertheless, everybody but me thinks this is a good idea.



git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@49663 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/include/llvm/Target/TargetOptions.h
4e1b79459fcf72216cdc42a59953e172c60e15ca 08-Apr-2008 Dale Johannesen <dalej@apple.com> Implement new llc flag -disable-required-unwind-tables.
Corresponds to -fno-unwind-tables (usually default in gcc).



git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@49361 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/include/llvm/Target/TargetOptions.h
55c666a867f6c47ada58b3a620be285de719fb8e 25-Mar-2008 Devang Patel <dpatel@apple.com> Add optimize-for-size knob.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@48793 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/include/llvm/Target/TargetOptions.h
7ed47a13356daed2a34cd2209a31f92552e3bdd8 29-Dec-2007 Chris Lattner <sabre@nondot.org> Don't attribute in file headers anymore. See llvmdev for the
discussion of this change. Boy are my fingers tired. ;-)



git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@45411 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/include/llvm/Target/TargetOptions.h
48abc5cf6ba6d53513034aa8c68b0a9abd748190 12-Oct-2007 Arnold Schwaighofer <arnold.schwaighofer@gmail.com> Corrected many typing errors. And removed 'nest' parameter handling
for fastcc from X86CallingConv.td. This means that nested functions
are not supported for calling convention 'fastcc'.



git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@42934 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/include/llvm/Target/TargetOptions.h
c85e1716f0e45e4c18a9ef2fbe431a51ac3a4252 11-Oct-2007 Arnold Schwaighofer <arnold.schwaighofer@gmail.com> Added tail call optimization to the x86 back end. It can be
enabled by passing -tailcallopt to llc. The optimization is
performed if the following conditions are satisfied:
* caller/callee are fastcc
* elf/pic is disabled OR
elf/pic enabled + callee is in module + callee has
visibility protected or hidden


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@42870 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/include/llvm/Target/TargetOptions.h
e5f6204cd5d2306379bf8954e280ad35619a38b5 29-Sep-2007 Evan Cheng <evan.cheng@apple.com> Enabling new condition code modeling scheme.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@42459 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/include/llvm/Target/TargetOptions.h
a3602685b34f4c9a1602fdc7fb120a7f51228736 25-Sep-2007 Evan Cheng <evan.cheng@apple.com> New temporary option -new-cc-modeling-scheme to test the new cc modeling scheme.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@42283 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/include/llvm/Target/TargetOptions.h
d8ebb3a0c2b42c5dedf96cfb7f2f3e87c91e1c23 06-Jul-2007 Dan Gohman <gohman@apple.com> Remove redundant declarations.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@37946 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/include/llvm/Target/TargetOptions.h
aa4f1e164bb9a0fe438c262f40857ca639b56fad 03-May-2007 Chris Lattner <sabre@nondot.org> Add a new option.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@36657 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/include/llvm/Target/TargetOptions.h
1b340dc8e20dc1ce204ebdcc2ff11c3dd36888f1 29-Jan-2007 Jim Laskey <jlaskey@mac.com> Flag to control exception handling.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@33628 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/include/llvm/Target/TargetOptions.h
292a007c946cce20badbe52dbae06d5758bfad42 17-Jan-2007 Anton Korobeynikov <asl@math.spbu.ru> Document flag


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@33300 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/include/llvm/Target/TargetOptions.h
5032e5a61381437174e035de2a7dd728978f7bd5 17-Jan-2007 Anton Korobeynikov <asl@math.spbu.ru> * Fix one more bug in PIC codegen: extra load is needed for *all*
non-statics.
* Introduce new option to output zero-initialized data to .bss section.
This can reduce size of binaries. Enable it by default for ELF &
Cygwin/Mingw targets. Probably, Darwin should be also added.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@33299 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/include/llvm/Target/TargetOptions.h
c9ab2f39ceadefa4ac8c0c922c55a76c0d637a6e 09-Dec-2006 Evan Cheng <evan.cheng@apple.com> Added option -soft-float to generate SW fp library calls instead of fp instructions.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@32393 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/include/llvm/Target/TargetOptions.h
80235d508e5f7a9603ef43ba6625984173ff0323 23-May-2006 Evan Cheng <evan.cheng@apple.com> -enable-unsafe-fp-math implies -enable-finite-only-fp-math


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@28437 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/include/llvm/Target/TargetOptions.h
95942d76f4fdd1191febf1aa2b612fce6351ab3b 23-May-2006 Evan Cheng <evan.cheng@apple.com> Added option -enable-finite-only-fp-math. When on, the codegen can assume that
FP arithmetic arguments and results are never NaNs or +=Infs. This includes
ignoring parity flag (PF) when checking for FP equality.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@28432 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/include/llvm/Target/TargetOptions.h
4c1aa866578f7a358407a22fe55b454f52a24325 22-Feb-2006 Evan Cheng <evan.cheng@apple.com> - Added option -relocation-model to set relocation model. Valid values include static, pic,
dynamic-no-pic, and default.
PPC and x86 default is dynamic-no-pic for Darwin, pic for others.
- Removed options -enable-pic and -ppc-static.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@26315 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/include/llvm/Target/TargetOptions.h
c9fdea915aaeb1343c3e9825886ce18efdb91994 18-Feb-2006 Evan Cheng <evan.cheng@apple.com> Move PICEnabled declaration here.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@26271 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/include/llvm/Target/TargetOptions.h
73bfa7152481620d60bf63d5397dfe35bbc9c098 19-Aug-2005 Nate Begeman <natebegeman@mac.com> Remove the X86 and PowerPC Simple instruction selectors; their time has
passed.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@22886 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/include/llvm/Target/TargetOptions.h
34f74a6162f1e493a9773e83a684cf31fa4838de 30-Apr-2005 Chris Lattner <sabre@nondot.org> Expose an option allowing unsafe math optimizations. Patch contributed by
Morten Ofstad!


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@21630 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/include/llvm/Target/TargetOptions.h
34695381d626485a560594f162701088079589df 21-Apr-2005 Misha Brukman <brukman+llvm@gmail.com> Remove trailing whitespace


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@21412 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/include/llvm/Target/TargetOptions.h
f8b02949e3d13e9b7cd38e029fcbf3e799366aa7 16-Apr-2005 Nate Begeman <natebegeman@mac.com> Make pattern isel default for ppc
Add new ppc beta option related to using condition registers
Make pattern isel control flag (-enable-pattern-isel) global and tristate
0 == off
1 == on
2 == target default


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@21309 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/include/llvm/Target/TargetOptions.h
45554a61f2814e1d445e272076fd7187e74a25c0 15-Jan-2005 Chris Lattner <sabre@nondot.org> Add a new target-independent code generator flag.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@19567 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/include/llvm/Target/TargetOptions.h
635ffcdf58f9bdc35c4ad4969fb35dc3659cf384 11-Jul-2004 Chris Lattner <sabre@nondot.org> Delete the allocate*TargetMachine functions. Move options to a header file
that makes sense.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@14754 91177308-0d34-0410-b5e6-96231b3b80d8
/external/llvm/include/llvm/Target/TargetOptions.h