Commit Graph

49685 Commits

Author SHA1 Message Date
Anton Korobeynikov 09991ada2d StoreInst does not produce any result thus it's useless to create new
variable for it. This greatly reduces amount of unused variables in
llvm2cpp-generated code

llvm-svn: 58905
2008-11-08 12:58:07 +00:00
Argyrios Kyrtzidis 0d9ee2eb2e Revert r58880, it breaks test/SemaCXX/constructor.cpp
llvm-svn: 58904
2008-11-08 12:02:25 +00:00
Argyrios Kyrtzidis 13042a4a4a Use only one constructor for CXXMethodDecl. Keep initialization stuff into one place.
llvm-svn: 58902
2008-11-08 11:24:06 +00:00
Anton Korobeynikov 9278247502 Properly escape dashes in TableGen's LLVMC2 emitter.
Patch by Patrick Walton!

llvm-svn: 58901
2008-11-08 10:16:21 +00:00
Eric Christopher 6e670388c0 Fix syntax of iterate_complex example. Noticed by Martin!
llvm-svn: 58900
2008-11-08 08:20:49 +00:00
Evan Cheng 436bdcdcca Moved InvalidateInstructionCache to ARMJITInfo::emitFunctionStub which knows size of stub.
llvm-svn: 58899
2008-11-08 08:16:49 +00:00
Evan Cheng 686a725b45 Remove a InvalidateInstructionCache call with incorrect size.
llvm-svn: 58898
2008-11-08 08:15:39 +00:00
Evan Cheng b31a717527 Rename startFunctionStub to startGVStub since it's also used for GV non-lazy ptr.
llvm-svn: 58897
2008-11-08 08:02:53 +00:00
Evan Cheng 98161f5f34 Tell ARMJITInfo if codegen relocation is PIC. It changes how function stubs are generated.
llvm-svn: 58896
2008-11-08 07:38:22 +00:00
Evan Cheng 1b889b16da Rename isString -> isExternalSymbol; getString -> getExternalSymbol since these work on externsym machine relocations.
llvm-svn: 58895
2008-11-08 07:37:34 +00:00
Evan Cheng 776f5922fb More debug output.
llvm-svn: 58894
2008-11-08 07:22:53 +00:00
Evan Cheng bb373c4637 Fix relocation for calls to external symbols.
llvm-svn: 58893
2008-11-08 07:22:33 +00:00
Daniel Dunbar 238475c8ca Avoid redundant cast<>s / simplify type dispatch.
llvm-svn: 58892
2008-11-08 06:12:46 +00:00
Daniel Dunbar bbc0af7e37 Support getTypeInfo, getTypeAlign, getTypeSize on const Type*s.
- Size/align are not effected by CVR qualifiers.

Support getCanonicalType: const Type* -> const Type*.

llvm-svn: 58891
2008-11-08 05:48:37 +00:00
Scott Michel 1ccbbc3d07 CellSPU: Fix prologue/epilogue emission when function contains calls but
theframe size is 0; the prologue and epilogue should be emitted in this case.

llvm-svn: 58890
2008-11-08 05:16:20 +00:00
Daniel Dunbar 8ec8048f93 "Fix" PR3021, don't crash on generating record types when we can't
generate the type of a member.

llvm-svn: 58889
2008-11-08 04:42:29 +00:00
Daniel Dunbar ad0a0f9cd2 Silence a gcc warning.
llvm-svn: 58888
2008-11-08 04:28:37 +00:00
Daniel Dunbar 2b9dce2669 Rework r58829, allowing removal of dbg info intrinsics during alloca
promotion.
 - Eliminate uses after free and simplify tests.

Devang: Please check that this is still doing what you intended.
llvm-svn: 58887
2008-11-08 04:12:17 +00:00
Zhongxing Xu 3d43015bc7 Add a boilerplate for out-of-bound array checking. This has no real function currently.
llvm-svn: 58886
2008-11-08 03:45:42 +00:00
Daniel Dunbar 06ad209fb1 Add LLVMC2 tool definitions for Objective-C and Objective-C++.
llvm-svn: 58885
2008-11-08 03:25:47 +00:00
Daniel Dunbar 813a640821 Add svn:ignore properties for Clang llvmc2 plugin.
llvm-svn: 58884
2008-11-08 03:10:19 +00:00
Evan Cheng 077c8f8832 Skip over two-address use operands.
llvm-svn: 58883
2008-11-08 01:44:13 +00:00
Evan Cheng ffdd91e3b8 Handle ARM machine constantpool entry with non-lazy ptr.
llvm-svn: 58882
2008-11-08 01:31:27 +00:00
Evan Cheng b126422533 Indentation.
llvm-svn: 58881
2008-11-08 01:30:20 +00:00
Argyrios Kyrtzidis 19b66a5e32 In a declarator, consider an identifier a constructor only if it is followed by '('.
Previously:

class C {
  int C;  // Declarator::SetConstructor was called here.
};

llvm-svn: 58880
2008-11-08 01:09:16 +00:00
Ted Kremenek 865da3cae0 remove unavailable clang project
llvm-svn: 58879
2008-11-08 01:02:44 +00:00
Ted Kremenek 58b1c2d54a update post-build step
llvm-svn: 58878
2008-11-08 01:02:26 +00:00
Evan Cheng 454ff53d58 Use ARMFunctionInfo to track number of constpool entries and jumptables.
llvm-svn: 58877
2008-11-08 00:51:41 +00:00
Dale Johannesen d70bd61758 Generated code for generic expansion of SETUGT etc.
is noticeably worse than previous PPC-specific code.
Since the latter was also wrong in some cases and
correctness is more important than efficiency, I'm
disabling this test temporarily while I fix it.

