Commit Graph

89713 Commits

Author SHA1 Message Date
Chris Lattner 58bd73a5a7 Add a new llvm.x86.int intrinsic, allowing access to the
x86 int and int3 instructions.  Patch by Peter Housel!

llvm-svn: 111831
2010-08-23 19:39:25 +00:00
Douglas Gregor 2529b55b4d Don't include macro results when we're completing a declarator.
llvm-svn: 111830
2010-08-23 19:33:40 +00:00
Mikhail Glushenkov 1a90528e63 llvmc: Allow multiple LanguageMaps.
llvm-svn: 111829
2010-08-23 19:24:16 +00:00
Mikhail Glushenkov c6c79ddcb9 Add a TODO.
llvm-svn: 111828
2010-08-23 19:24:12 +00:00
Mikhail Glushenkov bf38e0749d llvmc: Properly handle (error) in edge properties.
llvm-svn: 111827
2010-08-23 19:24:08 +00:00
Mikhail Glushenkov 0e6cfd7491 llvmc: Do not mention plugins in the code.
llvm-svn: 111826
2010-08-23 19:24:00 +00:00
Mikhail Glushenkov 59129fd9ef Trailing whitespace.
llvm-svn: 111825
2010-08-23 19:23:54 +00:00
Benjamin Kramer 40f83489b4 Add the symbol offset to the relocation value when we relocate against section. By Roman Divacky.
llvm-svn: 111824
2010-08-23 19:05:46 +00:00
Fariborz Jahanian bf9294fb65 Support for IRGen of synthesize bitfield ivars in
objc-nonfragile-abi2 (radar 7824380).

llvm-svn: 111823
2010-08-23 18:51:39 +00:00
Dan Gohman 99e9d6ffbf formatted_tool_output_file::close needs to flush its buffer before
closing the underlying stream.

llvm-svn: 111822
2010-08-23 18:43:24 +00:00
Devang Patel df96c75731 test case for PR7920.
llvm-svn: 111821
2010-08-23 18:26:10 +00:00
Devang Patel a8652674e0 Handle qualified constants that are directly folded by FE.
PR 7920.

llvm-svn: 111820
2010-08-23 18:25:56 +00:00
Benjamin Kramer 620b68e883 Use the proper relocation section + cleanup, from Roman Divacky.
llvm-svn: 111819
2010-08-23 18:24:20 +00:00
Douglas Gregor c49f5b2f11 Introduce a new code-completion point when we're parsing a
declarator. Here, we can only see a few things (e.g., cvr-qualifiers,
nested name specifiers) and we do not want to provide other non-macro
completions. Previously, we would end up in recovery mode and would
provide a large number of non-relevant completions.

llvm-svn: 111818
2010-08-23 18:23:48 +00:00
Benjamin Kramer 08fd2cf26a Avoid O(n*m) complexity in StringRef::find_first(_not)_of(StringRef).
- Cache used characters in a bitset to reduce memory overhead to just 32 bytes.
- On my core2 this code is faster except when the checked string was very short
  (smaller than the list of delimiters).

