summaryrefslogtreecommitdiffstats
path: root/clang/lib/CodeGen/CGBuiltin.cpp
Commit message (Collapse)AuthorAgeFilesLines
...
* Enable the implementation of __builtin_setjmp and __builtin_longjmp. Not allJohn McCall2010-05-271-15/+18
| | | | | | LLVM backends support these yet. llvm-svn: 104867
* Implement codegen for __builtin_isnormal.Benjamin Kramer2010-05-191-5/+19
| | | | llvm-svn: 104118
* add todos for isinf_sign and isnormal, which I don't intend to implementChris Lattner2010-05-061-1/+8
| | | | | | in the near future. llvm-svn: 103169
* implement codegen support for __builtin_isfinite, part of PR6083Chris Lattner2010-05-061-0/+13
| | | | llvm-svn: 103168
* implement part of PR6083: codegen support for isinf. Like isnan,Chris Lattner2010-05-061-1/+35
| | | | | | | this is generating correct but suboptimal (extra extend to double) code for the float case. Will investigate next. llvm-svn: 103166
* Rewrite handling of 64-bit palignr intrinsics to be vector shuffles.Eric Christopher2010-04-151-2/+32
| | | | | | | | | Stop multiplying constant by 8 accordingly in the header and change intrinsic definition for what types we expect. Add to existing palignr test to check that we're emitting the correct things. llvm-svn: 101332
* implement altivec.h and a bunch of support code, patch by Anton Yartsev!Chris Lattner2010-04-141-0/+44
| | | | llvm-svn: 101215
* @llvm.sqrt isn't really close enough to C's sqrt to justify emitting callsJohn McCall2010-04-071-7/+6
| | | | | | | | to the intrinsic, even when math-errno is off. Fixes rdar://problem/7828230 by falling back on the library function. llvm-svn: 100613
* Reapply patch for adding support for address spaces and added a isVolatile ↵Mon P Wang2010-04-041-17/+29
| | | | | | field to memcpy, memmove, and memset. llvm-svn: 100305
* Revert r100193 since it causes failures in objc in clangMon P Wang2010-04-021-29/+17
| | | | llvm-svn: 100200
* Reapply patch for adding support for address spaces and added a isVolatile ↵Mon P Wang2010-04-021-17/+29
| | | | | | field to memcpy, memmove, and memset. llvm-svn: 100193
* Revert Mon Ping's 99930 due to broken llvm-gcc buildbots.Bob Wilson2010-03-301-29/+17
| | | | llvm-svn: 99949
* Added support for address spaces and added a isVolatile field to memcpy, ↵Mon P Wang2010-03-301-17/+29
| | | | | | memmove, and memset llvm-svn: 99930
* Remove support for nand atomic builtins. They are inconsistently implemented inDaniel Dunbar2010-03-251-17/+0
| | | | | | | gcc, and the common expectation seems to be that they are unused. If and when someone cares we can add them back with well documented demantics. llvm-svn: 99522
* IRgen: Wrap atomic intrinsics with memory barriers, to ensure we honor the ↵Daniel Dunbar2010-03-201-25/+51
| | | | | | | | semantics. - This should be conservatively correct, we eventually should have target hooks for platforms that are less strict. llvm-svn: 99050
* PR6515: Implement __builtin_signbit and friends.Eli Friedman2010-03-061-0/+17
| | | | | | | I'm reasonably sure my implementation is correct, but it would be nice if someone could double-check. llvm-svn: 97864
* Implement __builtin_dwarf_sp_column for i386 (Darwin and not), x86-64 (all),John McCall2010-03-061-0/+16
| | | | | | | and ARM. Implement __builtin_init_dwarf_reg_size_table for i386 (both) and x86-64 (all). llvm-svn: 97859
* Revert changes r97693, r97700, and r97718.John McCall2010-03-041-15/+0
| | | | | | Our testing framework can't deal with disabled targets yet. llvm-svn: 97719
* Implement __builtin_dwarf_sp_column().John McCall2010-03-041-0/+15
| | | | llvm-svn: 97700
* add framework for ARM builtins, Patch by Edmund Grimley Evans!Chris Lattner2010-03-031-0/+15
| | | | llvm-svn: 97656
* Sketch out an implementation for __builtin_dwarf_cfa. I have no ideaJohn McCall2010-03-031-0/+18
| | | | | | why the front-end is calculating the argument to llvm.eh.dwarf.cfa(). llvm-svn: 97653
* Implement __builtin_eh_return.John McCall2010-03-031-0/+16
| | | | llvm-svn: 97643
* Add proper target hooks for __builtin_extract_return_address andJohn McCall2010-03-031-3/+9
| | | | | | | __builtin_frob_return_address. The implementations for both are still trivial in the default case. llvm-svn: 97638
* Inspired by seeing "MIPS" go by in the commits, I've gone ahead andJohn McCall2010-03-021-10/+25
| | | | | | | | | | | implemented a (codegen) target hook for __builtin_extend_pointer. I'm also making it return a uint64_t instead of an unsigned word; this comports with typical usage (i.e. the one use I know of). I don't know if any of the existing targets requires this hook to be set (other than x86 and x86_64, which I know do not). llvm-svn: 97547
* After much consultation aimed at figuring out what this builtin actuallyJohn McCall2010-03-021-0/+16
| | | | | | | does, document the results and then implement __builtin_extend_pointer for platforms where it's a no-op. llvm-svn: 97540
* IRgen: Add CreateMemTemp, for creating an temporary memory object for a ↵Daniel Dunbar2010-02-091-2/+1
| | | | | | | | | | particular type, and flood fill. - CreateMemTemp sets the alignment on the alloca correctly, which fixes a great many places in IRgen where we were doing the wrong thing. - This fixes many many more places than the test case, but my feeling is we need to audit alignment systematically so I'm not inclined to try hard to test the individual fixes in this patch. If this bothers you, patches welcome! PR6240. llvm-svn: 95648
* IRgen: Fix some CreateTempAlloca calls to use ConvertTypeForMem when that isDaniel Dunbar2010-02-051-1/+2
| | | | | | conceptually correct. Review appreciated (Chris, Eli, Anders). llvm-svn: 95401
* Add bzero builtin; this should help codegen quality for code using thisEli Friedman2010-01-231-0/+1
| | | | | | function. llvm-svn: 94320
* Created __builtin___NSStringMakeConstantString() builtin, which generates ↵David Chisnall2010-01-231-0/+1
| | | | | | constant Objective-C strings. llvm-svn: 94274
* Add codgen for BI__builtin_llvm_memory_barrier.Tanya Lattner2010-01-161-0/+12
| | | | llvm-svn: 93611
* Promote arguments of frameaddr / returnaddr builtins to i32 type, when needed.Anton Korobeynikov2009-12-271-2/+10
| | | | | | | This is needed for the platforms, where bitwidth of "int" is not 32 bits (e.g. 16 on msp430). llvm-svn: 92176
* Fill in the return value slot in CGExprAgg::VisitCallExpr. This takes us ↵Anders Carlsson2009-12-241-0/+1
| | | | | | halfway towards fixing PR5824. llvm-svn: 92142
* Add a ReturnValueSlot class. Change the argument order in EmitCall to match ↵Anders Carlsson2009-12-241-3/+3
| | | | | | the other overload better. llvm-svn: 92136
* Update for the intrinsic changes in llvm: the object size intrinsicEric Christopher2009-12-231-1/+10
| | | | | | | only takes a boolean second argument now. Update tests accordingly. Currently the builtin still accepts the full range for compatibility. llvm-svn: 91983
* Fix a few MSVC warnings.Daniel Dunbar2009-12-181-3/+1
| | | | llvm-svn: 91714
* Fix for PR5801: codegen memcpy, memmove, memset directly to LLVM intrinsics.Eli Friedman2009-12-171-0/+3
| | | | llvm-svn: 91573
* Add an addition check for undefined behavior for when we hit aMike Stump2009-12-161-0/+2
| | | | | | __builtin_unreachable. WIP. llvm-svn: 91499
* Revert mmx palignr to use an intrinsic, since mmx shuffle patterns are missing.Nate Begeman2009-12-141-1/+4
| | | | llvm-svn: 91269
* Support x86's PALIGNR instruction without the use of a palignr intrinsic.Nate Begeman2009-12-141-4/+32
| | | | llvm-svn: 91264
* Remove obsolete fallback code for objectsize.Mike Stump2009-12-071-10/+0
| | | | llvm-svn: 90780
* Update for llvm intrinsics change.Eric Christopher2009-12-011-0/+7
| | | | llvm-svn: 90208
* Explicitly use setVolatile instead of extra IRBuilder argument.Daniel Dunbar2009-11-291-1/+3
| | | | llvm-svn: 90095
* Pass a value for the isSigned parameter of CreateIntCast, rather thanDuncan Sands2009-11-161-5/+10
| | | | | | passing the name (an exotic way of specifying that the result is signed!). llvm-svn: 88909
* Enable the use of the new llvm objectsize intrinsic.Mike Stump2009-11-091-4/+2
| | | | llvm-svn: 86607
* __builtin_object_size refinements. Ensure we handle expressions withMike Stump2009-10-271-5/+7
| | | | | | | | | | side-effects up front, as when we switch to the llvm intrinsic call for __builtin_object_size later, it will have two evaluations. We also finish off the intrinsic version of the code so we can just turn it on once llvm has the intrinsic. llvm-svn: 85324
* Prep for future __builtin_object_size refinements. The theory is thatMike Stump2009-10-261-0/+11
| | | | | | | | | | someone will add an llvm intrinsic for us to use, so the optimizer can figure out the hard cases. WIP. For those that want to help, double check with Eric before starting. He has a bit of code this will plug into. llvm-svn: 85175
* Simplify pointer creation with the new Type::getInt*Ptr methods.Benjamin Kramer2009-10-131-10/+6
| | | | llvm-svn: 83964
* Implement __builtin_unreachable(), a GCC 4.5 extension.Chris Lattner2009-09-211-1/+6
| | | | llvm-svn: 82433
* Fix subtle bug in generating LLVM function declarations for builtin functions.Daniel Dunbar2009-09-141-1/+1
| | | | | | | | | | The decl wasn't being passed down, which meant that function attributes were not being set correctly. This is particularly important for ARM, since it wants to override the calling convention. Instead we would emit the builtin with the wrong calling convention, and instcombine would come along and merrily shred all the calls to it. :) llvm-svn: 81756
* Remove tabs, and whitespace cleanups.Mike Stump2009-09-091-77/+77
| | | | llvm-svn: 81346
OpenPOWER on IntegriCloud