summaryrefslogtreecommitdiffstats
path: root/llvm/lib/Support
Commit message (Collapse)AuthorAgeFilesLines
* Fix FindExecutable to use sys::Path::GetMainExecutable instead ofDan Gohman2009-08-051-15/+8
| | | | | | | | | | | | | just argv[0]. And remove the code for searching the current working directory and for searching PATH; the point of FindExecutable is not to find whatever version of the executable can be found by searching around, but to find an executable that accompanies the current executable. Update the tools to use sys::Program::FindProgramByName when they want PATH searching. llvm-svn: 78240
* cerr isn't buffered so it doesn't need to be flushed.Dan Gohman2009-08-051-3/+3
| | | | llvm-svn: 78135
* Remove now unused arguments from TargetRegistry::lookupTarget.Daniel Dunbar2009-08-031-14/+11
| | | | llvm-svn: 77950
* Pass target triple string in to TargetMachine constructor.Daniel Dunbar2009-08-031-0/+35
| | | | | | | | | | | | | | | | | | | | | | | | | | This is not just a matter of passing in the target triple from the module; currently backends are making decisions based on the build and host architecture. The goal is to migrate to making these decisions based off of the triple (in conjunction with the feature string). Thus most clients pass in the target triple, or the host triple if that is empty. This has one important change in the way behavior of the JIT and llc. For the JIT, it was previously selecting the Target based on the host (naturally), but it was setting the target machine features based on the triple from the module. Now it is setting the target machine features based on the triple of the host. For LLC, -march was previously only used to select the target, the target machine features were initialized from the module's triple (which may have been empty). Now the target triple is taken from the module, or the host's triple is used if that is empty. Then the triple is adjusted to match -march. The take away is that -march for llc is now used in conjunction with the host triple to initialize the subtarget. If users want more deterministic behavior from llc, they should use -mtriple, or set the triple in the input module. llvm-svn: 77946
* Analog Devices Blackfin back-end.Jakob Stoklund Olesen2009-08-021-0/+3
| | | | | | | | | | | | | | Generate code for the Blackfin family of DSPs from Analog Devices: http://www.analog.com/en/embedded-processing-dsp/blackfin/processors/index.html We aim to be compatible with the exsisting GNU toolchain found at: http://blackfin.uclinux.org/gf/project/toolchain The back-end is experimental. llvm-svn: 77897
* Remove duplicated colons and spaces.Benjamin Kramer2009-08-021-15/+15
| | | | llvm-svn: 77892
* Add missing flush().Daniel Dunbar2009-08-021-0/+3
| | | | llvm-svn: 77859
* Update CMake files.Ted Kremenek2009-07-311-1/+0
| | | | llvm-svn: 77709
* Remove Annotation.h, which is no longer used in the LLVM tree.Dan Gohman2009-07-311-130/+0
| | | | llvm-svn: 77706
* Twine: Directly support int, long, and long long types.Daniel Dunbar2009-07-301-17/+29
| | | | | | - This should resolve Cygwin gcc ambiguities. llvm-svn: 77624
* Twine: Use raw_ostream::write_hex, remove unused itohexstr method.Daniel Dunbar2009-07-301-2/+1
| | | | llvm-svn: 77617
* Add raw_ostream::write_hexDaniel Dunbar2009-07-301-4/+7
| | | | llvm-svn: 77614
* Twine: Provide [u]int{32,64} conversions via implicit constructors instead ofDaniel Dunbar2009-07-301-6/+18
| | | | | | explicitly. llvm-svn: 77576
* Perform simplification noticed by Reid.Daniel Dunbar2009-07-291-4/+0
| | | | llvm-svn: 77477
* Re-apply previous changes and improve column padding performance some more.David Greene2009-07-291-17/+21
| | | | llvm-svn: 77461
* Twines: Support numeric conversion directly (uitostr, etc).Daniel Dunbar2009-07-291-11/+37
| | | | | | | | | | | | | | | - Provides static constructors for doing number to string conversions without using temporaries. - There are several ways to do this, I think given the Twine constraints this is the simplest one. - One FIXME for fast number -> hex conversion. - Added another comment on one last major bit of perf work Twines need, which is to make raw_svector_ostream more efficient. llvm-svn: 77445
* raw_ostream: Follow the 32-bit path when printing "small" decimal numbers.Daniel Dunbar2009-07-291-0/+4
| | | | llvm-svn: 77444
* Revert r77397, it causes significant regressions in llc performance.Daniel Dunbar2009-07-291-9/+4
| | | | llvm-svn: 77425
* Improve performance of PadToColumn by eliminating flushes.David Greene2009-07-281-4/+9
| | | | llvm-svn: 77397
* Make raw_null_ostream flush its buffer in its destructor, so thatDan Gohman2009-07-271-0/+9
| | | | | | | it conforms to the assertion added in r77245. This fixes a failure in qa_override.c in clang's testsuite. llvm-svn: 77255
* Add an assertion check to raw_ostream's destructor to verifyDan Gohman2009-07-271-0/+5
| | | | | | that the subclass hasn't left any pending data in the buffer. llvm-svn: 77245
* Sort list of targets in --version.Daniel Dunbar2009-07-261-8/+11
| | | | llvm-svn: 77127
* Oops, forgot XCore. Sorry XCore!Daniel Dunbar2009-07-261-2/+3
| | | | llvm-svn: 77125
* Update for API change.Daniel Dunbar2009-07-261-6/+46
| | | | llvm-svn: 77124
* Update Triple to use StringRef/Twine based APIs.Daniel Dunbar2009-07-261-58/+35
| | | | | | - This is now shorter, simpler, safer, and more efficient, what a deal. llvm-svn: 77119
* Remove unused headerDaniel Dunbar2009-07-261-1/+0
| | | | llvm-svn: 77115
* Kill Target specific ModuleMatchQuality stuff.Daniel Dunbar2009-07-261-3/+1
| | | | | | - This was overkill and inconsistently implemented. llvm-svn: 77114
* Add TargetRegistry::lookupTarget.Daniel Dunbar2009-07-261-85/+17
| | | | | | | | | | | | | | - This is a simplified mechanism which just looks up a target based on the target triple, with a few additional flags. - Remove getClosestStaticTargetForModule, the moral equivalent is now: lookupTarget(Mod->getTargetTriple, true, false, ...); - This no longer does the fuzzy matching with target data (based on endianness and pointer width) that getClosestStaticTargetForModule was doing, but this was deemed unnecessary. llvm-svn: 77111
* Added a test and fixed a bug in BumpPtrAllocator relating to large alignmentReid Kleckner2009-07-251-2/+2
| | | | | | values. Hopefully this fixes PR4622. llvm-svn: 77088
* Simplify JIT target selection.Daniel Dunbar2009-07-251-5/+20
| | | | | | | | | | - Instead of requiring targets to define a JIT quality match function, we just have them specify if they support a JIT. - Target selection for the JIT just gets the host triple and looks for the best target which matches the triple and has a JIT. llvm-svn: 77060
* Allow llvm_report_error to accept a Twine.Daniel Dunbar2009-07-241-3/+12
| | | | llvm-svn: 76961
* Update CMakeDaniel Dunbar2009-07-241-0/+1
| | | | llvm-svn: 76957
* Add Twine ADT.Daniel Dunbar2009-07-241-0/+91
| | | | | | - Not currently used. llvm-svn: 76956
* Switch to raw_ostream.Daniel Dunbar2009-07-241-9/+9
| | | | llvm-svn: 76943
* Write space padding as one string to speed up comment printing.David Greene2009-07-231-3/+13
| | | | llvm-svn: 76910
* Re-committing changes from r76825 to BumpPtrAllocator with a fix and tests forReid Kleckner2009-07-231-105/+133
| | | | | | an off-by-one error. llvm-svn: 76891
* Convert StringMap to using StringRef for its APIs.Daniel Dunbar2009-07-232-19/+14
| | | | | | | | | | | | - Yay for '-'s and simplifications! - I kept StringMap::GetOrCreateValue for compatibility purposes, this can eventually go away. Likewise the StringMapEntry Create functions still follow the old style. - NIFC. llvm-svn: 76888
* Reverting r76825 and r76828, since they caused clang runtime errors and some ↵Reid Kleckner2009-07-231-132/+104
| | | | | | build failure involving memset. llvm-svn: 76838
* add header for 'memset'.Zhongxing Xu2009-07-231-0/+1
| | | | llvm-svn: 76837
* Parameterize the BumpPtrAllocator over a slab allocator. It defaults to usingReid Kleckner2009-07-231-104/+131
| | | | | | | | | | | malloc, so there should be no functional changes to other code. These changes are necessary since I have plans to use this allocator in the JIT memory manager, and it needs a special allocator. I also added some tests which helped me pinpoint some bugs. llvm-svn: 76825
* Hide the DOUT static variable behind a function interface.David Greene2009-07-201-0/+8
| | | | llvm-svn: 76425
* Fix ConstantRange::unionWith. Also make it work a little hard in some cases toNick Lewycky2009-07-191-45/+50
| | | | | | | return the smallest union of two ranges instead of just any range that happens to contain the union. llvm-svn: 76360
* Replace intersectWith with maximalIntersectWith. The latter guarantees thatNick Lewycky2009-07-181-43/+5
| | | | | | | | all values belonging to the intersection will belong to the resulting range. The former was inconsistent about that point (either way is fine, just pick one.) This is part of PR4545. llvm-svn: 76289
* Provide slightly more refined error message when trying to lookup a target, andDaniel Dunbar2009-07-171-1/+18
| | | | | | none are registered. llvm-svn: 76181
* Add raw_null_ostream and llvm::nulls(), a raw_ostream that discards output.Daniel Dunbar2009-07-161-0/+17
| | | | | | - No functionality change. llvm-svn: 76103
* Use size_t.Dan Gohman2009-07-162-13/+13
| | | | llvm-svn: 76069
* add a knob to turn off PrettyStackTrace globally. Patch by ZoltanChris Lattner2009-07-161-1/+6
| | | | | | Varga! llvm-svn: 75897
* Add registered target list to --version output.Daniel Dunbar2009-07-162-20/+39
| | | | llvm-svn: 75889
* Change raw_ostream so that it doesn't call llvm_report_errorDan Gohman2009-07-151-4/+14
| | | | | | | | | | | | | | | | | | immediately on every output error. Instead, add a flag to raw_ostream, and set the flag whenever an error is detected. The flag can be queried and cleared from the public API. This gives applications more flexibility to handling errors in application-specific ways. If the flag is not cleared when the raw_ostream is destructed, llvm_report_error is called from the destructor. This ensures that errors are not implicitly silenced, and provides convenient default behavior for tools like llc and opt. Clients wishing to avoid llvm_report_error calls from raw_ostream should check for errors and clear the error flag. llvm-svn: 75857
* Reapply TargetRegistry refactoring commits.Daniel Dunbar2009-07-151-7/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | --- Reverse-merging r75799 into '.': U test/Analysis/PointerTracking U include/llvm/Target/TargetMachineRegistry.h U include/llvm/Target/TargetMachine.h U include/llvm/Target/TargetRegistry.h U include/llvm/Target/TargetSelect.h U tools/lto/LTOCodeGenerator.cpp U tools/lto/LTOModule.cpp U tools/llc/llc.cpp U lib/Target/PowerPC/PPCTargetMachine.h U lib/Target/PowerPC/AsmPrinter/PPCAsmPrinter.cpp U lib/Target/PowerPC/PPCTargetMachine.cpp U lib/Target/PowerPC/PPC.h U lib/Target/ARM/ARMTargetMachine.cpp U lib/Target/ARM/AsmPrinter/ARMAsmPrinter.cpp U lib/Target/ARM/ARMTargetMachine.h U lib/Target/ARM/ARM.h U lib/Target/XCore/XCoreTargetMachine.cpp U lib/Target/XCore/XCoreTargetMachine.h U lib/Target/PIC16/PIC16TargetMachine.cpp U lib/Target/PIC16/PIC16TargetMachine.h U lib/Target/Alpha/AsmPrinter/AlphaAsmPrinter.cpp U lib/Target/Alpha/AlphaTargetMachine.cpp U lib/Target/Alpha/AlphaTargetMachine.h U lib/Target/X86/X86TargetMachine.h U lib/Target/X86/X86.h U lib/Target/X86/AsmPrinter/X86ATTAsmPrinter.h U lib/Target/X86/AsmPrinter/X86AsmPrinter.cpp U lib/Target/X86/AsmPrinter/X86IntelAsmPrinter.h U lib/Target/X86/X86TargetMachine.cpp U lib/Target/MSP430/MSP430TargetMachine.cpp U lib/Target/MSP430/MSP430TargetMachine.h U lib/Target/CppBackend/CPPTargetMachine.h U lib/Target/CppBackend/CPPBackend.cpp U lib/Target/CBackend/CTargetMachine.h U lib/Target/CBackend/CBackend.cpp U lib/Target/TargetMachine.cpp U lib/Target/IA64/IA64TargetMachine.cpp U lib/Target/IA64/AsmPrinter/IA64AsmPrinter.cpp U lib/Target/IA64/IA64TargetMachine.h U lib/Target/IA64/IA64.h U lib/Target/MSIL/MSILWriter.cpp U lib/Target/CellSPU/SPUTargetMachine.h U lib/Target/CellSPU/SPU.h U lib/Target/CellSPU/AsmPrinter/SPUAsmPrinter.cpp U lib/Target/CellSPU/SPUTargetMachine.cpp U lib/Target/Mips/AsmPrinter/MipsAsmPrinter.cpp U lib/Target/Mips/MipsTargetMachine.cpp U lib/Target/Mips/MipsTargetMachine.h U lib/Target/Mips/Mips.h U lib/Target/Sparc/AsmPrinter/SparcAsmPrinter.cpp U lib/Target/Sparc/SparcTargetMachine.cpp U lib/Target/Sparc/SparcTargetMachine.h U lib/ExecutionEngine/JIT/TargetSelect.cpp U lib/Support/TargetRegistry.cpp llvm-svn: 75820
OpenPOWER on IntegriCloud