summaryrefslogtreecommitdiffstats
path: root/llvm/lib/AsmParser/LLLexer.cpp
Commit message (Collapse)AuthorAgeFilesLines
...
* Split the Add, Sub, and Mul instruction opcodes into separateDan Gohman2009-06-041-1/+3
| | | | | | | | | | | | | | | integer and floating-point opcodes, introducing FAdd, FSub, and FMul. For now, the AsmParser, BitcodeReader, and IRBuilder all preserve backwards compatability, and the Core LLVM APIs preserve backwards compatibility for IR producers. Most front-ends won't need to change immediately. This implements the first step of the plan outlined here: http://nondot.org/sabre/LLVMNotes/IntegerOverflow.txt llvm-svn: 72897
* Add new function attribute - noredzone. Devang Patel2009-06-041-0/+1
| | | | | | | Update code generator to use this attribute and remove DisableRedZone target option. Update llc to set this attribute when -disable-red-zone command line option is used. llvm-svn: 72894
* Give embedded metadata its own type instead of relying on EmptyStructTy.Nick Lewycky2009-05-301-0/+1
| | | | llvm-svn: 72610
* Add a new "available_externally" linkage type. This is intendedChris Lattner2009-04-131-0/+1
| | | | | | | | to support C99 inline, GNU extern inline, etc. Related bugzilla's include PR3517, PR3100, & PR2933. Nothing uses this yet, but it appears to work. llvm-svn: 68940
* Add support for embedded metadata to LLVM. This introduces two new types ofNick Lewycky2009-04-041-0/+1
| | | | | | | | Constant, MDString and MDNode which can only be used by globals with a name that starts with "llvm." or as arguments to a function with the same naming restriction. llvm-svn: 68420
* Fix internal representation of fp80 to be theDale Johannesen2009-03-231-1/+34
| | | | | | | | | | same as a normal i80 {low64, high16} rather than its own {high64, low16}. A depressing number of places know about this; I think I got them all. Bitcode readers and writers convert back to the old form to avoid breaking compatibility. llvm-svn: 67562
* It makes no sense to have a ODR version of commonDuncan Sands2009-03-111-1/+0
| | | | | | linkage, so remove it. llvm-svn: 66690
* Remove the one-definition-rule version of extern_weakDuncan Sands2009-03-111-1/+0
| | | | | | | linkage: this linkage type only applies to declarations, but ODR is only relevant to globals with definitions. llvm-svn: 66650
* Introduce new linkage types linkonce_odr, weak_odr, common_odrDuncan Sands2009-03-071-0/+4
| | | | | | | | | | | | | | | | | | | | | and extern_weak_odr. These are the same as the non-odr versions, except that they indicate that the global will only be overridden by an *equivalent* global. In C, a function with weak linkage can be overridden by a function which behaves completely differently. This means that IP passes have to skip weak functions, since any deductions made from the function definition might be wrong, since the definition could be replaced by something completely different at link time. This is not allowed in C++, thanks to the ODR (One-Definition-Rule): if a function is replaced by another at link-time, then the new function must be the same as the original function. If a language knows that a function or other global can only be overridden by an equivalent global, it can give it the weak_odr linkage type, and the optimizers will understand that it is alright to make deductions based on the function body. The code generators on the other hand map weak and weak_odr linkage to the same thing. llvm-svn: 66339
* Add the private linkage.Rafael Espindola2009-01-151-0/+1
| | | | llvm-svn: 62279
* Alphabetized #includes.Misha Brukman2009-01-021-1/+1
| | | | llvm-svn: 61595
* Down with trailing whitespace!Misha Brukman2009-01-021-5/+5
| | | | llvm-svn: 61594
* add a #include to hopefully get the x86-64-linux buildbot building.Chris Lattner2009-01-021-0/+1
| | | | llvm-svn: 61563
* Reimplement the old and horrible bison parser for .ll files with a niceChris Lattner2009-01-021-335/+273
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | and clean recursive descent parser. This change has a couple of ramifications: 1. The parser code is about 400 lines shorter (in what we maintain, not including what is autogenerated). 2. The code should be significantly faster than the old code because we don't have to work around bison's poor handling of datatypes with ctors/dtors. This also makes the code much more resistant to memory leaks. 3. We now get caret diagnostics from the .ll parser, woo. 4. The actual diagnostics emited from the parser are completely different so a bunch of testcases had to be updated. 5. I now disallow "%ty = type opaque %ty = type i32". There was no good reason to support this, it was just an accident of the old implementation. I have no reason to think that anyone is actually using this. 6. The syntax for sticking a global variable has changed to make it unambiguous. I don't think anyone is depending on this since only clang supports this and it is not solid yet, so I'm not worried about anything breaking. 7. This gets rid of the last use of bison, and along with it the .cvs files. I'll prune this from the makefiles as a subsequent commit. There are a few minor cleanups that can be done after this commit (suggestions welcome!) but this passes dejagnu testing and is ready for its time in the limelight. llvm-svn: 61558
* Commit missed files from nocapture change.Nick Lewycky2008-12-191-0/+1
| | | | llvm-svn: 61240
* Temporarily revert r61019, r61030, and r61040. These were breaking LLVM ReleaseBill Wendling2008-12-161-1/+0
| | | | | | builds. llvm-svn: 61094
* Introducing nocapture, a parameter attribute for pointers to indicate that theNick Lewycky2008-12-151-0/+1
| | | | | | | | | | | | | | | | | | | | | | | callee will not introduce any new aliases of that pointer. The attributes had all bits allocated already, so I decided to collapse alignment. Alignment was previously stored as a 16-bit integer from bits 16 to 32 of the attribute, but it was required to be a power of 2. Now it's stored in log2 encoded form in five bits from 16 to 21. That gives us 11 more bits of space. You may have already noticed that you only need four bits to encode a 16-bit power of two, so why five bits? Because the AsmParser accepted 32-bit alignments, even though we couldn't store them (they were silently discarded). Now we can store them in memory, but not in the bitcode. The bitcode format was already storing these as 64-bit VBR integers. So, the bitcode format stays the same, keeping the alignment values stored as 16 bit raw values. There's some hideous code in the reader and writer that deals with this, waiting to be ripped out the moment we run out of bits again and have to replace the parameter attributes table encoding. llvm-svn: 61019
* Implement stack protectors as function attributes: "ssp" and "sspreq".Bill Wendling2008-11-131-0/+2
| | | | llvm-svn: 59202
* Implement function notes as function attributes. Devang Patel2008-09-261-5/+3
| | | | llvm-svn: 56716
* Add "inreg" field to CallSDNode (doesn't increaseDale Johannesen2008-09-261-1/+0
| | | | | | | | | its size). Adjust various lowering functions to pass this info through from CallInst. Use it to implement sseregparm returns on X86. Remove X86_ssecall calling convention. llvm-svn: 56677
* Parse and print opt_size note.Devang Patel2008-09-031-1/+1
| | | | llvm-svn: 55740
* Parse function notes.Devang Patel2008-09-021-0/+6
| | | | llvm-svn: 55646
* Add read/write support for X86's sseregparm.Dale Johannesen2008-08-131-0/+1
| | | | llvm-svn: 54744
* Enable first-class aggregates support.Dan Gohman2008-07-231-1/+1
| | | | | | | | | | | | Remove the GetResultInst instruction. It is still accepted in LLVM assembly and bitcode, where it is now auto-upgraded to ExtractValueInst. Also, remove support for return instructions with multiple values. These are auto-upgraded to use InsertValueInst instructions. The IRBuilder still accepts multiple-value returns, and auto-upgrades them to InsertValueInst instructions. llvm-svn: 53941
* Make structs and arrays first-class types, and add assemblyDan Gohman2008-05-231-0/+2
| | | | | | | | | and bitcode support for the extractvalue and insertvalue instructions and constant expressions. Note that this does not yet include CodeGen support. llvm-svn: 51468
* Recognize the "default" keyword, which is documented in LangRef.htmlDan Gohman2008-05-221-0/+1
| | | | | | and supported in the grammar, in the lexer. llvm-svn: 51448
* Add CommonLinkage; currently tentative definitionsDale Johannesen2008-05-141-0/+1
| | | | | | | | | | are represented as "weak", but there are subtle differences in some cases on Darwin, so we need both. The intent is that "common" will behave identically to "weak" unless somebody changes their target to do something else. No functional change as yet. llvm-svn: 51118
* Add two new instructions to the llvm IR, vicmp and vfcmp. see updated LangRefNate Begeman2008-05-121-0/+2
| | | | | | for details. CodeGen support coming in a follow up patch llvm-svn: 50985
* Remove 'unwinds to' support from mainline. This patch undoes r47802 r47989Nick Lewycky2008-04-251-1/+0
| | | | | | r48047 r48084 r48085 r48086 r48088 r48096 r48099 r48109 and r48123. llvm-svn: 50265
* Turn unwind_to into "unwinds to".Nick Lewycky2008-03-101-1/+1
| | | | llvm-svn: 48123
* Add an unwind_to field to basic blocks, making them Users instead of Values.Nick Lewycky2008-03-021-0/+1
| | | | | | This is the first checkin for PR1269, the new EH infrastructure. llvm-svn: 47802
* Unbreak build with gcc 4.3: provide missed includes and silence most ↵Anton Korobeynikov2008-02-201-0/+2
| | | | | | annoying warnings. llvm-svn: 47367
* ParseDevang Patel2008-02-191-0/+1
| | | | | | %b = getresult {i32, i32} %a, i32 1 llvm-svn: 47349
* Remove attribution from file headers, per discussion on llvmdev.Chris Lattner2007-12-291-2/+2
| | | | llvm-svn: 45418
* Remove spurious warnings from GCC:Bill Wendling2007-12-161-75/+79
| | | | | | | | | warning: suggest a space before ';' or explicit braces around empty body in 'for' statement Patch by Mike Stump (modified slightly by yours truly). llvm-svn: 45071
* Implement address space attribute for LLVM pointer types. Address spaces are Christopher Lamb2007-12-111-0/+1
| | | | | | | | | | | | | | | | | regions of memory that have a target specific relationship, as described in the Embedded C Technical Report. This also implements the 2007-12-11-AddressSpaces test, which demonstrates how address space attributes can be used in LLVM IR. In addition, this patch changes the bitcode signature for stores (in a backwards compatible manner), such that the pointer type, rather than the pointee type, is encoded. This permits type information in the pointer (e.g. address space) to be preserved for stores. LangRef updates are forthcoming. llvm-svn: 44858
* Adding a collector name attribute to Function in the IR. These Gordon Henriksen2007-12-101-0/+1
| | | | | | | | | | | | | | | | | | | | methods are new to Function: bool hasCollector() const; const std::string &getCollector() const; void setCollector(const std::string &); void clearCollector(); The assembly representation is as such: define void @f() gc "shadow-stack" { ... The implementation uses an on-the-side table to map Functions to collector names, such that there is no overhead. A StringPool is further used to unique collector names, which are extremely likely to be unique per process. llvm-svn: 44769
* add #includeChris Lattner2007-12-081-0/+1
| | | | llvm-svn: 44710
* Rename the 'const' parameter attribute to 'readnone',Duncan Sands2007-11-221-2/+2
| | | | | | | and the 'pure' parameter attribute to 'readonly'. Names suggested by DannyB. llvm-svn: 44273
* autoupgrade files that use callfoo as call foo.Chris Lattner2007-11-181-1/+9
| | | | llvm-svn: 44218
* Bugfix, this fixes CodeGen/X86/ldzero.ll and ↵Chris Lattner2007-11-181-1/+1
| | | | | | CodeGen/X86/2007-10-16-fp80_select.ll llvm-svn: 44215
* Replace the original flex lexer with a hand writen one. This Chris Lattner2007-11-181-0/+826
drops a dependency on flex and lets us make future progress more easily. Yay for 2 fewer .cvs files to make silly conflicts with. llvm-svn: 44213
OpenPOWER on IntegriCloud