llvm-svn: 111817
2010-08-23 18:16:08 +00:00
Owen Anderson 630add39a6 Re-enable LazyValueInfo. Monitoring for failures.
llvm-svn: 111816
2010-08-23 18:12:23 +00:00
Owen Anderson d31d82d75c Now that PassInfo and Pass::ID have been separated, move the rest of the passes over to the new registration API.
llvm-svn: 111815
2010-08-23 17:52:01 +00:00
Benjamin Kramer 0bf9c59d2f StringRef tweaks:
- Respect find_first_of(char's From parameter instead of silently dropping it.
- Prefer std::string() to std::string("")

llvm-svn: 111814
2010-08-23 17:44:13 +00:00
Chris Lattner a42202e0e4 random improvement for variable shift codegen.
llvm-svn: 111813
2010-08-23 17:30:29 +00:00
Johnny Chen a73af6f698 Fixed a crasher where during shutdown, loggings attempted to access the
thread name but the static map instance had already been destructed.

rdar://problem/8153284

llvm-svn: 111812
2010-08-23 17:13:12 +00:00
Johnny Chen d0190a6182 Changed the keyword argument for runCmd()/expect() from 'verbose' to 'trace',
which, defaults to False, and if set to True, will trace lldb command execution
and result.

Added "-t" command option to the test driver dotest.py which sets the
LLDB_COMMAND_TRACE environment variable to "YES" and as a result always turns on
command tracing regardless of the 'trace' keyword argument to runCmd()/expect().

llvm-svn: 111811
2010-08-23 17:10:44 +00:00
Douglas Gregor f63e4c3334 Emit an error noting that Clang does not support code generation for
the ternary operator without a left-hand side in C++ (PR7726), from
Jean-Daniel Dupas!

llvm-svn: 111809
2010-08-23 14:50:27 +00:00
Douglas Gregor 6181a75d49 Add XML for CXXConstructExpr, from Benoit Belley!
llvm-svn: 111808
2010-08-23 14:44:46 +00:00
Douglas Gregor a05f5aba9a When complaining about a duplicate declspec, provide a Fix-It that
removes the copy. Patch from Eelis van der Weegen, tweaked/updated by
me.

llvm-svn: 111807
2010-08-23 14:34:43 +00:00
Douglas Gregor 34a462538e Clarify documentation of escaping for backslash
llvm-svn: 111806
2010-08-23 14:03:03 +00:00
Chandler Carruth ebf42ac831 Try to escape the '$'s in these so they reach the underlying 'sh' invocation.
I have no idea how lit did the right thing here, but other test runners don't.

llvm-svn: 111805
2010-08-23 08:54:19 +00:00
Chandler Carruth 76c0cb493f Add a virtual destructor to the base of another class hierarchy with virtual
methods.

llvm-svn: 111804
2010-08-23 08:37:21 +00:00
Chandler Carruth 191c4f73b2 Fix some GCC warnings by providing a virtual destructor in the base of a class
hierarchy with virtual methods and using llvm_unreachable to properly indicate
unreachable states which would otherwise leave variables uninitialized.

llvm-svn: 111803
2010-08-23 08:25:07 +00:00
Chandler Carruth c926240172 Relax the construction of a definition for implicit, trivial default
constructors. We perform semantic checking when creating the definition, and
this isn't needed in certain contexts (value initialization) but is in others
(default initialization). This fixes PR7948.

We add explicit code to the default initialization path to ensure the
definition is both present and valid.

Doug, please review. I think this follows your latest suggestion, and it ended
up remarkably cleaner than I anticipated. Also let me know if similar logic
should be followed for destructors and copy-constructors.

llvm-svn: 111802
2010-08-23 07:55:51 +00:00
Anton Korobeynikov cbbe4501df Revert invalid r111792. Jump tables are not broken on x86-64 / coff,
it's COFF emitter which does not support differences of two symbols
(and needs to be fixed). GAS is pretty fine with code produced.

llvm-svn: 111801
2010-08-23 07:38:51 +00:00
John McCall 3e56fd4d22 Push DeclGroupRefs and TemplateNames in an opaque but type-safe way
through the parser.

llvm-svn: 111800
2010-08-23 07:28:44 +00:00
Argyrios Kyrtzidis 421ad5e1e6 In Sema::AddBuiltinOperatorCandidates, candidate pointer types set can also contain a ObjCObjectPointerType since r111699.
Don't assume that they are only PointerTypes or we will crash.

llvm-svn: 111798
2010-08-23 07:12:16 +00:00
John McCall 61a148881f chandlerc pointed out that ending a line with /\ is not very friendly. :)
llvm-svn: 111797
2010-08-23 06:56:36 +00:00
John McCall 572ccbc2c2 Kill off Parser::TemplateParameterList to avoid misparses.
llvm-svn: 111796
2010-08-23 06:53:58 +00:00
John McCall 37ad551a25 Sundry incremental steps towards killing off Action.
llvm-svn: 111795
2010-08-23 06:44:23 +00:00
Chris Lattner 65526f0190 fix rdar://8340348, a miscompile of boost that was exposed by r109848.
That revision started classifying truly empty structs like "Y" and "X"
as being NoClass/NoClass and turning them into 'ignore'.  The call code
turns around and allocates space for the ignored argument with 
GetUndefRValue.  The bug is that GetUndefRValue would return the address
as undef, instead of returning an object with a defined address but 
undefined contents.