llvm-svn: 58876
2008-11-08 00:49:19 +00:00
Dale Johannesen ee04c24bd5 Xfail an incorrect test.
llvm-svn: 58875
2008-11-08 00:40:24 +00:00
Dale Johannesen bb5c9b4b68 Make testb optimization work on big-endian targets.
llvm-svn: 58874
2008-11-08 00:01:16 +00:00
Sebastian Redl 015085fafa Greatly improve static_cast diagnostics
llvm-svn: 58873
2008-11-07 23:29:29 +00:00
Evan Cheng ef4d78ba67 More code clean up.
llvm-svn: 58872
2008-11-07 22:57:53 +00:00
Dale Johannesen 160be0ffda Make FP tests requiring two compares work on PPC (PR 642).
This is Chris' patch from the PR, modified to realize that
SETUGT/SETULT occur legitimately with integers, plus
two fixes in LegalizeDAG to pass a valid result type into
LegalizeSetCC.  The argument of TLI.getSetCCResultType is
ignored on PPC, but I think I'm following usage elsewhere.

llvm-svn: 58871
2008-11-07 22:54:33 +00:00
Douglas Gregor a1f013e8ed Initial, partially-baked support for implicit user-defined conversions by conversion functions
llvm-svn: 58870
2008-11-07 22:36:19 +00:00
Evan Cheng 8467e2459a Get PIC jump table working.
llvm-svn: 58869
2008-11-07 22:30:53 +00:00
Evan Cheng 077f686d4b More debug output.
llvm-svn: 58868
2008-11-07 22:30:29 +00:00
Cedric Venet 571c662350 Use css style instead of hard coded color in cxx_status. No visible change.
llvm-svn: 58867
2008-11-07 22:24:44 +00:00
Argyrios Kyrtzidis e442635c37 Changes in preparation for nested-name-specifiers.
-When parsing declarators, don't depend on "CurScope->isCXXClassScope() == true" for constructors/destructors
-For C++ member declarations, don't depend on "Declarator.getContext() == Declarator::MemberContext"

llvm-svn: 58866
2008-11-07 22:02:30 +00:00
Dan Gohman cc0d2cfa01 Make tablegen print out a nice error message for a const char*
exception, like it does for a std::string exception.

llvm-svn: 58865
2008-11-07 21:01:13 +00:00
Ted Kremenek 47a6235491 Updated checker build.
llvm-svn: 58864
2008-11-07 20:55:59 +00:00
Dan Gohman 67feab3b5a Document the acronym RAUW. Patch by Jonathan Brandmeyer!
llvm-svn: 58863
2008-11-07 20:29:17 +00:00
Douglas Gregor 60e64cfc43 Update C++ status
llvm-svn: 58862
2008-11-07 20:16:04 +00:00
Duncan Sands 2d636b5265 Sign-extend rather than zero-extend when promoting
the condition for a BRCOND, according to what is
returned by getSetCCResultContents.  Since all
targets return the same thing (ZeroOrOneSetCCResult),
this should be harmless!  The point is that all over
the place the result of SETCC is fed directly into
BRCOND.  On machines for which getSetCCResultContents
returns ZeroOrNegativeOneSetCCResult, this is a
sign-extended boolean.  So it seems dangerous to
also feed BRCOND zero-extended booleans in some
circumstances - for example, when promoting the
condition.

llvm-svn: 58861
2008-11-07 20:13:04 +00:00
Douglas Gregor dbc5daf058 Parsing, ASTs, and semantic analysis for the declaration of conversion
functions in C++, e.g.,

  struct X {
    operator bool() const;
  };

Note that these conversions don't actually do anything, since we don't
yet have the ability to use them for implicit or explicit conversions.

llvm-svn: 58860
2008-11-07 20:08:42 +00:00
Dan Gohman cb0df597e0 Flush the raw_ostream after emitting the assembly for a function.
This is a temporary fix for the -print-emitted-asm option, where
errs() is used as the stream, in the case where other code is
using stderr without using errs()' buffer. Hopefully soon we'll
fix errs() to be non-buffered instead. Patch by Preston Gurd.

llvm-svn: 58859
2008-11-07 19:49:17 +00:00
Dale Johannesen 9016882d67 Fix unsigned->ppcf128 conversion.
llvm-svn: 58856
2008-11-07 19:11:43 +00:00
Argyrios Kyrtzidis 56fa31bc87 Assert that Parser::MaybeParseOperatorFunctionId is called when token is kw_operator, and replace ExpectAndConsume for the 'operator' token with a ConsumeToken.
llvm-svn: 58855
2008-11-07 15:54:02 +00:00
Douglas Gregor 450c75a15f Separate the parsing of type-specifiers from other declaration specifiers, so that we can parse a C++ type-specifier-seq
llvm-svn: 58854
2008-11-07 15:42:26 +00:00
Anders Carlsson aaa183e944 include alloca.h instead of malloc.h. If this doesn't work for everyone we can just declare alloca directly in the file.
llvm-svn: 58853
2008-11-07 15:41:33 +00:00