Jim Grosbach
d3d283dc19
Dwarf EH prepare needs to be run after SjLj prepare. Otherwise,
...
catch info can get misplaced when a selector ends up more than one block
removed from the parent invoke(s). This could happen when a landing pad is
shared by multiple invokes and is also a target of a normal edge from
elsewhere.
llvm-svn: 93456
2010-01-14 21:22:16 +00:00
Chris Lattner
c0321eb1aa
introduce MCParsedAsmOperand
...
llvm-svn: 93455
2010-01-14 21:21:40 +00:00
Chris Lattner
001a94a0e3
introduce the MCParsedAsmOperand class.
...
llvm-svn: 93454
2010-01-14 21:20:55 +00:00
Evan Cheng
595cdb7091
Small tweak to inline cost computation. Ext of i/fcmp results are mostly optimized away in codegen.
...
llvm-svn: 93453
2010-01-14 21:04:31 +00:00
Anton Korobeynikov
d7f6117539
Remove spurious semicolon.
...
Patch by Diego Iastrubni!
llvm-svn: 93450
2010-01-14 20:19:51 +00:00
Victor Hernandez
ff4f0aa119
In debug builds, assert that function-local metadata has only 1 parent function
...
llvm-svn: 93449
2010-01-14 20:12:34 +00:00
Eric Christopher
b2708c4ba1
Reduce the inlining cost of functions that contain calls to easily,
...
and frequently optimized functions.
llvm-svn: 93448
2010-01-14 20:12:34 +00:00
Victor Hernandez
23d77b1e51
Simplify code that chooses when to enumerate function-local metadata operands
...
llvm-svn: 93446
2010-01-14 19:54:11 +00:00
Victor Hernandez
292297e8e2
Avoid modifying ValueEnumerator's MD ValueList by choosing which function-local MD to write based on the function currently being written
...
llvm-svn: 93441
2010-01-14 19:38:44 +00:00
Jakob Stoklund Olesen
97a8d154fb
ARM "l" constraint for inline asm means R0-R7, also for Thumb2.
...
This is consistent with llvm-gcc's arm/constraints.md.
Certain instructions (e.g. CBZ, CBNZ) require a low register, even in Thumb2
mode.
llvm-svn: 93436
2010-01-14 18:19:56 +00:00
Bill Wendling
56464738cc
Use ENABLE_ASSERTIONS throughout.
...
llvm-svn: 93423
2010-01-14 10:19:55 +00:00
Dan Gohman
7c596d2b00
Fix a codegen abort seen in 483.xalancbmk.
...
llvm-svn: 93417
2010-01-14 03:08:49 +00:00
Evan Cheng
71b4e96580
Test for r93409.
...
llvm-svn: 93410
2010-01-14 02:24:50 +00:00
Victor Hernandez
e5f811e0a6
Extend testcase to also test llvm.dbg.value intrinsic
...
llvm-svn: 93408
2010-01-14 02:12:41 +00:00
Victor Hernandez
70e33c3acd
Now that LLParser, AsmWriter, BitcodeReader, and BitcodeWriter all correctly support function-local metadata, test it.
...
llvm-svn: 93406
2010-01-14 01:51:28 +00:00
Victor Hernandez
6878a7e7b6
In WriteFunction(), write function-local metadata before we write the instructions, so instruction's references to metadata are fully resolved by the time they get written.
...
llvm-svn: 93403
2010-01-14 01:50:08 +00:00
Victor Hernandez
36a22e479a
Fix printing of function-local metadata in AsmWriter
...
llvm-svn: 93402
2010-01-14 01:47:37 +00:00
Victor Hernandez
367ef8bf4a
Clean up unnecessary return and brackets
...
llvm-svn: 93401
2010-01-14 01:46:02 +00:00
Victor Hernandez
cc00507183
Add MDNode::getFunction(), which figures out the metadata's function, if it has function that it is local to.
...
llvm-svn: 93400
2010-01-14 01:45:14 +00:00
Jakob Stoklund Olesen
5fdcc970a2
Don't fold insufficiently aligned ldr/str into ldm/stm instructions.
...
An unaligned ldr causes a trap, and is then emulated by the kernel with
awesome performance. The darwin kernel does not emulate unaligned ldm/stm
Thumb2 instructions, so don't generate them.
This fixes the miscompilation of Multisource/Applications/JM/lencod for Thumb2.
Generating unaligned ldr/str pairs from a 16-bit aligned memcpy is probably
also a bad idea, but that is beyond the scope of this patch.
llvm-svn: 93393
2010-01-14 00:54:10 +00:00
Stuart Hastings
a27112f01a
Erm, previous patch was wrong; Thanks Bill\!
...
llvm-svn: 93381
2010-01-14 00:34:53 +00:00
Stuart Hastings
47cfd4abc0
Enable assertions by default for Apple-style builds.
...
llvm-svn: 93380
2010-01-14 00:22:05 +00:00
Chris Lattner
72a06499b3
this is an SSE-specific issue.
...
llvm-svn: 93373
2010-01-13 23:29:11 +00:00
Chris Lattner
0aa093dbdf
X86 if conversion + tail merging issues from PR6032.
...
llvm-svn: 93372
2010-01-13 23:28:40 +00:00
Bill Wendling
488a7187b4
When the visitSub method was split into visitSub and visitFSub, this xform was
...
added to the FSub version. However, the original version of this xform guarded
against doing this for floating point (!Op0->getType()->isFPOrFPVector()).
This is causing LLVM to perform incorrect xforms for code like:
void func(double *rhi, double *rlo, double xh, double xl, double yh, double yl){
double mh, ml;
double c = 134217729.0;
double up, u1, u2, vp, v1, v2;
up = xh*c;
u1 = (xh - up) + up;
u2 = xh - u1;
vp = yh*c;
v1 = (yh - vp) + vp;
v2 = yh - v1;
mh = xh*yh;
ml = (((u1*v1 - mh) + (u1*v2)) + (u2*v1)) + (u2*v2);
ml += xh*yl + xl*yh;
*rhi = mh + ml;
*rlo = (mh - (*rhi)) + ml;
}
The last line was optimized away, but rl is intended to be the difference
between the infinitely precise result of mh + ml and after it has been rounded
to double precision.
llvm-svn: 93369
2010-01-13 23:23:17 +00:00
Tobias Grosser
fc9e55b439
Add getSource() to SuccIterator
...
Get the source BB of an iterator.
llvm-svn: 93364
2010-01-13 22:21:43 +00:00
Tobias Grosser
44e38a98c5
Extend SuccIterator
...
Implement most of the missing methods to make SuccIterator random access.
operator[] is still missing.
llvm-svn: 93363
2010-01-13 22:21:28 +00:00
Chris Lattner
b5605b72b7
this test requires SSE, thanks to jyasskin for pointing this out.
...
llvm-svn: 93360
2010-01-13 21:51:41 +00:00
Chris Lattner
e73ff5ecc3
makeNameProper is now private!
...
llvm-svn: 93357
2010-01-13 21:31:39 +00:00
Chris Lattner
4ce6464609
fix ELF section mangling stuff for weak symbols to not use
...
obsolete Mangler interfaces.
llvm-svn: 93356
2010-01-13 21:29:21 +00:00
Victor Hernandez
55e8dacfed
Fix comment typo
...
llvm-svn: 93355
2010-01-13 21:25:04 +00:00
Chris Lattner
c073f1009a
tidy
...
llvm-svn: 93352
2010-01-13 21:21:29 +00:00
Chris Lattner
4dcb71cc65
reduce duplicate mangling logic by using MCSymbol::printMangledName.
...
llvm-svn: 93351
2010-01-13 21:12:34 +00:00
Chris Lattner
9498bee8a3
expose a static function as a static method on the MCSymbol class.
...
llvm-svn: 93350
2010-01-13 21:09:59 +00:00
Johnny Chen
08c211683b
Fixed a couple of places for Thumb MOV where encoding bits are underspecified.
...
llvm-svn: 93349
2010-01-13 21:00:26 +00:00
Jakob Stoklund Olesen
27e36e52f5
Fix pasto
...
llvm-svn: 93342
2010-01-13 19:54:39 +00:00
Chris Lattner
6d1ddfeff2
stop the CBE from using deprecated Mangler stuff.
...
llvm-svn: 93341
2010-01-13 19:54:07 +00:00
Victor Hernandez
d250df09f5
Write function-local metadata as a metadata subblock of a funciton block
...
llvm-svn: 93339
2010-01-13 19:37:33 +00:00
Victor Hernandez
9938929f1f
Enumerate function-local metadata (and its types and operands) only during function-incorporation, global metadata continues to be enumerated during creation of ValueEnumerator
...
llvm-svn: 93338
2010-01-13 19:36:16 +00:00
Victor Hernandez
4e63ccc1c3
Parse function-local metadata inside function blocks
...
llvm-svn: 93337
2010-01-13 19:34:08 +00:00
Chris Lattner
b255aee77a
Use the GV version of getNameWithPrefix in TargetLoweringObjectFileCOFF::
...
SelectSectionForGlobal, unbreaking weak globals with no-name.
llvm-svn: 93336
2010-01-13 19:19:17 +00:00
Evan Cheng
0fa1e2d063
Commit some changes I had managed to lose last night while refactoring the code. Avoid change use of PHI instructions because it's not legal to insert any instructions before them.
...
This fixes PR6027.
llvm-svn: 93335
2010-01-13 19:16:39 +00:00
Chris Lattner
10021a1e25
just finish MCizing FnStubInfo which cleans it up and simplifies it.
...
llvm-svn: 93334
2010-01-13 19:13:16 +00:00
Chris Lattner
5c38b08b40
don't call getNameWithPrefix repeatedly and unnecesarily.
...
llvm-svn: 93333
2010-01-13 19:05:36 +00:00
Chris Lattner
6b0af1d420
properly use MCSymbol to print the strings aquired from getNameWithPrefix.
...
llvm-svn: 93332
2010-01-13 19:00:57 +00:00
Benjamin Kramer
5db856d384
Introduce Twine::toStringRef, a variant of toVector which avoids the copy if the
...
twine can be represented as a single StringRef. Use the new methode to simplify
some twine users.
llvm-svn: 93317
2010-01-13 12:45:23 +00:00
Evan Cheng
2afc417122
Re-enable extension optimization pass.
...
llvm-svn: 93313
2010-01-13 08:45:40 +00:00
Chris Lattner
d63a5fea41
upgrade and MC'ize a few uses of makeNameProper.
...
llvm-svn: 93310
2010-01-13 08:08:33 +00:00
Chris Lattner
34047fe59f
MC'ize this a bit and upgrade APIs
...
llvm-svn: 93309
2010-01-13 08:04:24 +00:00
Chris Lattner
29a0ff2e70
add a fixme, ELF MCSection isn't quite right and weak unnamed globals are broken
...
on linux (even though they are pointless, they shouldn't ICE).
llvm-svn: 93308
2010-01-13 08:02:14 +00:00