LLVM  4.0.0
RuntimeLibcalls.h
Go to the documentation of this file.
1 //===-- CodeGen/RuntimeLibcalls.h - Runtime Library Calls -------*- C++ -*-===//
2 //
3 // The LLVM Compiler Infrastructure
4 //
5 // This file is distributed under the University of Illinois Open Source
6 // License. See LICENSE.TXT for details.
7 //
8 //===----------------------------------------------------------------------===//
9 //
10 // This file defines the enum representing the list of runtime library calls
11 // the backend may emit during code generation, and also some helper functions.
12 //
13 //===----------------------------------------------------------------------===//
14 
15 #ifndef LLVM_CODEGEN_RUNTIMELIBCALLS_H
16 #define LLVM_CODEGEN_RUNTIMELIBCALLS_H
17 
19 
20 namespace llvm {
21 namespace RTLIB {
22  /// RTLIB::Libcall enum - This enum defines all of the runtime library calls
23  /// the backend can emit. The various long double types cannot be merged,
24  /// because 80-bit library functions use "xf" and 128-bit use "tf".
25  ///
26  /// When adding PPCF128 functions here, note that their names generally need
27  /// to be overridden for Darwin with the xxx$LDBL128 form. See
28  /// PPCISelLowering.cpp.
29  ///
30  enum Libcall {
31  // Integer
84 
85  // FLOATING POINT
216 
217  // CONVERSION
296 
297  // COMPARISON
330 
331  // MEMORY
335 
336  // ELEMENT-WISE ATOMIC MEMORY
342 
343  // EXCEPTION HANDLING
345 
346  // Note: there's two sets of atomics libcalls; see
347  // <http://llvm.org/docs/Atomics.html> for more info on the
348  // difference between them.
349 
350  // Atomic '__sync_*' libcalls.
411 
412  // Atomic '__atomic_*' libcalls.
419 
426 
433 
440 
446 
452 
458 
464 
470 
476 
477  // Stack Protector Fail.
479 
480  // Deoptimization.
482 
484  };
485 
486  /// getFPEXT - Return the FPEXT_*_* value for the given types, or
487  /// UNKNOWN_LIBCALL if there is none.
488  Libcall getFPEXT(EVT OpVT, EVT RetVT);
489 
490  /// getFPROUND - Return the FPROUND_*_* value for the given types, or
491  /// UNKNOWN_LIBCALL if there is none.
492  Libcall getFPROUND(EVT OpVT, EVT RetVT);
493 
494  /// getFPTOSINT - Return the FPTOSINT_*_* value for the given types, or
495  /// UNKNOWN_LIBCALL if there is none.
496  Libcall getFPTOSINT(EVT OpVT, EVT RetVT);
497 
498  /// getFPTOUINT - Return the FPTOUINT_*_* value for the given types, or
499  /// UNKNOWN_LIBCALL if there is none.
500  Libcall getFPTOUINT(EVT OpVT, EVT RetVT);
501 
502  /// getSINTTOFP - Return the SINTTOFP_*_* value for the given types, or
503  /// UNKNOWN_LIBCALL if there is none.
504  Libcall getSINTTOFP(EVT OpVT, EVT RetVT);
505 
506  /// getUINTTOFP - Return the UINTTOFP_*_* value for the given types, or
507  /// UNKNOWN_LIBCALL if there is none.
508  Libcall getUINTTOFP(EVT OpVT, EVT RetVT);
509 
510  /// Return the SYNC_FETCH_AND_* value for the given opcode and type, or
511  /// UNKNOWN_LIBCALL if there is none.
512  Libcall getSYNC(unsigned Opc, MVT VT);
513 
514  /// getMEMCPY_ELEMENT_ATOMIC - Return MEMCPY_ELEMENT_ATOMIC_* value for the
515  /// given element size or UNKNOW_LIBCALL if there is none.
516  Libcall getMEMCPY_ELEMENT_ATOMIC(uint64_t ElementSize);
517 }
518 }
519 
520 #endif
Libcall getSYNC(unsigned Opc, MVT VT)
Return the SYNC_FETCH_AND_* value for the given opcode and type, or UNKNOWN_LIBCALL if there is none...
Libcall
RTLIB::Libcall enum - This enum defines all of the runtime library calls the backend can emit...
Libcall getFPROUND(EVT OpVT, EVT RetVT)
getFPROUND - Return the FPROUND_*_* value for the given types, or UNKNOWN_LIBCALL if there is none...
Libcall getUINTTOFP(EVT OpVT, EVT RetVT)
getUINTTOFP - Return the UINTTOFP_*_* value for the given types, or UNKNOWN_LIBCALL if there is none...
Libcall getMEMCPY_ELEMENT_ATOMIC(uint64_t ElementSize)
getMEMCPY_ELEMENT_ATOMIC - Return MEMCPY_ELEMENT_ATOMIC_* value for the given element size or UNKNOW_...
MVT - Machine Value Type.
Libcall getFPTOSINT(EVT OpVT, EVT RetVT)
getFPTOSINT - Return the FPTOSINT_*_* value for the given types, or UNKNOWN_LIBCALL if there is none...
EVT - Extended Value Type.
Definition: ValueTypes.h:31
Libcall getFPEXT(EVT OpVT, EVT RetVT)
getFPEXT - Return the FPEXT_*_* value for the given types, or UNKNOWN_LIBCALL if there is none...
Libcall getFPTOUINT(EVT OpVT, EVT RetVT)
getFPTOUINT - Return the FPTOUINT_*_* value for the given types, or UNKNOWN_LIBCALL if there is none...
Libcall getSINTTOFP(EVT OpVT, EVT RetVT)
getSINTTOFP - Return the SINTTOFP_*_* value for the given types, or UNKNOWN_LIBCALL if there is none...