Anders Carlsson
77904f1d5b
Emit vbase offsets.
...
llvm-svn: 96329
2010-02-16 04:59:55 +00:00
Anders Carlsson
dc2dba306c
More work on the new layout code.
...
llvm-svn: 96328
2010-02-16 04:49:44 +00:00
John McCall
6ce747220a
When emitting complete destructors for classes with virtual bases, compute
...
the offset to the virtual bases statically inside of relying on the virtual
base offsets in the object's vtable(s). This is both more efficient and
sound against the destructor's manipulation of the vtables.
Also extract a few helper routines.
Oh and we seem to pass all tests with an optimized clang now.
llvm-svn: 96327
2010-02-16 04:15:37 +00:00
John McCall
1e3715acc3
White-list comma expressions with the literal 0 as their RHS against
...
unused-value warnings. This is a common macro idiom.
llvm-svn: 96326
2010-02-16 04:10:53 +00:00
John McCall
81e38507bd
Make the various type-decl Types (and their associated ASTContext routines)
...
accept const decls.
llvm-svn: 96325
2010-02-16 03:57:14 +00:00
Erick Tryzelaar
5bf1a325dc
Fix a typo in an LLVMOpcode enum. LLVMTrunk -> LLVMTrunc.
...
llvm-svn: 96324
2010-02-16 03:45:23 +00:00
Erick Tryzelaar
3b391a6dfa
Fix some ocaml documentation
...
llvm-svn: 96323
2010-02-16 03:45:17 +00:00
Sanjiv Gupta
adcee844ea
The code section for an ISR has a specific address.
...
Currently, whether a function is ISR or not is encoded in the section attribute for that function.
llvm-svn: 96322
2010-02-16 03:41:07 +00:00
Sanjiv Gupta
ecd2600c52
Re-applying 96173. Looks like finally I got the test case right.
...
llvm-svn: 96321
2010-02-16 03:37:11 +00:00
Ted Kremenek
588fc83c74
Add test case to show that Clang now checks the format string
...
arguments of asprintf (<rdar://problem/6657191>).
llvm-svn: 96319
2010-02-16 02:14:24 +00:00
Dale Johannesen
d7eb693643
Handle DBG_VALUE mixed with labels when doing PHI
...
elimination. Before a DBG_VALUE could affect codegen.
The solution here is imperfect and not final.
llvm-svn: 96318
2010-02-16 01:57:28 +00:00
Daniel Dunbar
ce79bc9c7a
c-index-test: Pass appropriate client data.
...
llvm-svn: 96317
2010-02-16 01:55:10 +00:00
Daniel Dunbar
1951192213
ASTUnit: Constant fold UseBumpAllocator to true, we don't care to support this as an argument.
...
llvm-svn: 96316
2010-02-16 01:55:04 +00:00
Daniel Dunbar
7f21a7f7ce
ASTUnit::LoadFromCompilerInvocation - Take ownership of the provided invocation.
...
llvm-svn: 96315
2010-02-16 01:54:54 +00:00
Daniel Dunbar
e922d9bdf0
CompilerInstance: Move LLVMContext member out of constructor.
...
llvm-svn: 96314
2010-02-16 01:54:47 +00:00
Daniel Dunbar
aced322c3c
Switch clang to use its own LLVMContext (not the global one).
...
llvm-svn: 96313
2010-02-16 01:54:33 +00:00
Rafael Espindola
af25cf825c
Drop support for the InReg attribute on the ppc backend. This was used by
...
llvm-gcc but has been replaced with pad argument which don't need any
special backend support.
llvm-svn: 96312
2010-02-16 01:50:18 +00:00
Ted Kremenek
ccf701d375
Fix test case.
...
llvm-svn: 96311
2010-02-16 01:47:05 +00:00
Ted Kremenek
c8b188d541
Refactor the logic for printf argument type-checking into analyze_printf::ArgTypeResult.
...
Implement printf argument type checking for '%s'.
Fixes <rdar://problem/3065808>.
llvm-svn: 96310
2010-02-16 01:46:59 +00:00
Ted Kremenek
1ee27e6d9a
Added 'AsWideChar' flag to LengthModifier.
...
llvm-svn: 96309
2010-02-16 01:46:47 +00:00
Dan Gohman
521efe68ab
Split the main for-each-use loop again, this time for GenerateTruncates,
...
as it also peeks at which registers are being used by other uses. This
makes LSR less sensitive to use-list order.
llvm-svn: 96308
2010-02-16 01:42:53 +00:00
Dale Johannesen
d37e7b5bc5
Reapply 96294; now that I've gotten around to looking
...
at older buildbot messages, I see the failure predates
this patch.
llvm-svn: 96307
2010-02-16 01:27:47 +00:00
Douglas Gregor
4563532043
Skeleton for importing Objective-C classes
...
llvm-svn: 96306
2010-02-16 01:20:57 +00:00
Bill Wendling
1776295bf1
Apply patch from http://llvm.org/bugs/attachment.cgi?id=4136 now that PR5004 is
...
finished.
llvm-svn: 96304
2010-02-16 00:58:02 +00:00
Dale Johannesen
ae87fc43a7
Something broke. Hard to believe it was this patch
...
but it's harder to believe it's the other candidate,
so reverting. Temporarily I hope.
llvm-svn: 96303
2010-02-16 00:43:58 +00:00
Chris Lattner
1b78ea446f
mark __builtin_longjmp noreturn, PR6312
...
llvm-svn: 96302
2010-02-16 00:23:21 +00:00
Dan Gohman
148a972b67
When reusing an existing PHI node in a loop, be even more
...
strict about the requirements.
llvm-svn: 96301
2010-02-16 00:20:08 +00:00
Douglas Gregor
9503c46a2e
Don't import __va_list_tag or __builtin_va_list when merging
...
llvm-svn: 96299
2010-02-16 00:04:46 +00:00
Douglas Gregor
b4964f7705
Cope with anonymous tags defined within declarators by structurally
...
comparing their types under the assumption that they are equivalent,
rather than importing the types and then checking for compatibility. A
few minor tweaks here:
- Teach structural matching to handle compatibility between
function types with prototypes and those without prototypes.
- Teach structural matching that an incomplete record decl is the
same as any other record decl with the same name.
- Keep track of pairs of declarations that we have already checked
(but failed to find as structurally matching), so we don't emit
diagnostics repeatedly.
- When importing a typedef of an anonymous tag, be sure to link the
imported tag type to its typedef.
With these changes, we survive a repeated import of <stdlib.h> and
<stdio.h>. Alas, the ASTNodeImporter is getting a little grotty.
llvm-svn: 96298
2010-02-15 23:54:17 +00:00
Bob Wilson
a945c64b5a
Put repeated empty pattern into the AQI instruction class.
...
We could almost use a multiclass for the signed/unsigned instructions, but
there are only 6 of them so I guess it's not worth it.
llvm-svn: 96297
2010-02-15 23:43:47 +00:00
Evan Cheng
3f08464a1a
Fix a memory leak. Patch by Nicolas Geoffray.
...
llvm-svn: 96295
2010-02-15 23:16:53 +00:00
Dale Johannesen
5b80f0d67f
More handling of DBG_VALUE.
...
llvm-svn: 96294
2010-02-15 23:05:03 +00:00
Ted Kremenek
d51217e968
Convert GRExprEngine's handling of ObjCMessageExprs to use a worklist
...
to evaluate arguments.
llvm-svn: 96293
2010-02-15 23:02:46 +00:00
Anton Korobeynikov
1be2063afd
Add missed entry to cmake build list file
...
llvm-svn: 96292
2010-02-15 22:55:13 +00:00
Benjamin Kramer
634fc10fe1
Add Sema support for __builtin_fpclassify by extending the existing check for __builtin_isinf and friends. Part of PR6083.
...
llvm-svn: 96291
2010-02-15 22:42:31 +00:00
Anton Korobeynikov
5d438e4ad2
Use ttype encoding consistently
...
llvm-svn: 96290
2010-02-15 22:38:25 +00:00
Anton Korobeynikov
c9adb6a463
Fix a silly darwin-only typo introduced during merge.
...
llvm-svn: 96289
2010-02-15 22:38:10 +00:00
Anton Korobeynikov
ab663a0bfe
Move TLOF implementations to libCodegen to resolve layering violation.
...
llvm-svn: 96288
2010-02-15 22:37:53 +00:00
Anton Korobeynikov
ec2ba08d16
It turns out that we emitted completely wrong common EH frame since the early beginning! The "z" CIE augmentation mark indicates that there is an extra word containing the size of augmentation section. However, even for frames w/o any augmentation data we emitted size uleb! (this is the case of "unwinding through C code"). Thus frame moves information was emitterd completely wrong.
...
llvm-svn: 96287
2010-02-15 22:36:41 +00:00
Anton Korobeynikov
397aecb6d6
Add suffix for stubs, so we won't have name clashes with private symbols.
...
llvm-svn: 96286
2010-02-15 22:36:26 +00:00
Anton Korobeynikov
ae4ccc10da
Preliminary patch to improve dwarf EH generation - Hooks to return Personality / FDE / LSDA / TType encoding depending on target / options (e.g. code model / relocation model) - MCIzation of Dwarf EH printer to use encoding information - Stub generation for ELF target (needed for indirect references) - Some other small changes here and there
...
llvm-svn: 96285
2010-02-15 22:35:59 +00:00
Fariborz Jahanian
8efe0ec899
Issue a bettter diagnostics for incorrect property setter name.
...
(radar 7647953).
llvm-svn: 96284
2010-02-15 22:20:11 +00:00
Chandler Carruth
3e0c140c50
Fix instantiation of template functions with local classes that contain virtual
...
methods.
llvm-svn: 96283
2010-02-15 22:12:26 +00:00
Nick Lewycky
1d9a8159df
Teach the verifier to check the condition on a branch and ensure that it has
...
'i1' type.
llvm-svn: 96282
2010-02-15 22:09:09 +00:00
Douglas Gregor
522e22d352
Tell ASTMerge to merge every declaration it sees, rather than cherry-picking those declarations that we know will work.
...
llvm-svn: 96280
2010-02-15 22:05:17 +00:00
Jakob Stoklund Olesen
2988d573e5
Fix PR6300.
...
A virtual register can be used before it is defined in the same MBB if the MBB
is part of a loop. Teach the implicit-def pass about this case.
llvm-svn: 96279
2010-02-15 22:03:29 +00:00
Douglas Gregor
3996e249ed
Reimplement the structural-equality checks used to determine whether
...
two types in different AST contexts are equivalent. Rather than
transforming the type from one context into the other context, we
perform a deep structural comparison of the types. This change
addresses a serious problem with recursive data types like
struct ListNode {
int value;
struct ListNode *Next;
} xList;
llvm-svn: 96278
2010-02-15 22:01:00 +00:00
Bob Wilson
9be7200b08
Last week we were generating code with duplicate induction variables in this
...
test, but the problem seems to have gone away today. Add a check to make sure
it doesn't come back.
llvm-svn: 96277
2010-02-15 21:56:40 +00:00
Fariborz Jahanian
30a42923d3
Class continuation now has its own property ast for
...
those declared in it. This is to allow duplicate
property diagnostics for properties declared in class extensions
multiple times (radar 7629420) and for future use.
llvm-svn: 96276
2010-02-15 21:55:26 +00:00
Nick Lewycky
62f864dea3
Fix crash in VerifyType when checking Contexts. Because there may not be a
...
Module (we were called with verifyFunction and an unowned Function) we can't
rely on Mod->getContext().
llvm-svn: 96275
2010-02-15 21:52:04 +00:00