llvm-svn: 111794
2010-08-23 05:26:13 +00:00
Michael J. Spencer db06215b7f Revert part of my last commit. the mingw32 build bot doesn't seem to like it.
llvm-svn: 111793
2010-08-23 05:25:23 +00:00
Michael J. Spencer e87231232a Workaround broken jump tables on x86-64 COFF.
llvm-svn: 111792
2010-08-23 04:45:37 +00:00
Chris Lattner c3847a8134 remove some dead code.
llvm-svn: 111791
2010-08-23 03:12:06 +00:00
Zhongxing Xu fee32dc783 Adjust code placement.
llvm-svn: 111790
2010-08-23 01:37:32 +00:00
John McCall 7a9aac2d9f Abstract out everything having to do with member pointers into the ABI
class;  they should just be completely opaque throughout IR gen now,
although I haven't really audited that.

Fix a bug apparently inherited from gcc-4.2 where we failed to null-check
member data pointers when performing derived-to-base or base-to-derived
conversions on them.

llvm-svn: 111789
2010-08-23 01:21:21 +00:00
John McCall aa4149a2aa Extract a method to check whether a function is the global placement
operator new[].

llvm-svn: 111788
2010-08-23 01:17:59 +00:00
Nick Lewycky c72d2853e1 Verify the predicates on icmp/fcmp. Suggested by Jeff Yasskin!
llvm-svn: 111787
2010-08-22 23:45:14 +00:00
John McCall 614dbdcd55 Go back to asking CodeGenTypes whether a type is zero-initializable.
Make CGT defer to the ABI on all member pointer types.
This requires giving CGT a handle to the ABI.
It's way easier to make that work if we avoid lazily creating the ABI.
Make it so.

llvm-svn: 111786
2010-08-22 21:01:12 +00:00
Nick Lewycky 0b84914da0 Add x86intrin.h which is generic x86 intrinsics for more than just Intel. Thus
far, this just #include's immintrin.h for compatibility.

llvm-svn: 111785
2010-08-22 20:38:05 +00:00
Douglas Gregor ec3a3f5257 Do not elide copy construction when we're performing base-class initialization
llvm-svn: 111783
2010-08-22 18:27:02 +00:00
Douglas Gregor 932c19dc9f Eliminate a stale assertion. Fixes Clang self-host.
llvm-svn: 111782
2010-08-22 18:26:35 +00:00
Douglas Gregor b0a04fff51 Preserve the zero-initialization and construction-kind settings when
instantiating CXXConstructExpr expressions.

llvm-svn: 111780
2010-08-22 17:20:18 +00:00
Douglas Gregor 630c76efb0 When performing value-initialization for a class with a non-trivial,
implicitly-defined default constructor, zero-initialize the memory
before calling the default constructor. Previously, we would only
zero-initialize in the case of a trivial default constructor.

Also, simplify the hideous logic that determines when we have a
trivial default constructor and, therefore, don't need to emit any
call at all.

llvm-svn: 111779
2010-08-22 16:15:35 +00:00
Howard Hinnant fae824a32d Remove tabs
llvm-svn: 111778
2010-08-22 13:53:14 +00:00