llvm/lib/Support
Ed Maste 944d939ce1 Fix detection of backtrace() availability on FreeBSD
On FreeBSD backtrace is not part of libc and depends on libexecinfo
being available. Instead of using manual checks we can use the builtin
CMake module FindBacktrace.cmake to detect availability of backtrace()
in a portable way.

Patch By:	Alex Richardson
Differential Revision:	https://reviews.llvm.org/D27143


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@300062 91177308-0d34-0410-b5e6-96231b3b80d8
2017-04-12 13:51:00 +00:00
..
Unix Fix detection of backtrace() availability on FreeBSD 2017-04-12 13:51:00 +00:00
Windows Remove name space pollution from Signals.cpp 2017-03-31 14:58:52 +00:00
Allocator.cpp
APFloat.cpp [APInt] Add a public typedef for the internal type of APInt use it instead of integerPart. Make APINT_BITS_PER_WORD and APINT_WORD_SIZE public. 2017-04-02 19:17:22 +00:00
APInt.cpp [APInt] Make use of whichWord and maskBit to simplify some code. NFC 2017-04-02 19:35:18 +00:00
APSInt.cpp
ARMAttributeParser.cpp
ARMBuildAttrs.cpp
ARMWinEH.cpp
Atomic.cpp
BinaryStreamError.cpp [Support] Move Stream library from MSF -> Support. 2017-03-02 20:52:51 +00:00
BinaryStreamReader.cpp [Support] Move Stream library from MSF -> Support. 2017-03-02 20:52:51 +00:00
BinaryStreamWriter.cpp [pdb] Write the module info and symbol record streams. 2017-03-15 22:18:53 +00:00
BlockFrequency.cpp
BranchProbability.cpp
CachePruning.cpp Support, LTO: When pruning a directory, ignore files matching a prefix. 2017-03-20 16:41:57 +00:00
Chrono.cpp Make naming in Host.h in line with coding standards. 2017-03-31 13:06:40 +00:00
circular_raw_ostream.cpp
CMakeLists.txt Fix detection of backtrace() availability on FreeBSD 2017-04-12 13:51:00 +00:00
COM.cpp
CommandLine.cpp Correct OptionCategoryCompare() in the command line library. 2017-03-27 13:43:24 +00:00
Compression.cpp
ConvertUTF.cpp
ConvertUTFWrapper.cpp
COPYRIGHT.regex
CrashRecoveryContext.cpp
DAGDeltaAlgorithm.cpp
DataExtractor.cpp
Debug.cpp
DebugCounter.cpp DebugCounter: Initialize skip to 0, not -1 2017-03-04 14:08:47 +00:00
DeltaAlgorithm.cpp
Dwarf.cpp [DWARFv5] Emit new unit header format. 2017-02-28 20:24:55 +00:00
DynamicLibrary.cpp Reland r296442 with modifications reverted in r296463. 2017-03-02 17:56:45 +00:00
Errno.cpp
Error.cpp
ErrorHandling.cpp
FileOutputBuffer.cpp Make FileOutputBuffer fail early if you pass a directory. 2017-03-13 22:19:05 +00:00
FileUtilities.cpp
FoldingSet.cpp
FormattedStream.cpp
FormatVariadic.cpp
GlobPattern.cpp
GraphWriter.cpp
Hashing.cpp
Host.cpp Remove xgene1 from host detection 2017-04-11 22:39:55 +00:00
IntEqClasses.cpp
IntervalMap.cpp
JamCRC.cpp
LEB128.cpp
LineIterator.cpp
LLVMBuild.txt
Locale.cpp
LockFileManager.cpp [LockFileManager] Reduce lock timeout 2017-03-18 00:32:34 +00:00
LowLevelType.cpp Recommit: [globalisel] Change LLT constructor string into an LLT-based object that knows how to generate it. 2017-03-07 23:20:35 +00:00
ManagedStatic.cpp
MathExtras.cpp
MD5.cpp Add a function to MD5 a file's contents. 2017-03-20 23:33:18 +00:00
Memory.cpp
MemoryBuffer.cpp [Support] Add a function to check if a file resides locally. 2017-02-21 20:55:47 +00:00
Mutex.cpp
NativeFormatting.cpp
Options.cpp
Path.cpp Add a function to MD5 a file's contents. 2017-03-20 23:33:18 +00:00
PluginLoader.cpp
PrettyStackTrace.cpp
Process.cpp
Program.cpp
RandomNumberGenerator.cpp
raw_os_ostream.cpp
raw_ostream.cpp Update comment for r299098 per feedback from James Henderson. 2017-03-31 12:08:45 +00:00
README.txt.system
regcclass.h
regcname.h
regcomp.c
regengine.inc
regerror.c
regex2.h
regex_impl.h
Regex.cpp
regexec.c
regfree.c
regstrlcpy.c
regutils.h
RWMutex.cpp [Support] Fix some Clang-tidy modernize and Include What You Use warnings; other minor fixes (NFC). 2017-02-15 22:17:02 +00:00
ScaledNumber.cpp
ScopedPrinter.cpp
SearchForAddressOfSpecialSymbol.cpp
SHA1.cpp
Signals.cpp Remove name space pollution from Signals.cpp 2017-03-31 14:58:52 +00:00
SmallPtrSet.cpp
SmallVector.cpp
SourceMgr.cpp [Support] Fix some Clang-tidy modernize and Include What You Use warnings; other minor fixes (NFC). 2017-02-15 22:17:02 +00:00
SpecialCaseList.cpp
Statistic.cpp
StringExtras.cpp
StringMap.cpp
StringPool.cpp
StringRef.cpp [Support] Add StringRef::getAsDouble. 2017-02-14 19:06:37 +00:00
StringSaver.cpp
SystemUtils.cpp
TargetParser.cpp [AArch64] Add Cavium ThunderX support 2017-02-17 18:34:24 +00:00
TargetRegistry.cpp
TarWriter.cpp
Threading.cpp Try to fix thread name truncation on non-Windows. 2017-03-04 18:53:09 +00:00
ThreadLocal.cpp
ThreadPool.cpp
Timer.cpp Change default TimerGroup singleton to use magic statics 2017-02-16 20:19:49 +00:00
ToolOutputFile.cpp
TrigramIndex.cpp
Triple.cpp Set default CPU for OpenBSD/arm to Cortex-A8 2017-02-28 17:28:35 +00:00
Twine.cpp
Unicode.cpp
Valgrind.cpp
Watchdog.cpp
xxhash.cpp
YAMLParser.cpp
YAMLTraits.cpp [YAML] When outputting, provide the ability to write default values. 2017-03-15 17:47:39 +00:00

