Commit Graph

119973 Commits

Author SHA1 Message Date
Howard Hinnant b1ca881191 Oops, forgot to svn add the new test.
llvm-svn: 148047
2012-01-12 21:08:25 +00:00
Howard Hinnant b7d59ec6e1 Put debug print statments under a flag so that I can get a first glimpse at performance. So far I haven't noticed any performance difference between this new __dynamic_cast and gcc's implementation. But I've barely started looking. Also adding a couple of tests which come straight out of the standard.
llvm-svn: 148046
2012-01-12 21:06:12 +00:00
Rafael Espindola 9479c1b42a Add a SONAME to the libclang library.
Patch by Sylvestre Ledru.

llvm-svn: 148045
2012-01-12 21:04:54 +00:00
Elena Demikhovsky 060f6ccdb8 Fixed a bug in LowerVECTOR_SHUFFLE caused assertion failure
lc: X86ISelLowering.cpp:6480: llvm::SDValue llvm::X86TargetLowering::LowerVECTOR_SHUFFLE(llvm::SDValue, llvm::SelectionDAG&) const: Assertion `V1.getOpcode() != ISD::UNDEF&&  "Op 1 of shuffle should not be undef"' failed.
Added a test.

llvm-svn: 148044
2012-01-12 20:33:10 +00:00
Evan Cheng 5c03a6b8f5 When hoisting common code, watch out for uses which are marked "kill". If the
killed registers are needed below the insertion point, then unset the kill
marker.

Sorry I'm not able to find a reduced test case.

rdar://10660944

llvm-svn: 148043
2012-01-12 20:31:24 +00:00
Rafael Espindola 9a167eeaff Add error-reporting tests for platforms that don't support segmented stacks.
Patch by Brian Anderson.

llvm-svn: 148042
2012-01-12 20:26:13 +00:00
Rafael Espindola 00e861ed57 Support segmented stacks on 64-bit FreeBSD.
This patch uses tcb_spare field in the tcb structure to store info.
Patch by Jyun-Yan You.

llvm-svn: 148041
2012-01-12 20:24:30 +00:00
Rafael Espindola 10745d3381 Support segmented stacks on win32.
Uses the pvArbitrary slot of the TIB, which is reserved for applications. We
only support frames with a static size.

llvm-svn: 148040
2012-01-12 20:22:08 +00:00
Devang Patel b04a09a515 Remove test case, as Chris suggested.
llvm-svn: 148039
2012-01-12 19:54:02 +00:00
Howard Hinnant af07bfdb67 Fixed a couple of bugs, updated many comments, and am including a comprehensive test for when there are only 3 types in place. I need to do something similar for 4 and maybe more types, but I'm not sure how comprehensive I can make the test at 4 and above types.
llvm-svn: 148038
2012-01-12 19:48:14 +00:00
Kaelyn Uhrain b02c5e9356 Convert SemaInit.cpp to pass a callback object to CorrectTypo.
And once again improve the typo correction results in certain
situations just by moving the existing checks on the correction.

llvm-svn: 148037
2012-01-12 19:27:05 +00:00
Ted Kremenek 3d3aea9374 [analyzer] fix inlining's handling of mapping actual to formal arguments and limit the call stack depth. The analyzer can now accurately simulate factorial for limited depths.
llvm-svn: 148036
2012-01-12 19:25:46 +00:00
Richard Smith 9eae723c18 constexpr: initialization of a union from an empty initializer-list should
zero-initialize the first union member. Also fix a bug where initializing an
array of types compatible with wchar_t from a wide string literal failed in C,
and fortify the C++ tests in this area. This part can't be tested without a code
change to enable array evaluation in C (where an existing test fails).

llvm-svn: 148035
2012-01-12 18:54:33 +00:00
Devang Patel 0014e38a8b Add test case to check intel syntax parsing.
llvm-svn: 148034
2012-01-12 18:40:46 +00:00
Evan Cheng 09cc429cb1 Allow targets to select source order pre-RA scheduler.
llvm-svn: 148033
2012-01-12 18:27:52 +00:00
Devang Patel 4a6e778aae Rename X86ATTAsmParser -> X86AsmParser
We are using one parser to parse att as well as intel style syntax.

llvm-svn: 148032
2012-01-12 18:03:40 +00:00
Jakob Stoklund Olesen 994fed689f Make SplitAnalysis::UseSlots private.
llvm-svn: 148031
2012-01-12 17:53:44 +00:00
Benjamin Kramer 9ece950ddb After Jakob's r147938 exception handling on i386 was completely broken.
Restore the (obviously wrong) behavior from before r147938 without relying on
undefined behavior. Add a fat FIXME note.

This should fix nightly tester failures.

llvm-svn: 148030
2012-01-12 17:37:18 +00:00
Hans Wennborg 6073e31baa scanf: parse the 'm' length modifier, and check that the right arguments
are used with that and the 'a' length modifier.

llvm-svn: 148029
2012-01-12 17:11:12 +00:00
Douglas Gregor bf3a826f2c In Objective-C++, actually compute the base type of a member access
expression for an Objective-C object or pointer type, so that we don't
attempt to treat the member name as a template. Fixes
<rdar://problem/10672501>.

llvm-svn: 148028
2012-01-12 16:11:24 +00:00
Nadav Rotem 0a0a829bea Fix a bug in the AVX 256-bit shuffle code in cases where the splat element is on the boundary of two 128-bit vectors.
The attached testcase was stuck in an endless loop.

llvm-svn: 148027
2012-01-12 15:31:55 +00:00
Hans Wennborg fd950878fa scanf analysis: the 'a' length modifier is valid with a scanlist
Before r148025 we (accidentally) didn't check whether a length modifier is
appropriate for a scanlist, but now we do.

llvm-svn: 148026
2012-01-12 15:07:16 +00:00
Hans Wennborg 32f115f9c1 scanf analysis: don't bail out after successful parse of scanlist
llvm-svn: 148025
2012-01-12 14:44:54 +00:00
Benjamin Kramer 5b3aa60b44 X86: Generalize the x << (y & const) optimization to also catch masks with more set bits set than 31 or 63.
llvm-svn: 148024
2012-01-12 12:41:34 +00:00
NAKAMURA Takumi 5a5bb93004 test/Driver/debug-options*.c: Tweak r147819 to split out another cc1as-sensitive test. gcc driver is invoked for assembling on cygming.
llvm-svn: 148022
2012-01-12 06:15:01 +00:00
Richard Smith 173b94c9ac Revert accidentally-committed file in r148020.
llvm-svn: 148021
2012-01-12 06:10:09 +00:00
Richard Smith 02ab9c2940 Allow constant-folding of references which were formed in a manner not permitted
in a constant expression, for compatibility with g++.

llvm-svn: 148020
2012-01-12 06:08:57 +00:00
Greg Clayton 4d4c988c6a Bumped Xcode project versions for lldb-104 and debugserver-163.
llvm-svn: 148018
2012-01-12 05:29:50 +00:00
Greg Clayton 44435ed07a Big change in the way ObjectFile file contents are managed. We now
mmap() the entire object file contents into memory with MAP_PRIVATE.
We do this because object file contents can change on us and currently
this helps alleviate this situation. It also make the code for accessing
object file data much easier to manage and we don't end up opening the
file, reading some data and closing the file over and over.

llvm-svn: 148017
2012-01-12 05:25:17 +00:00
Greg Clayton c7f03b6155 <rdar://problem/10681814>
Fix DWARF parsing issue we can run into when using llvm-gcc based dSYM files.

Also fix the parsing of objective C built-in types (Class, id and SEL) so
they don't parse more information that is not needed due to the way they
are represented in DWARF.

llvm-svn: 148016
2012-01-12 04:33:28 +00:00
Evan Cheng e195f0db8b Move Sched::Preference out of TargetMachine.h where it is not referenced.
llvm-svn: 148014
2012-01-12 02:35:23 +00:00
Argyrios Kyrtzidis a80f1bf262 Add IsImplicit field in ObjCMessageExpr that is true when the message
was constructed, e.g. for a property access.

This allows the selector identifier locations machinery for ObjCMessageExpr
to function correctly, in that there are not real locations to handle/report for
such a message.

llvm-svn: 148013
2012-01-12 02:34:39 +00:00
Argyrios Kyrtzidis 7e79129d15 [arcmt] The migrator tests for the buildbot in http://lab.llvm.org:8011/builders/clang-native-mingw32-win7/
are messed up, XFAIL does not help. Waiting until DISABLE is supported..

llvm-svn: 148012
2012-01-12 02:34:32 +00:00
Anna Zaks 95f332112f [analyzer] Rename Store::Retrieve() -> getBinding().
+ all the other Retrieve..() methods + a comment for ElementRegion.

llvm-svn: 148011
2012-01-12 02:22:40 +00:00
Anna Zaks b3fa8d7dd1 [analyzer] Add taint transfer by strcpy & others (part 1).
To simplify the process:
Refactor taint generation checker to simplify passing the
information on which arguments need to be tainted from pre to post
visit.

Todo: We need to factor out the code that sema is using to identify the
string and memcpy functions and use it here and in the CString checker.

llvm-svn: 148010
2012-01-12 02:22:34 +00:00
Devang Patel fc6be102ae Add predicate method check match memory operand size, if available.
In att style asm syntax memory operand size is derived from suffix attached with mnemonic.  In intel style asm syntax it is part of memory operand hence predicate method check is required to select appropriate instruction.

llvm-svn: 148006
2012-01-12 01:51:42 +00:00
Jim Ingham c07fe69850 Don't dereference the oso_dwarf without checking for NULL.
llvm-svn: 148005
2012-01-12 01:45:53 +00:00
Bill Wendling 58c7569854 A DenseMap of a std::map isn't a very good idea because the "grow()" method will
need to make a deep copy of each of the std::maps. Use a std::map of the
std::map instead. This improves the compile time of sqlite3 by ~2%.

llvm-svn: 148003
2012-01-12 01:41:03 +00:00
Devang Patel 46831de240 Add intel style operand parser skeleton.
This is a work in progress.

llvm-svn: 148002
2012-01-12 01:36:43 +00:00
Chandler Carruth eb21da060b Switch all of the uses of my InsertDAGNode helper to follow the exact
same pattern. We already had this pattern is a few places, but others
tried to make a rough approximation of an actual DAG structure. As not
everywhere went to this trouble, nothing could rely on this being done.
In fact, I've checked all references to these node Ids, and the ones
that are using the topo-sort properties are actually satisfied with
a strict-weak-ordering. The requirement appears to be that Use >= Def.

I've added a big blurb of comments to this bit of the transform to
clarify why the order is so important for the next reader of the code.

I'm starting with this change as it is very small, and trivially
reverted if something breaks or the >= above really does need to be >.
If that proves the case, we can hide the problem by reverting this
patch, but the problem exists elsewhere as well, and so a more
comprehensive solution will be needed.

llvm-svn: 148001
2012-01-12 01:34:44 +00:00
Akira Hatanaka acf9896ca1 Fix test case committed in r147986.
llvm-svn: 147993
2012-01-12 01:27:24 +00:00
Eric Christopher 8c363622d3 Formatting.
llvm-svn: 147989
2012-01-12 01:26:58 +00:00
Eric Christopher ffbc4d0b68 Formatting.
llvm-svn: 147988
2012-01-12 01:26:51 +00:00
Greg Clayton fa8c004aba Revert some changes I did for logging that affected the ability to
load .o files in BSD archive parsing.

llvm-svn: 147987
2012-01-12 01:21:31 +00:00
Akira Hatanaka 32604a9708 Take into account the pointer to an aggregate that is passed as a hidden
argument when Offset is initialized.

llvm-svn: 147986
2012-01-12 01:10:09 +00:00
Akira Hatanaka 02e13e5005 Call CodeGenTypes::ConvertType to get LLVM::Type*.
Remove function MipsABIInfo::GetFloatingPointTy.

llvm-svn: 147985
2012-01-12 00:52:17 +00:00
Eli Friedman 42b199c699 Fix some edge cases with C++ casts and placeholder expressions.
llvm-svn: 147984
2012-01-12 00:44:34 +00:00
Johnny Chen 5886fb5bd3 rdar://problem/10492827
SBProcess.GetSTDERR() not getting stderr of the launched process

Since we are launch the inferior with:

    process = target.LaunchSimple(None, None, os.getcwd())

i.e., without specifying stdin/out/err.  A pseudo terminal is used for
handling the process I/O, and we are satisfied once the expected output
appears in process.GetSTDOUT().

llvm-svn: 147983
2012-01-12 00:29:46 +00:00
Fariborz Jahanian 4f8cb1e83a objective-c: fixes a regression in looking up names
in class extensions and categories by recent refactoring
of objc class ASTs. // rdar://1066654

llvm-svn: 147982
2012-01-12 00:18:35 +00:00
Howard Hinnant f88480363e Initial implementaiton of __dynamic_cast. There is still lots of debugging code in here that needs to be stripped out. And many, many unit tests need to be written. And comments and probably code cleanliness needs to be improved. But I *think* the basic algorithm is sound. There also may still be some oportunities for algorithm optimization, I'm not positive.
llvm-svn: 147981
2012-01-11 23:49:18 +00:00