summaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
...
* ccc/Driver: Forward -fheinous-gnu-extensions to clang.Daniel Dunbar2009-03-132-0/+2
| | | | llvm-svn: 66915
* Driver: Fix '-x none' handling.Daniel Dunbar2009-03-132-4/+38
| | | | | | - Enough stuff works now we can test argument parsing & pipelining. llvm-svn: 66913
* ccc/Driver: Normalize phase spelling in -ccc-print-phases.Daniel Dunbar2009-03-133-8/+8
| | | | llvm-svn: 66912
* Driver: Some minor bug fixes.Daniel Dunbar2009-03-133-4/+4
| | | | | | | | | - language recognition was recognizing prefixes incorrectly. - -x none wasn't working. - test for "can lipo" was backwords. - missed a '"' in -ccc-print-phases llvm-svn: 66911
* introduce a new -fheinous-gnu-extensions flag that enables reallyChris Lattner2009-03-137-7/+76
| | | | | | | | | | | really horrible extensions that are disabled by default but that can be accepted by -fheinous-gnu-extensions (but which always emit a warning when enabled). As our first instance of this, implement PR3788/PR3794, which allows non-lvalues in inline asms in contexts where lvalues are required. bleh. llvm-svn: 66910
* add a helper function to strip noop casts.Chris Lattner2009-03-132-1/+43
| | | | llvm-svn: 66909
* Driver: Fix think in ArgList::MakeIndex.Daniel Dunbar2009-03-131-1/+1
| | | | llvm-svn: 66908
* Driver: Return 0 from BuildCompilation on -ccc-print-phases,Daniel Dunbar2009-03-132-4/+6
| | | | | | -ccc-print-options. llvm-svn: 66907
* Driver: Print -ccc-print-phases on stderr.Daniel Dunbar2009-03-131-4/+2
| | | | llvm-svn: 66906
* Fix typo.Ted Kremenek2009-03-131-1/+1
| | | | llvm-svn: 66905
* Fix <rdar://problem/6675489> BlockDecl should not use llvm::smallvector.Steve Naroff2009-03-134-13/+49
| | | | | | Also changed BlockDecl API to be more consistent (wrt FunctionDecl). llvm-svn: 66904
* generalize this code so that fast isel handles integer truncates to i1, whichChris Lattner2009-03-131-2/+4
| | | | | | | codegen to the same thing as integer truncates to i8 (the top bits are just undefined). This implements rdar://6667338 llvm-svn: 66902
* Add a hack in the analyzer to recover some path-sensitivity at branchTed Kremenek2009-03-132-1/+107
| | | | | | | | | | | | | | | | | | conditions. Currently the analyzer does not reason well about promotions/truncations of symbolic values, so at branch conditions when we see: if (condition) and condition is something like a 'short' or 'char', essentially ignore the promotion to 'int' so that we track constraints on the original symbolic value. We only ignore the casts if the underlying type has the same or fewer bits as the converted type. This fixes: <rdar://problem/6619921> llvm-svn: 66899
* add a new TGError class and use it to propagate location info withChris Lattner2009-03-133-20/+26
| | | | | | | | | | | | | | | | | | | | | errors when thrown. This gets us nice errors like this from tblgen: CMOVL32rr: (set GR32:i32:$dst, (X86cmov GR32:$src1, GR32:$src2)) /Users/sabre/llvm/Debug/bin/tblgen: error: Included from X86.td:116: Parsing X86InstrInfo.td:922: In CMOVL32rr: X86cmov node requires exactly 4 operands! def CMOVL32rr : I<0x4C, MRMSrcReg, // if <s, GR32 = GR32 ^ instead of just: CMOVL32rr: (set GR32:i32:$dst, (X86cmov GR32:$src1, GR32:$src2)) /Users/sabre/llvm/Debug/bin/tblgen: In CMOVL32rr: X86cmov node requires exactly 4 operands! This is all I plan to do with this, but it should be easy enough to improve if anyone cares (e.g. keeping more loc info in "dag" expr records in tblgen. llvm-svn: 66898
* give each Record a location.Chris Lattner2009-03-134-15/+29
| | | | llvm-svn: 66897
* Reimplement fix for <rdar://problem/6451399> problems with labels and blocks.Steve Naroff2009-03-134-3/+27
| | | | | | | | This solution is much simpler (and doesn't add any per-scope overhead, which concerned Chris). The only downside is the LabelMap is now declared in two places (Sema and BlockSemaInfo). My original fix tried to unify the LabelMap in "Scope" (which would support nested functions in general). In any event, this fixes the bug given the current language definition. If/when we decide to support GCC style nested functions, this will need to be tweaked. llvm-svn: 66896
* make "locations" a class instead of a typedef.Chris Lattner2009-03-137-58/+82
| | | | llvm-svn: 66895
* Updated comment.Ted Kremenek2009-03-131-0/+2
| | | | llvm-svn: 66894
* Remove ActiveScope (revert ↵Steve Naroff2009-03-138-96/+19
| | | | | | | | http://llvm.org/viewvc/llvm-project?view=rev&revision=65694 and http://llvm.org/viewvc/llvm-project?view=rev&revision=66741). Will replace with something better today... llvm-svn: 66893
* Fix failure reported by Sebastian of test/Analysis/ptr-arith.c when the targetTed Kremenek2009-03-133-15/+20
| | | | | | | | | | is 64-bit. I used his suggestion of doing a direct bitwidth/signedness conversion of the 'offset' instead of just changing the sign. For more information, see: http://lists.cs.uiuc.edu/pipermail/cfe-dev/2009-March/004587.html llvm-svn: 66892
* Split get_involved into Get Involved and Open Projects pagesDouglas Gregor2009-03-133-90/+101
| | | | llvm-svn: 66891
* Update these for the 2.5 release.Duncan Sands2009-03-131-7/+7
| | | | llvm-svn: 66890
* Driver: Fix thinko in Darwin host identification.Daniel Dunbar2009-03-131-1/+1
| | | | llvm-svn: 66889
* Driver: Support -ccc-print-phases.Daniel Dunbar2009-03-132-4/+47
| | | | llvm-svn: 66888
* Driver: Add cast<> support for Action, and some other accessors.Daniel Dunbar2009-03-132-18/+128
| | | | llvm-svn: 66887
* ccc: Don't print the arch for every action when printing phases.Daniel Dunbar2009-03-131-5/+3
| | | | llvm-svn: 66886
* Driver: Complete "pipelining" (building the list of abstract actionsDaniel Dunbar2009-03-133-38/+110
| | | | | | | | | to perform). Still doesn't do anything interesting. - This code came out much cleaner than in ccc with the reworked phases & mapping of types to lists of compilation steps (phases) to perform. llvm-svn: 66885
* support cmakeGabor Greif2009-03-131-0/+14
| | | | llvm-svn: 66884
* Driver: Make phase names nouns not verbs.Daniel Dunbar2009-03-131-5/+5
| | | | llvm-svn: 66883
* Driver: Add remaining Action classes we need.Daniel Dunbar2009-03-131-4/+52
| | | | llvm-svn: 66882
* Driver: Add types::getNumCompilationPhases, getCompilationPhase toDaniel Dunbar2009-03-132-0/+54
| | | | | | | provide information about what steps should be done for a particular file type. llvm-svn: 66881
* Driver: Pull Phase info into separate file.Daniel Dunbar2009-03-132-0/+59
| | | | llvm-svn: 66880
* ccc/Driver: Forward -fprint-source-range-info to clang.Daniel Dunbar2009-03-132-0/+2
| | | | llvm-svn: 66879
* These instructions have special lowering that may lower them to SSEBill Wendling2009-03-131-12/+19
| | | | | | instructions. Prevent that if we don't want implicit uses of SSE. llvm-svn: 66877
* Unbreak build, bring in std::string for GCC 4.3Argyrios Kyrtzidis2009-03-131-0/+1
| | | | llvm-svn: 66876
* Fix some significant problems with constant pools that resulted in ↵Evan Cheng2009-03-1319-134/+181
| | | | | | | | | | | | | | | | | | | | | | | unnecessary paddings between constant pool entries, larger than necessary alignments (e.g. 8 byte alignment for .literal4 sections), and potentially other issues. 1. ConstantPoolSDNode alignment field is log2 value of the alignment requirement. This is not consistent with other SDNode variants. 2. MachineConstantPool alignment field is also a log2 value. 3. However, some places are creating ConstantPoolSDNode with alignment value rather than log2 values. This creates entries with artificially large alignments, e.g. 256 for SSE vector values. 4. Constant pool entry offsets are computed when they are created. However, asm printer group them by sections. That means the offsets are no longer valid. However, asm printer uses them to determine size of padding between entries. 5. Asm printer uses expensive data structure multimap to track constant pool entries by sections. 6. Asm printer iterate over SmallPtrSet when it's emitting constant pool entries. This is non-deterministic. Solutions: 1. ConstantPoolSDNode alignment field is changed to keep non-log2 value. 2. MachineConstantPool alignment field is also changed to keep non-log2 value. 3. Functions that create ConstantPool nodes are passing in non-log2 alignments. 4. MachineConstantPoolEntry no longer keeps an offset field. It's replaced with an alignment field. Offsets are not computed when constant pool entries are created. They are computed on the fly in asm printer and JIT. 5. Asm printer uses cheaper data structure to group constant pool entries. 6. Asm printer compute entry offsets after grouping is done. 7. Change JIT code to compute entry offsets on the fly. llvm-svn: 66875
* Unbreak build.Evan Cheng2009-03-131-0/+1
| | | | llvm-svn: 66874
* split buffer management and diagnostic printing out of the tblgenChris Lattner2009-03-136-70/+228
| | | | | | lexer into its own TGSourceMgr class. llvm-svn: 66873
* Convert VirtRegMap to a MachineFunctionPass.Owen Anderson2009-03-134-28/+63
| | | | llvm-svn: 66870
* generalize the previous code to use the full generality of LEAChris Lattner2009-03-132-13/+121
| | | | | | | | | | | | | | | | | | | | | | | | | | for i32/i64 expressions (we could also do i16 on cpus where i16 lea is fast, but I didn't add this). On the example, we now generate: _test: movl 4(%esp), %eax cmpl $42, (%eax) setl %al movzbl %al, %eax leal 4(%eax,%eax,8), %eax ret instead of: _test: movl 4(%esp), %eax cmpl $41, (%eax) movl $4, %ecx movl $13, %eax cmovg %ecx, %eax ret llvm-svn: 66869
* optimize the case of cond ? 42 : 41 and friends. This compiles theChris Lattner2009-03-132-0/+41
| | | | | | | | | | | | | | | | | | | | | | | | | example to: _test: movl 4(%esp), %eax cmpl $41, (%eax) setg %al movzbl %al, %eax orl $4294967294, %eax ret instead of: movl 4(%esp), %eax cmpl $41, (%eax) movl $4294967294, %ecx movl $4294967295, %eax cmova %ecx, %eax ret which is smaller in code size and faster. rdar://6668608 llvm-svn: 66868
* Oops...I committed too much.Bill Wendling2009-03-1314-254/+233
| | | | llvm-svn: 66867
* Temporarily XFAIL this test.Bill Wendling2009-03-1315-233/+256
| | | | llvm-svn: 66866
* Enhance address-mode folding of ISD::ADD to handle cases where theDan Gohman2009-03-132-0/+38
| | | | | | | | | | operands can't both be fully folded at the same time. For example, in the included testcase, a global variable is being added with an add of two values. The global variable wants RIP-relative addressing, so it can't share the address with another base register, but it's still possible to fold the initial add. llvm-svn: 66865
* implement a new -fprint-source-range-info option, whichChris Lattner2009-03-133-5/+45
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | defaults to off. When enabled, it emits range info along with the file/line/col information for a diagnostic. This allows tools that textually parse the output of clang to know where the ranges are, even if they span multiple lines. For example, with: $ clang exprs.c -fprint-source-range-info We now produce: exprs.c:21:11:{21:12-21:13}: warning: use of unary operator that may be intended as compound assignment (+=) var =+ 5; // expected-warning {{use of unary operator that may be intended as compound assignment (+=)}} ^~ exprs.c:22:11:{22:12-22:13}: warning: use of unary operator that may be intended as compound assignment (-=) var =- 5; // expected-warning {{use of unary operator that may be intended as compound assignment (-=)}} ^~ exprs.c:36:13:{36:3-36:12}: error: assignment to cast is illegal, lvalue casts are not supported (float*)X = P; // expected-error {{assignment to cast is illegal, lvalue casts are not supported}} ~~~~~~~~~ ^ exprs.c:41:4:{41:3-41:4}: error: called object type 'int' is not a function or function pointer X(); // expected-error {{called object type 'int' is not a function or function pointer}} ~^ exprs.c:45:15:{45:8-45:14}{45:17-45:24}: error: invalid operands to binary expression ('int *' and '_Complex float') P = (P-42) + Gamma*4; // expected-error {{invalid operands to binary expression ('int *' and '_Complex float')}} ~~~~~~ ^ ~~~~~~~ exprs.c:61:7:{61:16-61:22}: error: invalid application of '__alignof' to bitfield R = __alignof(P->x); // expected-error {{invalid application of '__alignof' to bitfield}} expected-warning {{extension used}} ^ ~~~~~~ Note the range info after the column in the initial diagnostic. This is obviously really annoying if you're not a tool parsing the output of clang, which is why it is off by default. llvm-svn: 66862
* fix typoChris Lattner2009-03-131-1/+1
| | | | llvm-svn: 66860
* Fix one more place where debug info affectedDale Johannesen2009-03-131-2/+5
| | | | | | codegen (speculative execution). llvm-svn: 66859
* Driver: Ignore empty arguments.Daniel Dunbar2009-03-131-1/+11
| | | | llvm-svn: 66858
* Driver: Handle "immediate" options.Daniel Dunbar2009-03-133-14/+122
| | | | | | Also, add some FIXMEs, improve doxygen & comments. llvm-svn: 66857
* Fix test.Fariborz Jahanian2009-03-131-1/+1
| | | | llvm-svn: 66856
OpenPOWER on IntegriCloud