Design Of lib/System
====================

The software in this directory is designed to completely shield LLVM from any
and all operating system specific functionality. It is not intended to be a
complete operating system wrapper (such as ACE), but only to provide the
functionality necessary to support LLVM.

The software located here, of necessity, has very specific and stringent design
rules. Violation of these rules means that cracks in the shield could form and
the primary goal of the library is defeated. By consistently using this library,
LLVM becomes more easily ported to new platforms since the only thing requiring
porting is this library.

Complete documentation for the library can be found in the file:
  llvm/docs/SystemLibrary.html
or at this URL:
  http://llvm.org/docs/SystemLibrary.html

While we recommend that you read the more detailed documentation, for the
impatient, here's a high level summary of the library's requirements.

 1. No system header files are to be exposed through the interface.
 2. Std C++ and Std C header files are okay to be exposed through the interface.
 3. No exposed system-specific functions.
 4. No exposed system-specific data.
 5. Data in lib/System classes must use only simple C++ intrinsic types.
 6. Errors are handled by returning "true" and setting an optional std::string
 7. Library must not throw any exceptions, period.
 8. Interface functions must not have throw() specifications.
 9. No duplicate function impementations are permitted within an operating
    system class.

To accomplish these requirements, the library has numerous design criteria that
must be satisfied. Here's a high level summary of the library's design criteria:

 1. No unused functionality (only what LLVM needs)
 2. High-Level Interfaces
 3. Use Opaque Classes
 4. Common Implementations
 5. Multiple Implementations
 6. Minimize Memory Allocation
 7. No Virtual Methods