Douglas Gregor
e489a7d3d3
Warn about the deprecated string literal -> char* conversion. Fixes PR6428.
...
llvm-svn: 97404
2010-02-28 18:30:25 +00:00
Chris Lattner
fd48afe412
Implement PR6423 by using one token of lookahead to disambiguate
...
an *almost* always incorrect case. This only does the lookahead
in the insanely unlikely case, so it shouldn't impact performance.
On this testcase:
struct foo {
}
typedef int x;
Before:
t.c:3:9: error: cannot combine with previous 'struct' declaration specifier
typedef int x;
^
After:
t.c:2:2: error: expected ';' after struct
}
^
;
llvm-svn: 97403
2010-02-28 18:18:36 +00:00
Anders Carlsson
8b37bb7c48
When laying out vtables for virtual bases in construction vtables, we need to check if the vtable is a primary base in the layout class.
...
llvm-svn: 97402
2010-02-28 18:08:38 +00:00
Anders Carlsson
b15d8c57ad
Add another construction vtable test.
...
llvm-svn: 97401
2010-02-28 17:59:36 +00:00
John McCall
1629149103
Support constant-evaluation of __builtin_nans* as well as the correct constant
...
evaluation of __builtin_nan*. Most of the work to make this work is in LLVM.
Fixes <rdar://problem/7696712> and part of PR 5255.
llvm-svn: 97383
2010-02-28 13:00:19 +00:00
John McCall
c12b133d00
Properly clear all the extra bits in a significand when making a NaN from an
...
APInt. Be certain to set the integer bit in an x87 extended-precision
significand so that we don't accidentally make a pseudo-NaN.
llvm-svn: 97382
2010-02-28 12:49:50 +00:00
John McCall
512b650210
Add an override to StringRef::getAsInteger which parses into an APInt.
...
It gets its own implementation totally divorced from the (presumably
performance-sensitive) routines which parse into a uint64_t.
Add APInt::operator|=(uint64_t), which is situationally much better than
using a full APInt.
llvm-svn: 97381
2010-02-28 09:55:58 +00:00
Erick Tryzelaar
28db1a3e61
Add support for getting a null pointer.
...
llvm-svn: 97380
2010-02-28 09:46:27 +00:00
Erick Tryzelaar
272d62bc5a
Add a way to look up a type by it's name in a module.
...
llvm-svn: 97379
2010-02-28 09:46:21 +00:00
Erick Tryzelaar
6fdb7a6547
Add replace_all_uses_with to ocaml.
...
llvm-svn: 97378
2010-02-28 09:46:16 +00:00
Erick Tryzelaar
06894b3824
Add support for global variables in an address space for llvm-c and ocaml.
...
llvm-svn: 97377
2010-02-28 09:46:13 +00:00
Erick Tryzelaar
0fb26ef01f
Add indirect br support to llvm-c and ocaml.
...
llvm-svn: 97376
2010-02-28 09:46:06 +00:00
Erick Tryzelaar
d8531faf95
Add metadata functions to llvm-c and ocaml.
...
llvm-svn: 97375
2010-02-28 09:45:59 +00:00
Chris Lattner
56c50da3f6
remove redundant instruction.
...
llvm-svn: 97374
2010-02-28 07:23:21 +00:00
Zhongxing Xu
7ba9e99015
Use getBody() to get the function definition when the decl referenced is not
...
definition.
llvm-svn: 97373
2010-02-28 06:39:11 +00:00
Erick Tryzelaar
4c340c7f7f
Add the new builder arthmetic instructions to llvm-c and ocaml.
...
llvm-svn: 97372
2010-02-28 05:51:43 +00:00
Erick Tryzelaar
a8053dfd27
Add the new union arthmetic instructions to llvm-c and ocaml.
...
llvm-svn: 97371
2010-02-28 05:51:33 +00:00
Erick Tryzelaar
318317961c
Add generic binary op and cast builder functions.
...
llvm-svn: 97370
2010-02-28 05:51:27 +00:00
Erick Tryzelaar
eaaac73c1d
Rename ocaml vmcore tests to make it easier to insert tests.
...
llvm-svn: 97369
2010-02-28 05:51:21 +00:00
Erick Tryzelaar
5bfa919e66
Fix incorrect uses of an ocaml llbuilder without extracting it from ocaml.
...
llvm-svn: 97368
2010-02-28 05:51:16 +00:00
Erick Tryzelaar
4417431e0e
Remove malloc and free from the ocaml bindings.
...
llvm-svn: 97367
2010-02-28 05:51:09 +00:00
Bob Wilson
1136166ee9
Revert r97245 which seems to be causing performance problems.
...
llvm-svn: 97366
2010-02-28 05:34:05 +00:00
Ted Kremenek
9704635375
Fix typo.
...
llvm-svn: 97365
2010-02-28 05:14:08 +00:00
John McCall
dcb9a7ad3d
Teach APFloat how to create both QNaNs and SNaNs and with arbitrary-width
...
payloads. APFloat's internal folding routines always make QNaNs now,
instead of sometimes making QNaNs and sometimes SNaNs depending on the
type.
llvm-svn: 97364
2010-02-28 02:51:25 +00:00
Chris Lattner
abb1c7912e
enhance EmitNodeMatcher to keep track of the recorded slot numbers
...
it will populate.
llvm-svn: 97363
2010-02-28 02:41:25 +00:00
Chris Lattner
c3f80e0806
add infrastructure to support forming selectnodeto. Not used yet
...
because I have to go on another detour first.
llvm-svn: 97362
2010-02-28 02:31:26 +00:00
Anders Carlsson
e3385f566b
More improvements to construction vtables; we know handle vbase offsets correctly (I hope).
...
llvm-svn: 97361
2010-02-28 01:43:58 +00:00
Dan Gohman
34021b7445
Don't try to replace physical registers when doing CSE.
...
llvm-svn: 97360
2010-02-28 01:33:43 +00:00
Dan Gohman
357421ea12
Opt into the Verifier now that it's an opt-in feature of
...
addPassesToEmitFile.
llvm-svn: 97358
2010-02-28 00:55:40 +00:00
Dan Gohman
0d8a9af7b8
Add a flag to addPassesToEmit* to disable the Verifier pass run
...
after LSR, so that clients can opt in.
llvm-svn: 97357
2010-02-28 00:41:59 +00:00
Anders Carlsson
62c6c72bab
Pass information about whether a base is virtual or not down to getCtorVtable, we need this information in the vtable builder.
...
llvm-svn: 97356
2010-02-28 00:36:23 +00:00
Chris Lattner
99e53b3b33
Generalize my hack to use SDNodeInfo to find out when a
...
node is always guaranteed to have a particular type
instead of hacking in ISD::STORE explicitly. This allows
us to use implied types for a broad range of nodes, even
target specific ones.
llvm-svn: 97355
2010-02-28 00:22:30 +00:00
Dan Gohman
bdd6405f29
Implement XMM subregs.
...
Extracting the low element of a vector is now done with EXTRACT_SUBREG,
and the zero-extension performed by load movss is now modeled with
SUBREG_TO_REG, and so on.
Register-to-register movss and movsd are no longer considered copies;
they are two-address instructions which insert a scalar into a vector.
llvm-svn: 97354
2010-02-28 00:17:42 +00:00
Anders Carlsson
31f595f5ef
Add new function.
...
llvm-svn: 97353
2010-02-28 00:10:58 +00:00
Dan Gohman
6fb6a59766
Don't unconditionally suppress hoisting of instructions with implicit
...
defs or uses. The regular def and use checking below covers them, and
can be more precise. It's safe to hoist an instruction with a dead
implicit def if the register isn't live into the loop header.
llvm-svn: 97352
2010-02-28 00:08:44 +00:00
Anders Carlsson
f98b47d3b9
Fix to dumpLayout; we want to be able to dump address points even if the vtable doesn't have any methods.
...
llvm-svn: 97350
2010-02-27 23:58:01 +00:00
Dan Gohman
45e7ffc350
Add nounwinds.
...
llvm-svn: 97349
2010-02-27 23:53:53 +00:00
Dan Gohman
8c5d683aa9
The mayHaveSideEffects flag is no longer used.
...
llvm-svn: 97348
2010-02-27 23:47:46 +00:00
Nick Lewycky
48f74d2c9a
Debian sid moved these headers into /4.4 and left /4.4.3 as a symlink. Update.
...
Also, add support for 32-bit x86 Debian sid.
llvm-svn: 97347
2010-02-27 22:35:43 +00:00
Chris Lattner
278606b06e
change CheckOpcodeMatcher to hold the SDNodeInfo instead of
...
the opcode name. This gives the optimizer more semantic info.
llvm-svn: 97346
2010-02-27 21:48:43 +00:00
Chris Lattner
f159afc951
remove a bogus pattern, which had the same pattern as STDU
...
but codegen'd differently. This really wanted to use some
sort of subreg to get the low 4 bytes of the G8RC register
or something. However, it's invalid and nothing is testing
it, so I'm just zapping the bogosity.
llvm-svn: 97345
2010-02-27 21:15:32 +00:00
Anders Carlsson
c3f92a16f2
Add a simple construction vtable test.
...
llvm-svn: 97344
2010-02-27 21:09:00 +00:00
Anders Carlsson
9391375d95
Start fleshing out construction vtable support.
...
llvm-svn: 97342
2010-02-27 20:39:05 +00:00
Anders Carlsson
603d7d1910
Enable the new vtable layout code for vtables that aren't construction vtables. (This doesn't mean that we emit LLVM IR using it yet, it just means that it's running and hopefully not crashing or asserting).
...
llvm-svn: 97341
2010-02-27 20:02:53 +00:00
Anders Carlsson
9f19aaaa3a
Move ComputeThisAdjustmentBaseOffset to VtableBuilder.
...
llvm-svn: 97340
2010-02-27 19:57:44 +00:00
Anders Carlsson
b26c2abac7
Make sure to insert the primary base in the set :)
...
llvm-svn: 97339
2010-02-27 19:51:04 +00:00
Anders Carlsson
e02a926a1c
Use the real base offset when calculating vbase offsets.
...
llvm-svn: 97338
2010-02-27 19:21:58 +00:00
Anders Carlsson
4d0729a7cc
Figured out why the test was failing, this will hopefully fix it.
...
llvm-svn: 97336
2010-02-27 19:00:53 +00:00
Anders Carlsson
2b381bbb5c
Don't add this adjustments for pure virtual member functions.
...
llvm-svn: 97334
2010-02-27 18:16:50 +00:00
Anders Carlsson
01d3c7da60
We want to store method info for unused functions.
...
llvm-svn: 97333
2010-02-27 18:09:40 +00:00