forked from OSchip/llvm-project
parent
b792a01e13
commit
cf21875d41
llvm
docs
include/llvm/Support
lib
CodeGen/SelectionDAG
Support
Target/Hexagon
|
@ -487,7 +487,7 @@ into LLVM source tree. You can achieve it in two easy steps:
|
||||||
#. Adding ``add_subdirectory(<pass name>)`` line into
|
#. Adding ``add_subdirectory(<pass name>)`` line into
|
||||||
``<LLVM root>/lib/Transform/CMakeLists.txt``.
|
``<LLVM root>/lib/Transform/CMakeLists.txt``.
|
||||||
|
|
||||||
Compiler/Platform specific topics
|
Compiler/Platform-specific topics
|
||||||
=================================
|
=================================
|
||||||
|
|
||||||
Notes for specific compilers and/or platforms.
|
Notes for specific compilers and/or platforms.
|
||||||
|
|
|
@ -2027,7 +2027,7 @@ supported on x86/x86-64 and PowerPC. It is performed if:
|
||||||
|
|
||||||
* Option ``-tailcallopt`` is enabled.
|
* Option ``-tailcallopt`` is enabled.
|
||||||
|
|
||||||
* Platform specific constraints are met.
|
* Platform-specific constraints are met.
|
||||||
|
|
||||||
x86/x86-64 constraints:
|
x86/x86-64 constraints:
|
||||||
|
|
||||||
|
|
|
@ -633,7 +633,7 @@ Threaded
|
||||||
Denotes a multithreaded mutator; the collector must still stop the mutator
|
Denotes a multithreaded mutator; the collector must still stop the mutator
|
||||||
("stop the world") before beginning reachability analysis. Stopping a
|
("stop the world") before beginning reachability analysis. Stopping a
|
||||||
multithreaded mutator is a complicated problem. It generally requires highly
|
multithreaded mutator is a complicated problem. It generally requires highly
|
||||||
platform specific code in the runtime, and the production of carefully
|
platform-specific code in the runtime, and the production of carefully
|
||||||
designed machine code at safe points.
|
designed machine code at safe points.
|
||||||
|
|
||||||
Concurrent
|
Concurrent
|
||||||
|
|
|
@ -6408,7 +6408,7 @@ This instruction requires several arguments:
|
||||||
uses value of call or is void).
|
uses value of call or is void).
|
||||||
- Option ``-tailcallopt`` is enabled, or
|
- Option ``-tailcallopt`` is enabled, or
|
||||||
``llvm::GuaranteedTailCallOpt`` is ``true``.
|
``llvm::GuaranteedTailCallOpt`` is ``true``.
|
||||||
- `Platform specific constraints are
|
- `Platform-specific constraints are
|
||||||
met. <CodeGenerator.html#tailcallopt>`_
|
met. <CodeGenerator.html#tailcallopt>`_
|
||||||
|
|
||||||
#. The optional "cconv" marker indicates which :ref:`calling
|
#. The optional "cconv" marker indicates which :ref:`calling
|
||||||
|
|
|
@ -134,7 +134,7 @@ public:
|
||||||
};
|
};
|
||||||
|
|
||||||
/// file_status - Represents the result of a call to stat and friends. It has
|
/// file_status - Represents the result of a call to stat and friends. It has
|
||||||
/// a platform specific member to store the result.
|
/// a platform-specific member to store the result.
|
||||||
class file_status
|
class file_status
|
||||||
{
|
{
|
||||||
#if defined(LLVM_ON_UNIX)
|
#if defined(LLVM_ON_UNIX)
|
||||||
|
@ -273,7 +273,7 @@ private:
|
||||||
///
|
///
|
||||||
/// @param path A path that is modified to be an absolute path.
|
/// @param path A path that is modified to be an absolute path.
|
||||||
/// @returns errc::success if \a path has been made absolute, otherwise a
|
/// @returns errc::success if \a path has been made absolute, otherwise a
|
||||||
/// platform specific error_code.
|
/// platform-specific error_code.
|
||||||
std::error_code make_absolute(SmallVectorImpl<char> &path);
|
std::error_code make_absolute(SmallVectorImpl<char> &path);
|
||||||
|
|
||||||
/// @brief Normalize path separators in \a Path
|
/// @brief Normalize path separators in \a Path
|
||||||
|
@ -318,14 +318,14 @@ std::error_code create_link(const Twine &to, const Twine &from);
|
||||||
///
|
///
|
||||||
/// @param result Holds the current path on return.
|
/// @param result Holds the current path on return.
|
||||||
/// @returns errc::success if the current path has been stored in result,
|
/// @returns errc::success if the current path has been stored in result,
|
||||||
/// otherwise a platform specific error_code.
|
/// otherwise a platform-specific error_code.
|
||||||
std::error_code current_path(SmallVectorImpl<char> &result);
|
std::error_code current_path(SmallVectorImpl<char> &result);
|
||||||
|
|
||||||
/// @brief Remove path. Equivalent to POSIX remove().
|
/// @brief Remove path. Equivalent to POSIX remove().
|
||||||
///
|
///
|
||||||
/// @param path Input path.
|
/// @param path Input path.
|
||||||
/// @returns errc::success if path has been removed or didn't exist, otherwise a
|
/// @returns errc::success if path has been removed or didn't exist, otherwise a
|
||||||
/// platform specific error code. If IgnoreNonExisting is false, also
|
/// platform-specific error code. If IgnoreNonExisting is false, also
|
||||||
/// returns error if the file didn't exist.
|
/// returns error if the file didn't exist.
|
||||||
std::error_code remove(const Twine &path, bool IgnoreNonExisting = true);
|
std::error_code remove(const Twine &path, bool IgnoreNonExisting = true);
|
||||||
|
|
||||||
|
@ -346,7 +346,7 @@ std::error_code copy_file(const Twine &From, const Twine &To);
|
||||||
/// @param path Input path.
|
/// @param path Input path.
|
||||||
/// @param size Size to resize to.
|
/// @param size Size to resize to.
|
||||||
/// @returns errc::success if \a path has been resized to \a size, otherwise a
|
/// @returns errc::success if \a path has been resized to \a size, otherwise a
|
||||||
/// platform specific error_code.
|
/// platform-specific error_code.
|
||||||
std::error_code resize_file(const Twine &path, uint64_t size);
|
std::error_code resize_file(const Twine &path, uint64_t size);
|
||||||
|
|
||||||
/// @}
|
/// @}
|
||||||
|
@ -366,7 +366,7 @@ bool exists(file_status status);
|
||||||
/// @param result Set to true if the file represented by status exists, false if
|
/// @param result Set to true if the file represented by status exists, false if
|
||||||
/// it does not. Undefined otherwise.
|
/// it does not. Undefined otherwise.
|
||||||
/// @returns errc::success if result has been successfully set, otherwise a
|
/// @returns errc::success if result has been successfully set, otherwise a
|
||||||
/// platform specific error_code.
|
/// platform-specific error_code.
|
||||||
std::error_code exists(const Twine &path, bool &result);
|
std::error_code exists(const Twine &path, bool &result);
|
||||||
|
|
||||||
/// @brief Simpler version of exists for clients that don't need to
|
/// @brief Simpler version of exists for clients that don't need to
|
||||||
|
@ -408,7 +408,7 @@ bool equivalent(file_status A, file_status B);
|
||||||
/// @param result Set to true if stat(A) and stat(B) have the same device and
|
/// @param result Set to true if stat(A) and stat(B) have the same device and
|
||||||
/// inode (or equivalent).
|
/// inode (or equivalent).
|
||||||
/// @returns errc::success if result has been successfully set, otherwise a
|
/// @returns errc::success if result has been successfully set, otherwise a
|
||||||
/// platform specific error_code.
|
/// platform-specific error_code.
|
||||||
std::error_code equivalent(const Twine &A, const Twine &B, bool &result);
|
std::error_code equivalent(const Twine &A, const Twine &B, bool &result);
|
||||||
|
|
||||||
/// @brief Simpler version of equivalent for clients that don't need to
|
/// @brief Simpler version of equivalent for clients that don't need to
|
||||||
|
@ -430,7 +430,7 @@ bool is_directory(file_status status);
|
||||||
/// @param result Set to true if \a path is a directory, false if it is not.
|
/// @param result Set to true if \a path is a directory, false if it is not.
|
||||||
/// Undefined otherwise.
|
/// Undefined otherwise.
|
||||||
/// @returns errc::success if result has been successfully set, otherwise a
|
/// @returns errc::success if result has been successfully set, otherwise a
|
||||||
/// platform specific error_code.
|
/// platform-specific error_code.
|
||||||
std::error_code is_directory(const Twine &path, bool &result);
|
std::error_code is_directory(const Twine &path, bool &result);
|
||||||
|
|
||||||
/// @brief Simpler version of is_directory for clients that don't need to
|
/// @brief Simpler version of is_directory for clients that don't need to
|
||||||
|
@ -452,7 +452,7 @@ bool is_regular_file(file_status status);
|
||||||
/// @param result Set to true if \a path is a regular file, false if it is not.
|
/// @param result Set to true if \a path is a regular file, false if it is not.
|
||||||
/// Undefined otherwise.
|
/// Undefined otherwise.
|
||||||
/// @returns errc::success if result has been successfully set, otherwise a
|
/// @returns errc::success if result has been successfully set, otherwise a
|
||||||
/// platform specific error_code.
|
/// platform-specific error_code.
|
||||||
std::error_code is_regular_file(const Twine &path, bool &result);
|
std::error_code is_regular_file(const Twine &path, bool &result);
|
||||||
|
|
||||||
/// @brief Simpler version of is_regular_file for clients that don't need to
|
/// @brief Simpler version of is_regular_file for clients that don't need to
|
||||||
|
@ -478,7 +478,7 @@ bool is_other(file_status status);
|
||||||
/// @param result Set to true if \a path exists, but is not a directory, regular
|
/// @param result Set to true if \a path exists, but is not a directory, regular
|
||||||
/// file, or a symlink, false if it does not. Undefined otherwise.
|
/// file, or a symlink, false if it does not. Undefined otherwise.
|
||||||
/// @returns errc::success if result has been successfully set, otherwise a
|
/// @returns errc::success if result has been successfully set, otherwise a
|
||||||
/// platform specific error_code.
|
/// platform-specific error_code.
|
||||||
std::error_code is_other(const Twine &path, bool &result);
|
std::error_code is_other(const Twine &path, bool &result);
|
||||||
|
|
||||||
/// @brief Get file status as if by POSIX stat().
|
/// @brief Get file status as if by POSIX stat().
|
||||||
|
@ -486,7 +486,7 @@ std::error_code is_other(const Twine &path, bool &result);
|
||||||
/// @param path Input path.
|
/// @param path Input path.
|
||||||
/// @param result Set to the file status.
|
/// @param result Set to the file status.
|
||||||
/// @returns errc::success if result has been successfully set, otherwise a
|
/// @returns errc::success if result has been successfully set, otherwise a
|
||||||
/// platform specific error_code.
|
/// platform-specific error_code.
|
||||||
std::error_code status(const Twine &path, file_status &result);
|
std::error_code status(const Twine &path, file_status &result);
|
||||||
|
|
||||||
/// @brief A version for when a file descriptor is already available.
|
/// @brief A version for when a file descriptor is already available.
|
||||||
|
@ -497,7 +497,7 @@ std::error_code status(int FD, file_status &Result);
|
||||||
/// @param Path Input path.
|
/// @param Path Input path.
|
||||||
/// @param Result Set to the size of the file in \a Path.
|
/// @param Result Set to the size of the file in \a Path.
|
||||||
/// @returns errc::success if result has been successfully set, otherwise a
|
/// @returns errc::success if result has been successfully set, otherwise a
|
||||||
/// platform specific error_code.
|
/// platform-specific error_code.
|
||||||
inline std::error_code file_size(const Twine &Path, uint64_t &Result) {
|
inline std::error_code file_size(const Twine &Path, uint64_t &Result) {
|
||||||
file_status Status;
|
file_status Status;
|
||||||
std::error_code EC = status(Path, Status);
|
std::error_code EC = status(Path, Status);
|
||||||
|
@ -510,7 +510,7 @@ inline std::error_code file_size(const Twine &Path, uint64_t &Result) {
|
||||||
/// @brief Set the file modification and access time.
|
/// @brief Set the file modification and access time.
|
||||||
///
|
///
|
||||||
/// @returns errc::success if the file times were successfully set, otherwise a
|
/// @returns errc::success if the file times were successfully set, otherwise a
|
||||||
/// platform specific error_code or errc::function_not_supported on
|
/// platform-specific error_code or errc::function_not_supported on
|
||||||
/// platforms where the functionality isn't available.
|
/// platforms where the functionality isn't available.
|
||||||
std::error_code setLastModificationAndAccessTime(int FD, TimeValue Time);
|
std::error_code setLastModificationAndAccessTime(int FD, TimeValue Time);
|
||||||
|
|
||||||
|
@ -525,7 +525,7 @@ bool status_known(file_status s);
|
||||||
/// @param path Input path.
|
/// @param path Input path.
|
||||||
/// @param result Set to true if status() != status_error.
|
/// @param result Set to true if status() != status_error.
|
||||||
/// @returns errc::success if result has been successfully set, otherwise a
|
/// @returns errc::success if result has been successfully set, otherwise a
|
||||||
/// platform specific error_code.
|
/// platform-specific error_code.
|
||||||
std::error_code status_known(const Twine &path, bool &result);
|
std::error_code status_known(const Twine &path, bool &result);
|
||||||
|
|
||||||
/// @brief Create a uniquely named file.
|
/// @brief Create a uniquely named file.
|
||||||
|
@ -548,7 +548,7 @@ std::error_code status_known(const Twine &path, bool &result);
|
||||||
/// @param ResultFD Set to the opened file's file descriptor.
|
/// @param ResultFD Set to the opened file's file descriptor.
|
||||||
/// @param ResultPath Set to the opened file's absolute path.
|
/// @param ResultPath Set to the opened file's absolute path.
|
||||||
/// @returns errc::success if Result{FD,Path} have been successfully set,
|
/// @returns errc::success if Result{FD,Path} have been successfully set,
|
||||||
/// otherwise a platform specific error_code.
|
/// otherwise a platform-specific error_code.
|
||||||
std::error_code createUniqueFile(const Twine &Model, int &ResultFD,
|
std::error_code createUniqueFile(const Twine &Model, int &ResultFD,
|
||||||
SmallVectorImpl<char> &ResultPath,
|
SmallVectorImpl<char> &ResultPath,
|
||||||
unsigned Mode = all_read | all_write);
|
unsigned Mode = all_read | all_write);
|
||||||
|
@ -618,7 +618,7 @@ file_magic identify_magic(StringRef magic);
|
||||||
/// @param path Input path.
|
/// @param path Input path.
|
||||||
/// @param result Set to the type of file, or file_magic::unknown.
|
/// @param result Set to the type of file, or file_magic::unknown.
|
||||||
/// @returns errc::success if result has been successfully set, otherwise a
|
/// @returns errc::success if result has been successfully set, otherwise a
|
||||||
/// platform specific error_code.
|
/// platform-specific error_code.
|
||||||
std::error_code identify_magic(const Twine &path, file_magic &result);
|
std::error_code identify_magic(const Twine &path, file_magic &result);
|
||||||
|
|
||||||
std::error_code getUniqueID(const Twine Path, UniqueID &Result);
|
std::error_code getUniqueID(const Twine Path, UniqueID &Result);
|
||||||
|
@ -638,7 +638,7 @@ public:
|
||||||
};
|
};
|
||||||
|
|
||||||
private:
|
private:
|
||||||
/// Platform specific mapping state.
|
/// Platform-specific mapping state.
|
||||||
mapmode Mode;
|
mapmode Mode;
|
||||||
uint64_t Size;
|
uint64_t Size;
|
||||||
void *Mapping;
|
void *Mapping;
|
||||||
|
|
|
@ -442,7 +442,7 @@ signed ResourcePriorityQueue::SUSchedulingCost(SUnit *SU) {
|
||||||
ResCount -= (regPressureDelta(SU) * ScaleTwo);
|
ResCount -= (regPressureDelta(SU) * ScaleTwo);
|
||||||
}
|
}
|
||||||
|
|
||||||
// These are platform specific things.
|
// These are platform-specific things.
|
||||||
// Will need to go into the back end
|
// Will need to go into the back end
|
||||||
// and accessed from here via a hook.
|
// and accessed from here via a hook.
|
||||||
for (SDNode *N = SU->getNode(); N; N = N->getGluedNode()) {
|
for (SDNode *N = SU->getNode(); N; N = N->getGluedNode()) {
|
||||||
|
|
|
@ -320,7 +320,7 @@ private:
|
||||||
/// 1. Preserve the architecture independence of stack protector generation.
|
/// 1. Preserve the architecture independence of stack protector generation.
|
||||||
///
|
///
|
||||||
/// 2. Preserve the normal IR level stack protector check for platforms like
|
/// 2. Preserve the normal IR level stack protector check for platforms like
|
||||||
/// OpenBSD for which we support platform specific stack protector
|
/// OpenBSD for which we support platform-specific stack protector
|
||||||
/// generation.
|
/// generation.
|
||||||
///
|
///
|
||||||
/// The main problem that guided the present solution is that one can not
|
/// The main problem that guided the present solution is that one can not
|
||||||
|
@ -338,7 +338,7 @@ private:
|
||||||
/// basic block (where the return inst is placed) and then move it back
|
/// basic block (where the return inst is placed) and then move it back
|
||||||
/// later at SelectionDAG/MI time before the stack protector check if the
|
/// later at SelectionDAG/MI time before the stack protector check if the
|
||||||
/// tail call optimization failed. The MI level option was nixed
|
/// tail call optimization failed. The MI level option was nixed
|
||||||
/// immediately since it would require platform specific pattern
|
/// immediately since it would require platform-specific pattern
|
||||||
/// matching. The SelectionDAG level option was nixed because
|
/// matching. The SelectionDAG level option was nixed because
|
||||||
/// SelectionDAG only processes one IR level basic block at a time
|
/// SelectionDAG only processes one IR level basic block at a time
|
||||||
/// implying one could not create a DAG Combine to move the callinst.
|
/// implying one could not create a DAG Combine to move the callinst.
|
||||||
|
|
|
@ -53,7 +53,7 @@ TimeValue::normalize( void ) {
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/// Include the platform specific portion of TimeValue class
|
/// Include the platform-specific portion of TimeValue class
|
||||||
#ifdef LLVM_ON_UNIX
|
#ifdef LLVM_ON_UNIX
|
||||||
#include "Unix/TimeValue.inc"
|
#include "Unix/TimeValue.inc"
|
||||||
#endif
|
#endif
|
||||||
|
|
|
@ -20,7 +20,7 @@ using namespace llvm;
|
||||||
|
|
||||||
#define DEBUG_TYPE "misched"
|
#define DEBUG_TYPE "misched"
|
||||||
|
|
||||||
/// Platform specific modifications to DAG.
|
/// Platform-specific modifications to DAG.
|
||||||
void VLIWMachineScheduler::postprocessDAG() {
|
void VLIWMachineScheduler::postprocessDAG() {
|
||||||
SUnit* LastSequentialCall = nullptr;
|
SUnit* LastSequentialCall = nullptr;
|
||||||
// Currently we only catch the situation when compare gets scheduled
|
// Currently we only catch the situation when compare gets scheduled
|
||||||
|
@ -150,7 +150,7 @@ void VLIWMachineScheduler::schedule() {
|
||||||
|
|
||||||
buildDAGWithRegPressure();
|
buildDAGWithRegPressure();
|
||||||
|
|
||||||
// Postprocess the DAG to add platform specific artificial dependencies.
|
// Postprocess the DAG to add platform-specific artificial dependencies.
|
||||||
postprocessDAG();
|
postprocessDAG();
|
||||||
|
|
||||||
SmallVector<SUnit*, 8> TopRoots, BotRoots;
|
SmallVector<SUnit*, 8> TopRoots, BotRoots;
|
||||||
|
|
|
@ -100,7 +100,7 @@ public:
|
||||||
/// Schedule - This is called back from ScheduleDAGInstrs::Run() when it's
|
/// Schedule - This is called back from ScheduleDAGInstrs::Run() when it's
|
||||||
/// time to do some work.
|
/// time to do some work.
|
||||||
virtual void schedule() override;
|
virtual void schedule() override;
|
||||||
/// Perform platform specific DAG postprocessing.
|
/// Perform platform-specific DAG postprocessing.
|
||||||
void postprocessDAG();
|
void postprocessDAG();
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue