Commit Graph

134675 Commits

Author SHA1 Message Date
Eric Christopher b45bcc6d72 Allow alternate instructions to silence bot.
llvm-svn: 165055
2012-10-02 21:44:16 +00:00
Eric Christopher a55b1d5b99 80-col.
llvm-svn: 165054
2012-10-02 21:44:12 +00:00
Andrew Kaylor adc70568f9 Clean-up of memory buffer and object ownership model in MCJIT
llvm-svn: 165053
2012-10-02 21:18:39 +00:00
Eric Christopher f01b02b7cf Don't use a debug location for frame setup instructions in the
prologue. Also skip frame setup instructions when looking for the
first location.

llvm-svn: 165052
2012-10-02 21:17:00 +00:00
Eric Christopher 4ec766facf Use the existing DebugLoc.
llvm-svn: 165051
2012-10-02 21:16:55 +00:00
Eric Christopher 657a42daf1 Make the location a parameter since we may not want the next one
in the block.

llvm-svn: 165050
2012-10-02 21:16:53 +00:00
Eric Christopher d40ce7a43d Remove the SavePoint infrastructure from fast isel, replace
with just an insert point from the MachineBasicBlock and let
the location be updated as we access it.

llvm-svn: 165049
2012-10-02 21:16:50 +00:00
Hemant Kulkarni cc613e1c25 Changed test output comparison to be consistent with the way llvm-objdump and llvm-readobj work.
llvm-svn: 165048
2012-10-02 21:12:21 +00:00
Argyrios Kyrtzidis 4db774a8ef [PCH/Module] Change the map of file-level DeclIDs to use a FileID
as key instead of a SLocEntry pointer. This allows the array of
file sorted declarations in a PCH/module to be deterministic.

llvm-svn: 165047
2012-10-02 21:09:17 +00:00
Argyrios Kyrtzidis 10e7846abf [libclang] When indexing an AST file, only deserialize the file level
declarations of the current primary module.

llvm-svn: 165046
2012-10-02 21:09:13 +00:00
Chad Rosier 7768299b98 [ms-inline asm] Fixup test case to be valid ms-style asm. Fix whitespace.
llvm-svn: 165045
2012-10-02 20:55:30 +00:00
Ted Kremenek 4924a0161b Refactor clients of AnalyzerOptions::getBooleanOption() to have
an intermediate helper method to query and populate the Optional value.

llvm-svn: 165043
2012-10-02 20:42:16 +00:00
Bill Wendling 24c20ec63a Set the 'build clang only' flag when we're building only clang.
llvm-svn: 165042
2012-10-02 20:32:23 +00:00
Ted Kremenek 3c6932922e Tweak AnalyzerOptions::getOptionAsInteger() to populate the string
table, making it printable with the ConfigDump checker.  Along the
way, fix a really serious bug where the value was getting parsed
from the string in code that was in an assert() call.  This means
in a Release-Asserts build this code wouldn't work as expected.

llvm-svn: 165041
2012-10-02 20:31:56 +00:00
Ted Kremenek 5faa5e04a3 Change AnalyzerOptions::mayInlineCXXMemberFunction to default populate
the config string table.  Also setup a test for dumping the analyzer
configuration for C++.

llvm-svn: 165040
2012-10-02 20:31:52 +00:00
Fariborz Jahanian de0ae1e406 [Doc parsing]: Add available and deprecated attribute info
to XML output. // rdar://12378879

llvm-svn: 165039
2012-10-02 20:05:47 +00:00
Nick Kledzik 35c79da3f8 Improve overflow detection in StringRef::getAsUnsignedInteger().
llvm-svn: 165038
2012-10-02 20:01:48 +00:00
Tobias Grosser 8a5bc6edca Add a new isl based code generation
This pass implements a new code generator that uses the code generation
algorithm included in isl.

For the moment the new code generation is limited to sequential code.

llvm-svn: 165037
2012-10-02 19:50:43 +00:00
Tobias Grosser 0934e70e6e Add an ast pretty printer pass based on the isl code generator
llvm-svn: 165036
2012-10-02 19:50:38 +00:00
Tobias Grosser 50fce4f8de Update isl to get the new code generation
llvm-svn: 165035
2012-10-02 19:50:30 +00:00
Tobias Grosser c845fef391 Detect the isl code generation feature correctly
llvm-svn: 165034
2012-10-02 19:50:22 +00:00
Howard Hinnant 6e551ae1a3 Make vector::iterator and string::iterator more resilient against overly generic relational operators.
llvm-svn: 165033
2012-10-02 19:45:42 +00:00
Chandler Carruth 6c3890b680 Fix another crasher in SROA, reported by Joel.
We require that the indices into the use lists are stable in order to
build fast lookup tables to locate a particular partition use from an
operand of a PHI or select. This is (obviously in hind sight)
incompatible with erasing elements from the array. Really, we don't want
to erase anyways. It is expensive, and a rare operation. Instead, simply
weaken the contract of the PartitionUse structure to allow null Use
pointers to represent dead uses. Now we can clear out the pointer to
mark things as dead, and all it requires is adding some 'continue'
checks to the various loops.

I'm still reducing a test case for this, as the test case I have is
huge. I think this one I can get a nice test case for though, as it was
much more deterministic.

llvm-svn: 165032
2012-10-02 18:57:13 +00:00
Chad Rosier 04d5664295 [ms-inline asm] Enhance the isSimpleMSAsm() function to handle operands with pointer size
directives (e.g., dword ptr [eax]).

llvm-svn: 165031
2012-10-02 18:51:05 +00:00
Andrew Kaylor feb805fcf2 Support for generating ELF objects on Windows.
This adds 'elf' as a recognized target triple environment value and overrides the default generated object format on Windows platforms if that value is present.  This patch also enables MCJIT tests on Windows using the new environment value.

llvm-svn: 165030
2012-10-02 18:38:34 +00:00
Bill Wendling 5e5cf1a50c Fix test for r165028. It only generates that flag for source files now.
<rdar://problem/12401423>

llvm-svn: 165029
2012-10-02 18:07:59 +00:00
Bill Wendling 3b2000fcac During LTO, we call 'dsymutil' when we compile source files. This necessitates
clang specifying a temporary file that it later cleans up so that it can survive
the linking stage. However, when we compile object files during LTO we don't
call 'dsymutil'. That's done at a different stage (if at all). We rely upon the
linker to specify a unique name for the temporary file it generates.
<rdar://problem/12401423>

llvm-svn: 165028
2012-10-02 18:02:50 +00:00
Chandler Carruth 3903e05244 Fix a silly coding error on my part. The whole point of the speculator
being separate was that it can grow the use list. As a consequence, we
can't use the iterator-pair interface, we need an index based interface.
Expose such an interface from the AllocaPartitioning, and use it in the
speculator.

This should at least fix a use-after-free bug found by Duncan, and may
fix some of the other crashers.

I don't have a nice deterministic test case yet, but if I get a good
one, I'll add it.

llvm-svn: 165027
2012-10-02 17:49:47 +00:00
Rafael Espindola ea0c5ecb28 Convert to FileCheck.
llvm-svn: 165026
2012-10-02 17:41:03 +00:00
Chad Rosier 0ede0986b9 No need to call the InitializeAll* functions.
llvm-svn: 165025
2012-10-02 16:41:12 +00:00
NAKAMURA Takumi 18fc445af5 FP_CONTRACT: Fix two tests for -Asserts.
llvm-svn: 165024
2012-10-02 16:36:54 +00:00
Argyrios Kyrtzidis d4fcf58070 [libclang] When indexing an AST file, only deserialize the preprocessing record
entities of the current primary module.

llvm-svn: 165023
2012-10-02 16:10:51 +00:00
Argyrios Kyrtzidis f590e094ad Add info in the preprocessing record whether an inclusion directive
resulted in an automatic module import.

llvm-svn: 165022
2012-10-02 16:10:46 +00:00
Argyrios Kyrtzidis b36ee5c592 [libclang] Even though we disable the preprocessing record during indexing,
make sure that it gets enabled for when a module needs to be created.

llvm-svn: 165021
2012-10-02 16:10:41 +00:00
Argyrios Kyrtzidis 472eda06b0 [libclang] Implement the importedASTFile indexing callback to provide
info about imported modules.

llvm-svn: 165020
2012-10-02 16:10:38 +00:00
Benjamin Kramer bc2724f6e0 Fix broken tests.
llvm-svn: 165019
2012-10-02 15:49:34 +00:00
Alexander Potapenko 77c0ac2336 Do not patch the instruction address when symbolizing the reports.
Instead, print the correct address at runtime.

llvm-svn: 165018
2012-10-02 15:42:24 +00:00
Duncan Sands f97cb15aee Fix PR13991: legalizing an overflowing multiplication operation is harder than
the add/sub case since in the case of multiplication you also have to check that
the operation in the larger type did not overflow.

llvm-svn: 165017
2012-10-02 15:03:49 +00:00
Aaron Ballman a99c35702d Splitting this test case into two because the behavior for the calling convention code is target-specific.
llvm-svn: 165016
2012-10-02 14:56:00 +00:00
Aaron Ballman e91c6be01e Allowing individual targets to determine whether a given calling convention is allowed or ignored with warning. This allows for correct name mangling for x64 targets on Windows, which in turn allows for linking against the Win32 APIs.
Fixes PR13782

llvm-svn: 165015
2012-10-02 14:26:08 +00:00
Alexey Samsonov 30c01f25f1 [Sanitizer] fix line width
llvm-svn: 165009
2012-10-02 14:09:20 +00:00
Alexey Samsonov 78c340d205 [ASan] Change __asan_set_on_error_callback to weak overridable __asan_on_error, so that ASan would call the latter even if it finds the error early (i.e. during module initialization)
llvm-svn: 165008
2012-10-02 14:06:39 +00:00
Aaron Ballman ac11a9b572 Silencing an MSVC warning about */ being found outside of a comment.
llvm-svn: 165007
2012-10-02 13:54:25 +00:00
Evgeniy Stepanov 49e8576a09 [*San]: handle EINTR.
llvm-svn: 165006
2012-10-02 13:41:40 +00:00
Axel Naumann 0439f03bcf Add redecls into their lexical DeclContext: this is what they assert on, and the merging should have set it correctly.
This is especially relevant for templatedDecls that might be injected (and thus have their DeclContext set to) somewhere completely different.

llvm-svn: 165005
2012-10-02 13:06:13 +00:00
Dmitry Vyukov 56faa551b9 tsan: fix mac build
llvm-svn: 165004
2012-10-02 12:58:14 +00:00
Alexey Samsonov 298e237d7e [ASan] Add extern C for __asan_symbolize on Windows
llvm-svn: 165003
2012-10-02 12:35:42 +00:00
Axel Naumann 2bd39fd2de Enable programmatic provisioning of virtual module.map files (instead of writing out actual module.map files).
Opens up the wonders of clang::Modules to tools - though they remain as experimental as before.

llvm-svn: 165002
2012-10-02 12:26:36 +00:00
Axel Naumann d9a25b3c17 Only those InterestingDecls that got added to the AST should be passed to the ASTConsumer.
llvm-svn: 165001
2012-10-02 12:18:46 +00:00
Alexey Samsonov e29c6731aa [Sanitizer/ASan] Simplify the code that prints and symbolizes stack traces. Fall back to module+offset if user-provided symbolizer failed. Use weak function __asan_symbolize instead of __asan_set_symbolize_callback in ASan interface, so that we're able to symbolize reports for errors that happen before the main() is called, for example, during module initialization.
llvm-svn: 165000
2012-10-02 12:11:17 +00:00