[Flang][NFC] Move runtime library files to flang-rt (#110298)

Mostly mechanical changes in preparation of extracting the Flang-RT
"subproject" in #110217. This PR intends to only move pre-existing files
to the new folder structure, with no behavioral change. Common files
(headers, testing, cmake) shared by Flang-RT and Flang remain in
`flang/`.

Some cosmetic changes and files paths were necessary:
* Relative paths to the new path for the source files and
`add_subdirectory`.
 * Add the new location's include directory to `include_directories`
* The unittest/Evaluate directory has unitests for flang-rt and Flang. A
new `CMakeLists.txt` was introduced for the flang-rt tests.
 * Change the `#include` paths relative to the include directive
 * clang-format on the `#include` directives
* Since the paths are part if the copyright header and include guards, a
script was used to canonicalize those
* `test/Runtime` and runtime tests in `test/Driver` are moved, but the
lit.cfg.py mechanism to execute the will only be added in #110217.
This commit is contained in:
Michael Kruse 2025-02-16 13:25:31 +01:00 committed by GitHub
parent 29f3a35206
commit 54f37133b7
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
220 changed files with 824 additions and 725 deletions

25
flang-rt/.clang-format Normal file
View File

@ -0,0 +1,25 @@
---
# See: https://clang.llvm.org/docs/ClangFormatStyleOptions.html
BasedOnStyle: LLVM
AlignAfterOpenBracket: DontAlign
AlignEscapedNewlines: DontAlign
AlignConsecutiveAssignments: false
AlignConsecutiveDeclarations: false
AlignOperands: false
AlignTrailingComments: false
IncludeCategories:
- Regex: '^<'
Priority: 6
- Regex: '^"(llvm|llvm-c|clang|clang-c)/'
Priority: 5
- Regex: '^"flang/' # Headers shared with Flang
Priority: 4
- Regex: '^"flang-rt/' # Public Flang-RT headers
Priority: 3
- Regex: '^[^/]*$' # Private headers from same library
Priority: 1
- Regex: '.*' # Private headers from sibling libraries
Priority: 2
...
# vim:set filetype=yaml:

View File

@ -0,0 +1,19 @@
/*===-- cmake/config.cmake.in ---------------------------------------*- C -*-===
*
* Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
* See https://llvm.org/LICENSE.txt for license information.
* SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
*
*===----------------------------------------------------------------------===*/
#ifndef FORTRAN_RUNTIME_CONFIG_H
#define FORTRAN_RUNTIME_CONFIG_H
/* Define to 1 if you have the `strerror_r' function. */
#cmakedefine01 HAVE_STRERROR_R
/* Define to 1 if you have the declaration of `strerror_s', and to 0 if you
don't. */
#cmakedefine01 HAVE_DECL_STRERROR_S
#endif

View File

@ -1,3 +1,11 @@
//===-- examples/ExternalHelloWorld/external-hello.cpp ----------*- C++ -*-===//
//
// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
// See https://llvm.org/LICENSE.txt for license information.
// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
//
//===----------------------------------------------------------------------===//
#include "flang/Runtime/io-api.h"
#include "flang/Runtime/main.h"
#include "flang/Runtime/stop.h"

View File

@ -1,4 +1,4 @@
//===-- runtime/allocator-registry.h ----------------------------*- C++ -*-===//
//===-- include/flang-rt/runtime/allocator-registry.h -----------*- C++ -*-===//
//
// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
// See https://llvm.org/LICENSE.txt for license information.
@ -6,8 +6,8 @@
//
//===----------------------------------------------------------------------===//
#ifndef FORTRAN_RUNTIME_ALLOCATOR_REGISTRY_H_
#define FORTRAN_RUNTIME_ALLOCATOR_REGISTRY_H_
#ifndef FLANG_RT_RUNTIME_ALLOCATOR_REGISTRY_H_
#define FLANG_RT_RUNTIME_ALLOCATOR_REGISTRY_H_
#include "flang/Common/api-attrs.h"
#include "flang/Runtime/allocator-registry-consts.h"
@ -55,4 +55,4 @@ RT_OFFLOAD_VAR_GROUP_END
} // namespace Fortran::runtime
#endif // FORTRAN_RUNTIME_ALLOCATOR_REGISTRY_H_
#endif // FLANG_RT_RUNTIME_ALLOCATOR_REGISTRY_H_

View File

@ -1,4 +1,4 @@
//===-- include/flang/Runtime/array-constructor.h ---------------*- C++ -*-===//
//===-- include/flang-rt/runtime/array-constructor.h ------------*- C++ -*-===//
//
// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
// See https://llvm.org/LICENSE.txt for license information.
@ -9,11 +9,11 @@
// External APIs to create temporary storage for array constructors when their
// final extents or length parameters cannot be pre-computed.
#ifndef FORTRAN_RUNTIME_ARRAYCONSTRUCTOR_H_
#define FORTRAN_RUNTIME_ARRAYCONSTRUCTOR_H_
#ifndef FLANG_RT_RUNTIME_ARRAY_CONSTRUCTOR_H_
#define FLANG_RT_RUNTIME_ARRAY_CONSTRUCTOR_H_
#include "descriptor.h"
#include "flang/Runtime/array-constructor-consts.h"
#include "flang/Runtime/descriptor.h"
#include "flang/Runtime/entry-names.h"
#include <cstdint>
@ -54,4 +54,4 @@ static_assert(alignof(Fortran::runtime::ArrayConstructorVector) <=
"MaxArrayConstructorVectorAlignInBytes");
} // namespace Fortran::runtime
#endif // FORTRAN_RUNTIME_ARRAYCONSTRUCTOR_H_
#endif // FLANG_RT_RUNTIME_ARRAY_CONSTRUCTOR_H_

View File

@ -1,4 +1,4 @@
//===-- runtime/assign-impl.h -----------------------------------*- C++ -*-===//
//===-- include/flang-rt/runtime/assign-impl.h ------------------*- C++ -*-===//
//
// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
// See https://llvm.org/LICENSE.txt for license information.
@ -6,8 +6,8 @@
//
//===----------------------------------------------------------------------===//
#ifndef FORTRAN_RUNTIME_ASSIGN_IMPL_H_
#define FORTRAN_RUNTIME_ASSIGN_IMPL_H_
#ifndef FLANG_RT_RUNTIME_ASSIGN_IMPL_H_
#define FLANG_RT_RUNTIME_ASSIGN_IMPL_H_
#include "flang/Runtime/freestanding-tools.h"
@ -28,4 +28,4 @@ RT_API_ATTRS void DoFromSourceAssign(Descriptor &, const Descriptor &,
#endif
} // namespace Fortran::runtime
#endif // FORTRAN_RUNTIME_ASSIGN_IMPL_H_
#endif // FLANG_RT_RUNTIME_ASSIGN_IMPL_H_

View File

@ -1,4 +1,4 @@
//===-- runtime/buffer.h ----------------------------------------*- C++ -*-===//
//===-- include/flang-rt/runtime/buffer.h -----------------------*- C++ -*-===//
//
// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
// See https://llvm.org/LICENSE.txt for license information.
@ -8,12 +8,12 @@
// External file buffering
#ifndef FORTRAN_RUNTIME_BUFFER_H_
#define FORTRAN_RUNTIME_BUFFER_H_
#ifndef FLANG_RT_RUNTIME_BUFFER_H_
#define FLANG_RT_RUNTIME_BUFFER_H_
#include "io-error.h"
#include "memory.h"
#include "flang/Runtime/freestanding-tools.h"
#include "flang/Runtime/memory.h"
#include <algorithm>
#include <cinttypes>
#include <cstring>
@ -221,4 +221,4 @@ private:
bool dirty_{false};
};
} // namespace Fortran::runtime::io
#endif // FORTRAN_RUNTIME_BUFFER_H_
#endif // FLANG_RT_RUNTIME_BUFFER_H_

View File

@ -1,4 +1,4 @@
//===-- runtime/connection.h ------------------------------------*- C++ -*-===//
//===-- include/flang-rt/runtime/connection.h -------------------*- C++ -*-===//
//
// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
// See https://llvm.org/LICENSE.txt for license information.
@ -8,8 +8,8 @@
// Fortran I/O connection state (abstracted over internal & external units)
#ifndef FORTRAN_RUNTIME_IO_CONNECTION_H_
#define FORTRAN_RUNTIME_IO_CONNECTION_H_
#ifndef FLANG_RT_RUNTIME_CONNECTION_H_
#define FLANG_RT_RUNTIME_CONNECTION_H_
#include "format.h"
#include "flang/Common/optional.h"
@ -124,4 +124,4 @@ private:
};
} // namespace Fortran::runtime::io
#endif // FORTRAN_RUNTIME_IO_CONNECTION_H_
#endif // FLANG_RT_RUNTIME_CONNECTION_H_

View File

@ -1,4 +1,4 @@
//===-- runtime/derived.h -------------------------------------------------===//
//===-- include/flang-rt/runtime/derived.h ----------------------*- C++ -*-===//
//
// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
// See https://llvm.org/LICENSE.txt for license information.
@ -8,8 +8,8 @@
// Internal runtime utilities for derived type operations.
#ifndef FORTRAN_RUNTIME_DERIVED_H_
#define FORTRAN_RUNTIME_DERIVED_H_
#ifndef FLANG_RT_RUNTIME_DERIVED_H_
#define FLANG_RT_RUNTIME_DERIVED_H_
#include "flang/Common/api-attrs.h"
@ -48,4 +48,4 @@ RT_API_ATTRS void Destroy(const Descriptor &, bool finalize,
RT_API_ATTRS bool HasDynamicComponent(const Descriptor &);
} // namespace Fortran::runtime
#endif // FORTRAN_RUNTIME_DERIVED_H_
#endif // FLANG_RT_RUNTIME_DERIVED_H_

View File

@ -1,4 +1,4 @@
//===-- include/flang/Runtime/descriptor.h ----------------------*- C++ -*-===//
//===-- include/flang-rt/runtime/descriptor.h -------------------*- C++ -*-===//
//
// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
// See https://llvm.org/LICENSE.txt for license information.
@ -6,8 +6,8 @@
//
//===----------------------------------------------------------------------===//
#ifndef FORTRAN_RUNTIME_DESCRIPTOR_H_
#define FORTRAN_RUNTIME_DESCRIPTOR_H_
#ifndef FLANG_RT_RUNTIME_DESCRIPTOR_H_
#define FLANG_RT_RUNTIME_DESCRIPTOR_H_
// Defines data structures used during execution of a Fortran program
// to implement nontrivial dummy arguments, pointers, allocatables,
@ -18,10 +18,10 @@
// User C code is welcome to depend on that ISO_Fortran_binding.h file,
// but should never reference this internal header.
#include "memory.h"
#include "type-code.h"
#include "flang/Common/ISO_Fortran_binding_wrapper.h"
#include "flang/Runtime/descriptor-consts.h"
#include "flang/Runtime/memory.h"
#include "flang/Runtime/type-code.h"
#include <algorithm>
#include <cassert>
#include <cinttypes>
@ -482,4 +482,4 @@ private:
};
} // namespace Fortran::runtime
#endif // FORTRAN_RUNTIME_DESCRIPTOR_H_
#endif // FLANG_RT_RUNTIME_DESCRIPTOR_H_

View File

@ -1,4 +1,4 @@
//===-- runtime/emit-encoded.h ----------------------------------*- C++ -*-===//
//===-- include/flang-rt/runtime/emit-encoded.h -----------------*- C++ -*-===//
//
// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
// See https://llvm.org/LICENSE.txt for license information.
@ -8,8 +8,8 @@
// Templates for emitting CHARACTER values with conversion
#ifndef FORTRAN_RUNTIME_EMIT_ENCODED_H_
#define FORTRAN_RUNTIME_EMIT_ENCODED_H_
#ifndef FLANG_RT_RUNTIME_EMIT_ENCODED_H_
#define FLANG_RT_RUNTIME_EMIT_ENCODED_H_
#include "connection.h"
#include "environment.h"
@ -114,4 +114,4 @@ RT_API_ATTRS bool EmitRepeated(CONTEXT &to, char ch, std::size_t n) {
}
} // namespace Fortran::runtime::io
#endif // FORTRAN_RUNTIME_EMIT_ENCODED_H_
#endif // FLANG_RT_RUNTIME_EMIT_ENCODED_H_

View File

@ -1,4 +1,4 @@
//===-- runtime/environment.h -----------------------------------*- C++ -*-===//
//===-- include/flang-rt/runtime/environment.h ------------------*- C++ -*-===//
//
// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
// See https://llvm.org/LICENSE.txt for license information.
@ -6,8 +6,8 @@
//
//===----------------------------------------------------------------------===//
#ifndef FORTRAN_RUNTIME_ENVIRONMENT_H_
#define FORTRAN_RUNTIME_ENVIRONMENT_H_
#ifndef FLANG_RT_RUNTIME_ENVIRONMENT_H_
#define FLANG_RT_RUNTIME_ENVIRONMENT_H_
#include "flang/Common/optional.h"
#include "flang/Decimal/decimal.h"
@ -67,4 +67,4 @@ RT_OFFLOAD_VAR_GROUP_END
} // namespace Fortran::runtime
#endif // FORTRAN_RUNTIME_ENVIRONMENT_H_
#endif // FLANG_RT_RUNTIME_ENVIRONMENT_H_

View File

@ -1,4 +1,4 @@
//===-- runtime/file.h ------------------------------------------*- C++ -*-===//
//===-- include/flang-rt/runtime/file.h -------------------------*- C++ -*-===//
//
// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
// See https://llvm.org/LICENSE.txt for license information.
@ -8,12 +8,12 @@
// Raw system I/O wrappers
#ifndef FORTRAN_RUNTIME_FILE_H_
#define FORTRAN_RUNTIME_FILE_H_
#ifndef FLANG_RT_RUNTIME_FILE_H_
#define FLANG_RT_RUNTIME_FILE_H_
#include "io-error.h"
#include "memory.h"
#include "flang/Common/optional.h"
#include "flang/Runtime/memory.h"
#include <cinttypes>
namespace Fortran::runtime::io {
@ -113,4 +113,4 @@ RT_API_ATTRS bool MayWrite(const char *path);
RT_API_ATTRS bool MayReadAndWrite(const char *path);
RT_API_ATTRS std::int64_t SizeInBytes(const char *path);
} // namespace Fortran::runtime::io
#endif // FORTRAN_RUNTIME_FILE_H_
#endif // FLANG_RT_RUNTIME_FILE_H_

View File

@ -1,4 +1,4 @@
//===-- runtime/format-implementation.h -------------------------*- C++ -*-===//
//===-- include/flang-rt/runtime/format-implementation.h --------*- C++ -*-===//
//
// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
// See https://llvm.org/LICENSE.txt for license information.
@ -8,8 +8,8 @@
// Implements out-of-line member functions of template class FormatControl
#ifndef FORTRAN_RUNTIME_FORMAT_IMPLEMENTATION_H_
#define FORTRAN_RUNTIME_FORMAT_IMPLEMENTATION_H_
#ifndef FLANG_RT_RUNTIME_FORMAT_IMPLEMENTATION_H_
#define FLANG_RT_RUNTIME_FORMAT_IMPLEMENTATION_H_
#include "emit-encoded.h"
#include "format.h"
@ -601,4 +601,4 @@ RT_API_ATTRS void FormatControl<CONTEXT>::Finish(Context &context) {
}
}
} // namespace Fortran::runtime::io
#endif // FORTRAN_RUNTIME_FORMAT_IMPLEMENTATION_H_
#endif // FLANG_RT_RUNTIME_FORMAT_IMPLEMENTATION_H_

View File

@ -1,4 +1,4 @@
//===-- runtime/format.h ----------------------------------------*- C++ -*-===//
//===-- include/flang-rt/runtime/format.h -----------------------*- C++ -*-===//
//
// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
// See https://llvm.org/LICENSE.txt for license information.
@ -8,8 +8,8 @@
// FORMAT string processing
#ifndef FORTRAN_RUNTIME_FORMAT_H_
#define FORTRAN_RUNTIME_FORMAT_H_
#ifndef FLANG_RT_RUNTIME_FORMAT_H_
#define FLANG_RT_RUNTIME_FORMAT_H_
#include "environment.h"
#include "io-error.h"
@ -201,4 +201,4 @@ private:
Iteration stack_[maxMaxHeight];
};
} // namespace Fortran::runtime::io
#endif // FORTRAN_RUNTIME_FORMAT_H_
#endif // FLANG_RT_RUNTIME_FORMAT_H_

View File

@ -1,4 +1,4 @@
//===-- runtime/internal-unit.h ---------------------------------*- C++ -*-===//
//===-- include/flang-rt/runtime/internal-unit.h ----------------*- C++ -*-===//
//
// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
// See https://llvm.org/LICENSE.txt for license information.
@ -8,11 +8,11 @@
// Fortran internal I/O "units"
#ifndef FORTRAN_RUNTIME_IO_INTERNAL_UNIT_H_
#define FORTRAN_RUNTIME_IO_INTERNAL_UNIT_H_
#ifndef FLANG_RT_RUNTIME_INTERNAL_UNIT_H_
#define FLANG_RT_RUNTIME_INTERNAL_UNIT_H_
#include "connection.h"
#include "flang/Runtime/descriptor.h"
#include "descriptor.h"
#include <cinttypes>
#include <type_traits>
@ -56,4 +56,4 @@ private:
extern template class InternalDescriptorUnit<Direction::Output>;
extern template class InternalDescriptorUnit<Direction::Input>;
} // namespace Fortran::runtime::io
#endif // FORTRAN_RUNTIME_IO_INTERNAL_UNIT_H_
#endif // FLANG_RT_RUNTIME_INTERNAL_UNIT_H_

View File

@ -1,4 +1,4 @@
//===-- runtime/io-error.h --------------------------------------*- C++ -*-===//
//===-- include/flang-rt/runtime/io-error.h ---------------------*- C++ -*-===//
//
// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
// See https://llvm.org/LICENSE.txt for license information.
@ -12,12 +12,12 @@
// IOSTAT error codes are raw errno values augmented with values for
// Fortran-specific errors.
#ifndef FORTRAN_RUNTIME_IO_ERROR_H_
#define FORTRAN_RUNTIME_IO_ERROR_H_
#ifndef FLANG_RT_RUNTIME_IO_ERROR_H_
#define FLANG_RT_RUNTIME_IO_ERROR_H_
#include "memory.h"
#include "terminator.h"
#include "flang/Runtime/iostat.h"
#include "flang/Runtime/memory.h"
#include <cinttypes>
namespace Fortran::runtime::io {
@ -80,4 +80,4 @@ private:
};
} // namespace Fortran::runtime::io
#endif // FORTRAN_RUNTIME_IO_ERROR_H_
#endif // FLANG_RT_RUNTIME_IO_ERROR_H_

View File

@ -1,4 +1,4 @@
//===-- runtime/io-stmt.h ---------------------------------------*- C++ -*-===//
//===-- include/flang-rt/runtime/io-stmt.h ----------------------*- C++ -*-===//
//
// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
// See https://llvm.org/LICENSE.txt for license information.
@ -8,10 +8,11 @@
// Representations of the state of an I/O statement in progress
#ifndef FORTRAN_RUNTIME_IO_STMT_H_
#define FORTRAN_RUNTIME_IO_STMT_H_
#ifndef FLANG_RT_RUNTIME_IO_STMT_H_
#define FLANG_RT_RUNTIME_IO_STMT_H_
#include "connection.h"
#include "descriptor.h"
#include "file.h"
#include "format.h"
#include "internal-unit.h"
@ -19,7 +20,6 @@
#include "flang/Common/optional.h"
#include "flang/Common/reference-wrapper.h"
#include "flang/Common/visit.h"
#include "flang/Runtime/descriptor.h"
#include "flang/Runtime/io-api.h"
#include <flang/Common/variant.h>
#include <functional>
@ -791,4 +791,4 @@ private:
};
} // namespace Fortran::runtime::io
#endif // FORTRAN_RUNTIME_IO_STMT_H_
#endif // FLANG_RT_RUNTIME_IO_STMT_H_

View File

@ -1,4 +1,4 @@
//===-- runtime/lock.h ------------------------------------------*- C++ -*-===//
//===-- include/flang-rt/runtime/lock.h -------------------------*- C++ -*-===//
//
// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
// See https://llvm.org/LICENSE.txt for license information.
@ -8,8 +8,8 @@
// Wraps a mutex
#ifndef FORTRAN_RUNTIME_LOCK_H_
#define FORTRAN_RUNTIME_LOCK_H_
#ifndef FLANG_RT_RUNTIME_LOCK_H_
#define FLANG_RT_RUNTIME_LOCK_H_
#include "terminator.h"
#include "tools.h"
@ -113,4 +113,4 @@ private:
};
} // namespace Fortran::runtime
#endif // FORTRAN_RUNTIME_LOCK_H_
#endif // FLANG_RT_RUNTIME_LOCK_H_

View File

@ -1,4 +1,4 @@
//===-- include/flang/Runtime/memory.h --------------------------*- C++ -*-===//
//===-- include/flang-rt/runtime/memory.h -----------------------*- C++ -*-===//
//
// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
// See https://llvm.org/LICENSE.txt for license information.
@ -9,8 +9,8 @@
// Thin wrapper around malloc()/free() to isolate the dependency,
// ease porting, and provide an owning pointer.
#ifndef FORTRAN_RUNTIME_MEMORY_H_
#define FORTRAN_RUNTIME_MEMORY_H_
#ifndef FLANG_RT_RUNTIME_MEMORY_H_
#define FLANG_RT_RUNTIME_MEMORY_H_
#include "flang/Common/api-attrs.h"
#include <cassert>
@ -170,4 +170,4 @@ template <typename A> struct Allocator {
};
} // namespace Fortran::runtime
#endif // FORTRAN_RUNTIME_MEMORY_H_
#endif // FLANG_RT_RUNTIME_MEMORY_H_

View File

@ -1,4 +1,4 @@
//===-- runtime/namelist.h --------------------------------------*- C++ -*-===//
//===-- include/flang-rt/runtime/namelist.h ---------------------*- C++ -*-===//
//
// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
// See https://llvm.org/LICENSE.txt for license information.
@ -8,8 +8,8 @@
// Defines the data structure used for NAMELIST I/O
#ifndef FORTRAN_RUNTIME_NAMELIST_H_
#define FORTRAN_RUNTIME_NAMELIST_H_
#ifndef FLANG_RT_RUNTIME_NAMELIST_H_
#define FLANG_RT_RUNTIME_NAMELIST_H_
#include "non-tbp-dio.h"
#include "flang/Common/api-attrs.h"
@ -51,4 +51,4 @@ public:
RT_API_ATTRS bool IsNamelistNameOrSlash(IoStatementState &);
} // namespace Fortran::runtime::io
#endif // FORTRAN_RUNTIME_NAMELIST_H_
#endif // FLANG_RT_RUNTIME_NAMELIST_H_

View File

@ -1,4 +1,4 @@
//===-- flang/runtime/non-tbp-dio.h -----------------------------*- C++ -*-===//
//===-- include/flang-rt/runtime/non-tbp-dio.h ------------------*- C++ -*-===//
//
// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
// See https://llvm.org/LICENSE.txt for license information.
@ -19,8 +19,8 @@
// a containing scope has become inaccessible in a nested scope due
// to the use of "IMPORT, NONE" or "IMPORT, ONLY:".
#ifndef FORTRAN_RUNTIME_NON_TBP_DIO_H_
#define FORTRAN_RUNTIME_NON_TBP_DIO_H_
#ifndef FLANG_RT_RUNTIME_NON_TBP_DIO_H_
#define FLANG_RT_RUNTIME_NON_TBP_DIO_H_
#include "flang/Common/Fortran-consts.h"
#include "flang/Common/api-attrs.h"
@ -53,4 +53,4 @@ struct NonTbpDefinedIoTable {
};
} // namespace Fortran::runtime::io
#endif // FORTRAN_RUNTIME_NON_TBP_DIO_H_
#endif // FLANG_RT_RUNTIME_NON_TBP_DIO_H_

View File

@ -1,4 +1,4 @@
//===-- runtime/numeric-templates.h -----------------------------*- C++ -*-===//
//===-- include/flang-rt/runtime/numeric-templates.h ------------*- C++ -*-===//
//
// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
// See https://llvm.org/LICENSE.txt for license information.
@ -15,8 +15,8 @@
// for the data type corresponding to CppTypeFor<TypeCategory::Real, 16>
// on the target.
#ifndef FORTRAN_RUNTIME_NUMERIC_TEMPLATES_H_
#define FORTRAN_RUNTIME_NUMERIC_TEMPLATES_H_
#ifndef FLANG_RT_RUNTIME_NUMERIC_TEMPLATES_H_
#define FLANG_RT_RUNTIME_NUMERIC_TEMPLATES_H_
#include "terminator.h"
#include "tools.h"
@ -368,4 +368,4 @@ template <typename T> inline RT_API_ATTRS T ErfcScaled(T arg) {
} // namespace Fortran::runtime
#endif // FORTRAN_RUNTIME_NUMERIC_TEMPLATES_H_
#endif // FLANG_RT_RUNTIME_NUMERIC_TEMPLATES_H_

View File

@ -1,4 +1,4 @@
//===-- runtime/random-templates.h ------------------------------*- C++ -*-===//
//===-- include/flang-rt/runtime/random-templates.h -------------*- C++ -*-===//
//
// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
// See https://llvm.org/LICENSE.txt for license information.
@ -6,13 +6,13 @@
//
//===----------------------------------------------------------------------===//
#ifndef FORTRAN_RUNTIME_RANDOM_TEMPLATES_H_
#define FORTRAN_RUNTIME_RANDOM_TEMPLATES_H_
#ifndef FLANG_RT_RUNTIME_RANDOM_TEMPLATES_H_
#define FLANG_RT_RUNTIME_RANDOM_TEMPLATES_H_
#include "descriptor.h"
#include "lock.h"
#include "numeric-templates.h"
#include "flang/Common/optional.h"
#include "flang/Runtime/descriptor.h"
#include <algorithm>
#include <random>
@ -108,4 +108,4 @@ inline void GenerateUnsigned(const Descriptor &harvest) {
} // namespace Fortran::runtime::random
#endif // FORTRAN_RUNTIME_RANDOM_TEMPLATES_H_
#endif // FLANG_RT_RUNTIME_RANDOM_TEMPLATES_H_

View File

@ -1,4 +1,4 @@
//===-- runtime/reduction-templates.h ---------------------------*- C++ -*-===//
//===-- include/flang-rt/runtime/reduction-templates.h ----------*- C++ -*-===//
//
// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
// See https://llvm.org/LICENSE.txt for license information.
@ -18,14 +18,14 @@
// * Character-valued reductions (MAXVAL & MINVAL) return arbitrary
// length results, dynamically allocated in a caller-supplied descriptor
#ifndef FORTRAN_RUNTIME_REDUCTION_TEMPLATES_H_
#define FORTRAN_RUNTIME_REDUCTION_TEMPLATES_H_
#ifndef FLANG_RT_RUNTIME_REDUCTION_TEMPLATES_H_
#define FLANG_RT_RUNTIME_REDUCTION_TEMPLATES_H_
#include "descriptor.h"
#include "numeric-templates.h"
#include "terminator.h"
#include "tools.h"
#include "flang/Runtime/cpp-type.h"
#include "flang/Runtime/descriptor.h"
#include <algorithm>
namespace Fortran::runtime {
@ -416,4 +416,4 @@ template <int KIND> struct Norm2Helper {
};
} // namespace Fortran::runtime
#endif // FORTRAN_RUNTIME_REDUCTION_TEMPLATES_H_
#endif // FLANG_RT_RUNTIME_REDUCTION_TEMPLATES_H_

View File

@ -1,4 +1,4 @@
//===-- runtime/stat.h ------------------------------------------*- C++ -*-===//
//===-- include/flang-rt/runtime/stat.h -------------------------*- C++ -*-===//
//
// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
// See https://llvm.org/LICENSE.txt for license information.
@ -9,8 +9,8 @@
// Defines the values returned by the runtime for STAT= specifiers
// on executable statements.
#ifndef FORTRAN_RUNTIME_STAT_H_
#define FORTRAN_RUNTIME_STAT_H_
#ifndef FLANG_RT_RUNTIME_STAT_H_
#define FLANG_RT_RUNTIME_STAT_H_
#include "flang/Common/ISO_Fortran_binding_wrapper.h"
#include "flang/Common/api-attrs.h"
#include "flang/Runtime/magic-numbers.h"
@ -60,4 +60,4 @@ RT_API_ATTRS int ToErrmsg(const Descriptor *errmsg, int stat); // returns stat
RT_API_ATTRS int ReturnError(Terminator &, int stat,
const Descriptor *errmsg = nullptr, bool hasStat = false);
} // namespace Fortran::runtime
#endif // FORTRAN_RUNTIME_STAT_H
#endif // FLANG_RT_RUNTIME_STAT_H_

View File

@ -1,4 +1,4 @@
//===-- runtime/terminator.h ------------------------------------*- C++ -*-===//
//===-- include/flang-rt/runtime/terminator.h -------------------*- C++ -*-===//
//
// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
// See https://llvm.org/LICENSE.txt for license information.
@ -8,8 +8,8 @@
// Termination of the image
#ifndef FORTRAN_RUNTIME_TERMINATOR_H_
#define FORTRAN_RUNTIME_TERMINATOR_H_
#ifndef FLANG_RT_RUNTIME_TERMINATOR_H_
#define FLANG_RT_RUNTIME_TERMINATOR_H_
#include "flang/Common/api-attrs.h"
#include <cstdarg>
@ -121,4 +121,4 @@ namespace Fortran::runtime::io {
RT_API_ATTRS void FlushOutputOnCrash(const Terminator &);
}
#endif // FORTRAN_RUNTIME_TERMINATOR_H_
#endif // FLANG_RT_RUNTIME_TERMINATOR_H_

View File

@ -1,4 +1,4 @@
//===-- runtime/tools.h -----------------------------------------*- C++ -*-===//
//===-- include/flang-rt/runtime/tools.h ------------------------*- C++ -*-===//
//
// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
// See https://llvm.org/LICENSE.txt for license information.
@ -6,16 +6,16 @@
//
//===----------------------------------------------------------------------===//
#ifndef FORTRAN_RUNTIME_TOOLS_H_
#define FORTRAN_RUNTIME_TOOLS_H_
#ifndef FLANG_RT_RUNTIME_TOOLS_H_
#define FLANG_RT_RUNTIME_TOOLS_H_
#include "descriptor.h"
#include "memory.h"
#include "stat.h"
#include "terminator.h"
#include "flang/Common/optional.h"
#include "flang/Runtime/cpp-type.h"
#include "flang/Runtime/descriptor.h"
#include "flang/Runtime/freestanding-tools.h"
#include "flang/Runtime/memory.h"
#include <cstring>
#include <functional>
#include <map>
@ -348,7 +348,7 @@ inline RT_API_ATTRS RESULT ApplyFloatingPointKind(
if constexpr (HasCppTypeFor<TypeCategory::Real, 16>) {
// If FUNC implemenation relies on FP math functions,
// then we should not be here. The compiler should have
// generated a call to an entry in flang_rt.quadmath
// generated a call to an entry in the libflang_rt.quadmath
// library.
if constexpr (!NEEDSMATH) {
return FUNC<16>{}(std::forward<A>(x)...);
@ -570,4 +570,4 @@ RT_API_ATTRS void CreatePartialReductionResult(Descriptor &result,
const char *intrinsic, TypeCode);
} // namespace Fortran::runtime
#endif // FORTRAN_RUNTIME_TOOLS_H_
#endif // FLANG_RT_RUNTIME_TOOLS_H_

View File

@ -1,4 +1,4 @@
//===-- include/flang/Runtime/type-code.h -----------------------*- C++ -*-===//
//===-- include/flang-rt/runtime/type-code.h --------------------*- C++ -*-===//
//
// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
// See https://llvm.org/LICENSE.txt for license information.
@ -6,8 +6,8 @@
//
//===----------------------------------------------------------------------===//
#ifndef FORTRAN_RUNTIME_TYPE_CODE_H_
#define FORTRAN_RUNTIME_TYPE_CODE_H_
#ifndef FLANG_RT_RUNTIME_TYPE_CODE_H_
#define FLANG_RT_RUNTIME_TYPE_CODE_H_
#include "flang/Common/Fortran-consts.h"
#include "flang/Common/ISO_Fortran_binding_wrapper.h"
@ -75,4 +75,4 @@ private:
ISO::CFI_type_t raw_{CFI_type_other};
};
} // namespace Fortran::runtime
#endif // FORTRAN_RUNTIME_TYPE_CODE_H_
#endif // FLANG_RT_RUNTIME_TYPE_CODE_H_

View File

@ -1,4 +1,4 @@
//===-- runtime/type-info.h -------------------------------------*- C++ -*-===//
//===-- include/flang-rt/runtime/type-info.h --------------------*- C++ -*-===//
//
// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
// See https://llvm.org/LICENSE.txt for license information.
@ -6,17 +6,17 @@
//
//===----------------------------------------------------------------------===//
#ifndef FORTRAN_RUNTIME_TYPE_INFO_H_
#define FORTRAN_RUNTIME_TYPE_INFO_H_
#ifndef FLANG_RT_RUNTIME_TYPE_INFO_H_
#define FLANG_RT_RUNTIME_TYPE_INFO_H_
// A C++ perspective of the derived type description schemata in
// flang/module/__fortran_type_info.f90.
#include "descriptor.h"
#include "terminator.h"
#include "flang/Common/Fortran-consts.h"
#include "flang/Common/bit-population-count.h"
#include "flang/Common/optional.h"
#include "flang/Runtime/descriptor.h"
#include <cinttypes>
#include <memory>
@ -321,4 +321,4 @@ private:
};
} // namespace Fortran::runtime::typeInfo
#endif // FORTRAN_RUNTIME_TYPE_INFO_H_
#endif // FLANG_RT_RUNTIME_TYPE_INFO_H_

View File

@ -1,4 +1,4 @@
//===-- runtime/utf.h -----------------------------------------------------===//
//===-- include/flang-rt/runtime/utf.h --------------------------*- C++ -*-===//
//
// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
// See https://llvm.org/LICENSE.txt for license information.
@ -38,8 +38,8 @@
// standard maximum. However, we support extended forms up to 32 bits so that
// CHARACTER(KIND=4) can be abused to hold arbitrary 32-bit data.
#ifndef FORTRAN_RUNTIME_UTF_H_
#define FORTRAN_RUNTIME_UTF_H_
#ifndef FLANG_RT_RUNTIME_UTF_H_
#define FLANG_RT_RUNTIME_UTF_H_
#include "flang/Common/optional.h"
#include <cstddef>
@ -70,4 +70,4 @@ RT_API_ATTRS Fortran::common::optional<char32_t> DecodeUTF8(const char *);
RT_API_ATTRS std::size_t EncodeUTF8(char *, char32_t);
} // namespace Fortran::runtime
#endif // FORTRAN_RUNTIME_UTF_H_
#endif // FLANG_RT_RUNTIME_UTF_H_

View File

@ -1,4 +1,4 @@
//===-- runtime/CUDA/allocatable.cpp --------------------------------------===//
//===-- lib/cuda/allocatable.cpp --------------------------------*- C++ -*-===//
//
// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
// See https://llvm.org/LICENSE.txt for license information.
@ -7,9 +7,10 @@
//===----------------------------------------------------------------------===//
#include "flang/Runtime/CUDA/allocatable.h"
#include "../assign-impl.h"
#include "../stat.h"
#include "../terminator.h"
#include "flang-rt/runtime/assign-impl.h"
#include "flang-rt/runtime/descriptor.h"
#include "flang-rt/runtime/stat.h"
#include "flang-rt/runtime/terminator.h"
#include "flang/Runtime/CUDA/common.h"
#include "flang/Runtime/CUDA/descriptor.h"
#include "flang/Runtime/CUDA/memmove-function.h"

View File

@ -1,4 +1,4 @@
//===-- runtime/CUDA/allocator.cpp ----------------------------------------===//
//===-- lib/cuda/allocator.cpp ----------------------------------*- C++ -*-===//
//
// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
// See https://llvm.org/LICENSE.txt for license information.
@ -7,13 +7,13 @@
//===----------------------------------------------------------------------===//
#include "flang/Runtime/CUDA/allocator.h"
#include "../derived.h"
#include "../stat.h"
#include "../terminator.h"
#include "../type-info.h"
#include "flang-rt/runtime/allocator-registry.h"
#include "flang-rt/runtime/derived.h"
#include "flang-rt/runtime/stat.h"
#include "flang-rt/runtime/terminator.h"
#include "flang-rt/runtime/type-info.h"
#include "flang/Common/ISO_Fortran_binding_wrapper.h"
#include "flang/Runtime/CUDA/common.h"
#include "flang/Runtime/allocator-registry.h"
#include "flang/Support/Fortran.h"
#include "cuda_runtime.h"

View File

@ -1,4 +1,4 @@
//===-- runtime/CUDA/descriptor.cpp ---------------------------------------===//
//===-- lib/cuda/descriptor.cpp ---------------------------------*- C++ -*-===//
//
// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
// See https://llvm.org/LICENSE.txt for license information.
@ -7,10 +7,10 @@
//===----------------------------------------------------------------------===//
#include "flang/Runtime/CUDA/descriptor.h"
#include "../terminator.h"
#include "flang-rt/runtime/descriptor.h"
#include "flang-rt/runtime/terminator.h"
#include "flang/Runtime/CUDA/allocator.h"
#include "flang/Runtime/CUDA/common.h"
#include "flang/Runtime/descriptor.h"
#include "cuda_runtime.h"

View File

@ -1,4 +1,4 @@
//===-- runtime/CUDA/init.cpp ---------------------------------------------===//
//===-- lib/cuda/init.cpp ---------------------------------------*- C++ -*-===//
//
// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
// See https://llvm.org/LICENSE.txt for license information.
@ -7,8 +7,8 @@
//===----------------------------------------------------------------------===//
#include "flang/Runtime/CUDA/init.h"
#include "../environment.h"
#include "../terminator.h"
#include "flang-rt/runtime/environment.h"
#include "flang-rt/runtime/terminator.h"
#include "flang/Runtime/CUDA/common.h"
#include "cuda_runtime.h"

View File

@ -1,4 +1,4 @@
//===-- runtime/CUDA/kernel.cpp -------------------------------------------===//
//===-- lib/cuda/kernel.cpp -------------------------------------*- C++ -*-===//
//
// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
// See https://llvm.org/LICENSE.txt for license information.
@ -7,7 +7,7 @@
//===----------------------------------------------------------------------===//
#include "flang/Runtime/CUDA/kernel.h"
#include "../terminator.h"
#include "flang-rt/runtime/terminator.h"
#include "flang/Runtime/CUDA/common.h"
#include "cuda_runtime.h"

View File

@ -1,4 +1,4 @@
//===-- runtime/CUDA/memmove-function.cpp ---------------------------------===//
//===-- lib/cuda/memmove-function.cpp ---------------------------*- C++ -*-===//
//
// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
// See https://llvm.org/LICENSE.txt for license information.
@ -7,7 +7,7 @@
//===----------------------------------------------------------------------===//
#include "flang/Runtime/CUDA/memmove-function.h"
#include "../terminator.h"
#include "flang-rt/runtime/terminator.h"
#include "flang/Runtime/CUDA/common.h"
#include "cuda_runtime.h"

View File

@ -1,4 +1,4 @@
//===-- runtime/CUDA/memory.cpp -------------------------------------------===//
//===-- lib/cuda/memory.cpp -------------------------------------*- C++ -*-===//
//
// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
// See https://llvm.org/LICENSE.txt for license information.
@ -7,8 +7,8 @@
//===----------------------------------------------------------------------===//
#include "flang/Runtime/CUDA/memory.h"
#include "../assign-impl.h"
#include "../terminator.h"
#include "flang-rt/runtime/assign-impl.h"
#include "flang-rt/runtime/terminator.h"
#include "flang/Runtime/CUDA/common.h"
#include "flang/Runtime/CUDA/descriptor.h"
#include "flang/Runtime/CUDA/memmove-function.h"

View File

@ -1,4 +1,4 @@
//===-- runtime/CUDA/pointer.cpp ------------------------------------------===//
//===-- lib/cuda/pointer.cpp ------------------------------------*- C++ -*-===//
//
// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
// See https://llvm.org/LICENSE.txt for license information.
@ -7,9 +7,10 @@
//===----------------------------------------------------------------------===//
#include "flang/Runtime/CUDA/pointer.h"
#include "../assign-impl.h"
#include "../stat.h"
#include "../terminator.h"
#include "flang-rt/runtime/assign-impl.h"
#include "flang-rt/runtime/descriptor.h"
#include "flang-rt/runtime/stat.h"
#include "flang-rt/runtime/terminator.h"
#include "flang/Runtime/CUDA/descriptor.h"
#include "flang/Runtime/CUDA/memmove-function.h"
#include "flang/Runtime/pointer.h"

View File

@ -1,4 +1,4 @@
//===-- runtime/CUDA/registration.cpp -------------------------------------===//
//===-- lib/cuda/registration.cpp -------------------------------*- C++ -*-===//
//
// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
// See https://llvm.org/LICENSE.txt for license information.
@ -7,7 +7,7 @@
//===----------------------------------------------------------------------===//
#include "flang/Runtime/CUDA/registration.h"
#include "../terminator.h"
#include "flang-rt/runtime/terminator.h"
#include "flang/Runtime/CUDA/common.h"
#include "cuda_runtime.h"

View File

@ -1,4 +1,4 @@
//===-- runtime/Float128Math/acos.cpp -------------------------------------===//
//===-- lib/quadmath/acos.cpp -----------------------------------*- C++ -*-===//
//
// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
// See https://llvm.org/LICENSE.txt for license information.

View File

@ -1,4 +1,4 @@
//===-- runtime/Float128Math/acosh.cpp ------------------------------------===//
//===-- lib/quadmath/acosh.cpp ----------------------------------*- C++ -*-===//
//
// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
// See https://llvm.org/LICENSE.txt for license information.

View File

@ -1,4 +1,4 @@
//===-- runtime/Float128Math/asin.cpp -------------------------------------===//
//===-- lib/quadmath/asin.cpp -----------------------------------*- C++ -*-===//
//
// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
// See https://llvm.org/LICENSE.txt for license information.

View File

@ -1,4 +1,4 @@
//===-- runtime/Float128Math/asinh.cpp ------------------------------------===//
//===-- lib/quadmath/asinh.cpp ----------------------------------*- C++ -*-===//
//
// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
// See https://llvm.org/LICENSE.txt for license information.

View File

@ -1,4 +1,4 @@
//===-- runtime/Float128Math/atan.cpp -------------------------------------===//
//===-- lib/quadmath/atan.cpp -----------------------------------*- C++ -*-===//
//
// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
// See https://llvm.org/LICENSE.txt for license information.

View File

@ -1,4 +1,4 @@
//===-- runtime/Float128Math/atan2.cpp ------------------------------------===//
//===-- lib/quadmath/atan2.cpp ----------------------------------*- C++ -*-===//
//
// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
// See https://llvm.org/LICENSE.txt for license information.

View File

@ -1,4 +1,4 @@
//===-- runtime/Float128Math/atanh.cpp ------------------------------------===//
//===-- lib/quadmath/atanh.cpp ----------------------------------*- C++ -*-===//
//
// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
// See https://llvm.org/LICENSE.txt for license information.

View File

@ -1,4 +1,4 @@
//===-- runtime/Float128Math/ceil.cpp -------------------------------------===//
//===-- lib/quadmath/ceil.cpp -----------------------------------*- C++ -*-===//
//
// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
// See https://llvm.org/LICENSE.txt for license information.

View File

@ -1,11 +1,10 @@
/*===-- runtime/Float128Math/complex-math.c -------------------------*- C -*-===
/*===-- lib/quadmath/complex-math.c ---------------------------------*- C -*-===
*
* Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
* See https://llvm.org/LICENSE.txt for license information.
* SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
*
* ===-----------------------------------------------------------------------===
*/
*===----------------------------------------------------------------------===*/
#include "complex-math.h"

View File

@ -1,4 +1,4 @@
/*===-- runtime/Float128Math/complex-math.h -------------------------*- C -*-===
/*===-- lib/quadmath/complex-math.h ---------------------------------*- C -*-===
*
* Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
* See https://llvm.org/LICENSE.txt for license information.
@ -6,8 +6,8 @@
*
*===----------------------------------------------------------------------===*/
#ifndef FORTRAN_RUNTIME_FLOAT128MATH_COMPLEX_MATH_H_
#define FORTRAN_RUNTIME_FLOAT128MATH_COMPLEX_MATH_H_
#ifndef FLANG_RT_QUADMATH_COMPLEX_MATH_H_
#define FLANG_RT_QUADMATH_COMPLEX_MATH_H_
#include "flang/Common/float128.h"
#include "flang/Runtime/entry-names.h"
@ -59,4 +59,4 @@
#error "Float128Math build with glibc>=2.26 is unsupported yet"
#endif
#endif /* FORTRAN_RUNTIME_FLOAT128MATH_COMPLEX_MATH_H_ */
#endif /* FLANG_RT_QUADMATH_COMPLEX_MATH_H_ */

View File

@ -1,4 +1,4 @@
//===-- runtime/Float128Math/cos.cpp --------------------------------------===//
//===-- lib/quadmath/cos.cpp ------------------------------------*- C++ -*-===//
//
// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
// See https://llvm.org/LICENSE.txt for license information.

View File

@ -1,4 +1,4 @@
//===-- runtime/Float128Math/cosh.cpp -------------------------------------===//
//===-- lib/quadmath/cosh.cpp -----------------------------------*- C++ -*-===//
//
// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
// See https://llvm.org/LICENSE.txt for license information.

View File

@ -1,4 +1,4 @@
//===-- runtime/Float128Math/erf.cpp --------------------------------------===//
//===-- lib/quadmath/erf.cpp ------------------------------------*- C++ -*-===//
//
// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
// See https://llvm.org/LICENSE.txt for license information.

View File

@ -1,4 +1,4 @@
//===-- runtime/Float128Math/erfc.cpp -------------------------------------===//
//===-- lib/quadmath/erfc.cpp -----------------------------------*- C++ -*-===//
//
// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
// See https://llvm.org/LICENSE.txt for license information.

View File

@ -1,4 +1,4 @@
//===-- runtime/Float128Math/exp.cpp --------------------------------------===//
//===-- lib/quadmath/exp.cpp ------------------------------------*- C++ -*-===//
//
// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
// See https://llvm.org/LICENSE.txt for license information.

View File

@ -1,4 +1,4 @@
//===-- runtime/Float128Math/exponent.cpp ---------------------------------===//
//===-- lib/quadmath/exponent.cpp -------------------------------*- C++ -*-===//
//
// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
// See https://llvm.org/LICENSE.txt for license information.

View File

@ -1,4 +1,4 @@
//===-- runtime/Float128Math/floor.cpp ------------------------------------===//
//===-- lib/quadmath/floor.cpp ----------------------------------*- C++ -*-===//
//
// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
// See https://llvm.org/LICENSE.txt for license information.

View File

@ -1,4 +1,4 @@
//===-- runtime/Float128Math/fma.cpp --------------------------------------===//
//===-- lib/quadmath/fma.cpp ------------------------------------*- C++ -*-===//
//
// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
// See https://llvm.org/LICENSE.txt for license information.

View File

@ -1,4 +1,4 @@
//===-- runtime/Float128Math/fraction.cpp ---------------------------------===//
//===-- lib/quadmath/fraction.cpp -------------------------------*- C++ -*-===//
//
// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
// See https://llvm.org/LICENSE.txt for license information.

View File

@ -1,4 +1,4 @@
//===-- runtime/Float128Math/hypot.cpp ------------------------------------===//
//===-- lib/quadmath/hypot.cpp ----------------------------------*- C++ -*-===//
//
// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
// See https://llvm.org/LICENSE.txt for license information.

View File

@ -1,4 +1,4 @@
//===-- runtime/Float128Math/j0.cpp ---------------------------------------===//
//===-- lib/quadmath/j0.cpp -------------------------------------*- C++ -*-===//
//
// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
// See https://llvm.org/LICENSE.txt for license information.

View File

@ -1,4 +1,4 @@
//===-- runtime/Float128Math/j1.cpp ---------------------------------------===//
//===-- lib/quadmath/j1.cpp -------------------------------------*- C++ -*-===//
//
// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
// See https://llvm.org/LICENSE.txt for license information.

View File

@ -1,4 +1,4 @@
//===-- runtime/Float128Math/jn.cpp ---------------------------------------===//
//===-- lib/quadmath/jn.cpp -------------------------------------*- C++ -*-===//
//
// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
// See https://llvm.org/LICENSE.txt for license information.

View File

@ -1,4 +1,4 @@
//===-- runtime/Float128Math/lgamma.cpp -----------------------------------===//
//===-- lib/quadmath/lgamma.cpp ---------------------------------*- C++ -*-===//
//
// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
// See https://llvm.org/LICENSE.txt for license information.

View File

@ -1,4 +1,4 @@
//===-- runtime/Float128Math/llround.cpp ----------------------------------===//
//===-- lib/quadmath/llround.cpp --------------------------------*- C++ -*-===//
//
// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
// See https://llvm.org/LICENSE.txt for license information.

View File

@ -1,4 +1,4 @@
//===-- runtime/Float128Math/log.cpp --------------------------------------===//
//===-- lib/quadmath/log.cpp ------------------------------------*- C++ -*-===//
//
// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
// See https://llvm.org/LICENSE.txt for license information.

View File

@ -1,4 +1,4 @@
//===-- runtime/Float128Math/log10.cpp ------------------------------------===//
//===-- lib/quadmath/log10.cpp ----------------------------------*- C++ -*-===//
//
// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
// See https://llvm.org/LICENSE.txt for license information.

View File

@ -1,4 +1,4 @@
//===-- runtime/Float128Math/lround.cpp -----------------------------------===//
//===-- lib/quadmath/lround.cpp ---------------------------------*- C++ -*-===//
//
// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
// See https://llvm.org/LICENSE.txt for license information.

View File

@ -1,4 +1,4 @@
//===-- runtime/Float128Math/math-entries.h ---------------------*- C++ -*-===//
//===-- lib/quadmath/math-entries.h -----------------------------*- C++ -*-===//
//
// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
// See https://llvm.org/LICENSE.txt for license information.
@ -6,10 +6,11 @@
//
//===----------------------------------------------------------------------===//
#ifndef FORTRAN_RUNTIME_FLOAT128MATH_MATH_ENTRIES_H_
#define FORTRAN_RUNTIME_FLOAT128MATH_MATH_ENTRIES_H_
#include "terminator.h"
#include "tools.h"
#ifndef FLANG_RT_QUADMATH_MATH_ENTRIES_H_
#define FLANG_RT_QUADMATH_MATH_ENTRIES_H_
#include "flang-rt/runtime/terminator.h"
#include "flang-rt/runtime/tools.h"
#include "flang/Common/float128.h"
#include "flang/Runtime/entry-names.h"
#include <cfloat>
@ -231,4 +232,4 @@ DEFINE_SIMPLE_ALIAS(Yn, ynl)
} // namespace Fortran::runtime
#endif // FORTRAN_RUNTIME_FLOAT128MATH_MATH_ENTRIES_H_
#endif // FLANG_RT_QUADMATH_MATH_ENTRIES_H_

View File

@ -1,4 +1,4 @@
//===-- runtime/Float128Math/mod-real.cpp ---------------------------------===//
//===-- lib/quadmath/mod-real.cpp -------------------------------*- C++ -*-===//
//
// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
// See https://llvm.org/LICENSE.txt for license information.

View File

@ -1,4 +1,4 @@
//===-- runtime/Float128Math/modulo-real.cpp ------------------------------===//
//===-- lib/quadmath/modulo-real.cpp ----------------------------*- C++ -*-===//
//
// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
// See https://llvm.org/LICENSE.txt for license information.

View File

@ -1,4 +1,4 @@
//===-- runtime/Float128Math/nearbyint.cpp --------------------------------===//
//===-- lib/quadmath/nearbyint.cpp ------------------------------*- C++ -*-===//
//
// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
// See https://llvm.org/LICENSE.txt for license information.

View File

@ -1,4 +1,4 @@
//===-- runtime/Float128Math/nearest.cpp ----------------------------------===//
//===-- lib/quadmath/nearest.cpp --------------------------------*- C++ -*-===//
//
// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
// See https://llvm.org/LICENSE.txt for license information.

View File

@ -1,4 +1,4 @@
//===-- runtime/Float128Math/norm2.cpp ------------------------------------===//
//===-- lib/quadmath/norm2.cpp ----------------------------------*- C++ -*-===//
//
// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
// See https://llvm.org/LICENSE.txt for license information.
@ -8,7 +8,7 @@
#include "math-entries.h"
#include "numeric-template-specs.h"
#include "reduction-templates.h"
#include "flang-rt/runtime/reduction-templates.h"
namespace Fortran::runtime {
extern "C" {

View File

@ -1,4 +1,4 @@
//===-- runtime/Float128Math/numeric-template-specs.h -----------*- C++ -*-===//
//===-- lib/quadmath/numeric-template-specs.h -------------------*- C++ -*-===//
//
// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
// See https://llvm.org/LICENSE.txt for license information.
@ -6,11 +6,11 @@
//
//===----------------------------------------------------------------------===//
#ifndef FORTRAN_RUNTIME_FLOAT128MATH_NUMERIC_TEMPLATE_SPECS_H_
#define FORTRAN_RUNTIME_FLOAT128MATH_NUMERIC_TEMPLATE_SPECS_H_
#ifndef FLANG_RT_QUADMATH_NUMERIC_TEMPLATE_SPECS_H_
#define FLANG_RT_QUADMATH_NUMERIC_TEMPLATE_SPECS_H_
#include "math-entries.h"
#include "numeric-templates.h"
#include "flang-rt/runtime/numeric-templates.h"
namespace Fortran::runtime {
using F128Type = CppTypeFor<TypeCategory::Real, 16>;
@ -52,4 +52,4 @@ template <> struct SQRTTy<F128Type> {
};
} // namespace Fortran::runtime
#endif // FORTRAN_RUNTIME_FLOAT128MATH_NUMERIC_TEMPLATE_SPECS_H_
#endif // FLANG_RT_QUADMATH_NUMERIC_TEMPLATE_SPECS_H_

View File

@ -1,4 +1,4 @@
//===-- runtime/Float128Math/pow.cpp --------------------------------------===//
//===-- lib/quadmath/pow.cpp ------------------------------------*- C++ -*-===//
//
// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
// See https://llvm.org/LICENSE.txt for license information.

View File

@ -1,4 +1,4 @@
//===-- runtime/Float128Math/random.cpp -----------------------------------===//
//===-- lib/quadmath/random.cpp ---------------------------------*- C++ -*-===//
//
// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
// See https://llvm.org/LICENSE.txt for license information.
@ -8,7 +8,7 @@
#include "math-entries.h"
#include "numeric-template-specs.h"
#include "random-templates.h"
#include "flang-rt/runtime/random-templates.h"
using namespace Fortran::runtime::random;
extern "C" {

View File

@ -1,4 +1,4 @@
//===-- runtime/Float128Math/remainder.cpp --------------------------------===//
//===-- lib/quadmath/remainder.cpp ------------------------------*- C++ -*-===//
//
// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
// See https://llvm.org/LICENSE.txt for license information.

View File

@ -1,4 +1,4 @@
//===-- runtime/Float128Math/round.cpp ------------------------------------===//
//===-- lib/quadmath/round.cpp ----------------------------------*- C++ -*-===//
//
// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
// See https://llvm.org/LICENSE.txt for license information.

View File

@ -1,4 +1,4 @@
//===-- runtime/Float128Math/rrspacing.cpp --------------------------------===//
//===-- lib/quadmath/rrspacing.cpp ------------------------------*- C++ -*-===//
//
// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
// See https://llvm.org/LICENSE.txt for license information.

View File

@ -1,4 +1,4 @@
//===-- runtime/Float128Math/scale.cpp ------------------------------------===//
//===-- lib/quadmath/scale.cpp ----------------------------------*- C++ -*-===//
//
// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
// See https://llvm.org/LICENSE.txt for license information.

View File

@ -1,4 +1,4 @@
//===-- runtime/Float128Math/set-exponent.cpp -----------------------------===//
//===-- lib/quadmath/set-exponent.cpp ---------------------------*- C++ -*-===//
//
// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
// See https://llvm.org/LICENSE.txt for license information.

View File

@ -1,4 +1,4 @@
//===-- runtime/Float128Math/sin.cpp --------------------------------------===//
//===-- lib/quadmath/sin.cpp ------------------------------------*- C++ -*-===//
//
// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
// See https://llvm.org/LICENSE.txt for license information.

View File

@ -1,4 +1,4 @@
//===-- runtime/Float128Math/sinh.cpp -------------------------------------===//
//===-- lib/quadmath/sinh.cpp -----------------------------------*- C++ -*-===//
//
// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
// See https://llvm.org/LICENSE.txt for license information.

View File

@ -1,4 +1,4 @@
//===-- runtime/Float128Math/spacing.cpp ----------------------------------===//
//===-- lib/quadmath/spacing.cpp --------------------------------*- C++ -*-===//
//
// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
// See https://llvm.org/LICENSE.txt for license information.

View File

@ -1,4 +1,4 @@
//===-- runtime/Float128Math/sqrt.cpp -------------------------------------===//
//===-- lib/quadmath/sqrt.cpp -----------------------------------*- C++ -*-===//
//
// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
// See https://llvm.org/LICENSE.txt for license information.

View File

@ -1,4 +1,4 @@
//===-- runtime/Float128Math/tan.cpp --------------------------------------===//
//===-- lib/quadmath/tan.cpp ------------------------------------*- C++ -*-===//
//
// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
// See https://llvm.org/LICENSE.txt for license information.

View File

@ -1,4 +1,4 @@
//===-- runtime/Float128Math/tanh.cpp -------------------------------------===//
//===-- lib/quadmath/tanh.cpp -----------------------------------*- C++ -*-===//
//
// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
// See https://llvm.org/LICENSE.txt for license information.

View File

@ -1,4 +1,4 @@
//===-- runtime/Float128Math/tgamma.cpp -----------------------------------===//
//===-- lib/quadmath/tgamma.cpp ---------------------------------*- C++ -*-===//
//
// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
// See https://llvm.org/LICENSE.txt for license information.

View File

@ -1,4 +1,4 @@
//===-- runtime/Float128Math/trunc.cpp ------------------------------------===//
//===-- lib/quadmath/trunc.cpp ----------------------------------*- C++ -*-===//
//
// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
// See https://llvm.org/LICENSE.txt for license information.

View File

@ -1,4 +1,4 @@
//===-- runtime/Float128Math/y0.cpp ---------------------------------------===//
//===-- lib/quadmath/y0.cpp -------------------------------------*- C++ -*-===//
//
// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
// See https://llvm.org/LICENSE.txt for license information.

View File

@ -1,4 +1,4 @@
//===-- runtime/Float128Math/y1.cpp ---------------------------------------===//
//===-- lib/quadmath/y1.cpp -------------------------------------*- C++ -*-===//
//
// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
// See https://llvm.org/LICENSE.txt for license information.

View File

@ -1,4 +1,4 @@
//===-- runtime/Float128Math/yn.cpp ---------------------------------------===//
//===-- lib/quadmath/yn.cpp -------------------------------------*- C++ -*-===//
//
// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
// See https://llvm.org/LICENSE.txt for license information.

View File

@ -1,4 +1,4 @@
//===-- runtime/ISO_Fortran_binding.cpp -----------------------------------===//
//===-- lib/runtime/ISO_Fortran_binding.cpp ---------------------*- C++ -*-===//
//
// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
// See https://llvm.org/LICENSE.txt for license information.
@ -10,11 +10,11 @@
// as specified in section 18.5.5 of Fortran 2018.
#include "ISO_Fortran_util.h"
#include "terminator.h"
#include "flang-rt/runtime/descriptor.h"
#include "flang-rt/runtime/terminator.h"
#include "flang-rt/runtime/type-code.h"
#include "flang/Common/ISO_Fortran_binding_wrapper.h"
#include "flang/Runtime/descriptor.h"
#include "flang/Runtime/pointer.h"
#include "flang/Runtime/type-code.h"
#include <cstdlib>
namespace Fortran::ISO {

View File

@ -1,4 +1,4 @@
//===-- runtime/ISO_Fortran_util.h ------------------------------*- C++ -*-===//
//===-- lib/runtime/ISO_Fortran_util.h --------------------------*- C++ -*-===//
//
// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
// See https://llvm.org/LICENSE.txt for license information.
@ -6,15 +6,15 @@
//
//===----------------------------------------------------------------------===//
#ifndef FORTRAN_RUNTIME_ISO_FORTRAN_UTIL_H_
#define FORTRAN_RUNTIME_ISO_FORTRAN_UTIL_H_
#ifndef FLANG_RT_RUNTIME_ISO_FORTRAN_UTIL_H_
#define FLANG_RT_RUNTIME_ISO_FORTRAN_UTIL_H_
// Internal utils for establishing CFI_cdesc_t descriptors.
#include "terminator.h"
#include "flang-rt/runtime/descriptor.h"
#include "flang-rt/runtime/terminator.h"
#include "flang-rt/runtime/type-code.h"
#include "flang/Common/ISO_Fortran_binding_wrapper.h"
#include "flang/Runtime/descriptor.h"
#include "flang/Runtime/type-code.h"
#include <cstdlib>
namespace Fortran::ISO {
@ -99,4 +99,4 @@ static inline RT_API_ATTRS void EstablishDescriptor(CFI_cdesc_t *descriptor,
}
}
} // namespace Fortran::ISO
#endif // FORTRAN_RUNTIME_ISO_FORTRAN_UTIL_H_
#endif // FLANG_RT_RUNTIME_ISO_FORTRAN_UTIL_H_

View File

@ -1,4 +1,4 @@
//===-- runtime/allocatable.cpp -------------------------------------------===//
//===-- lib/runtime/allocatable.cpp -----------------------------*- C++ -*-===//
//
// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
// See https://llvm.org/LICENSE.txt for license information.
@ -7,14 +7,14 @@
//===----------------------------------------------------------------------===//
#include "flang/Runtime/allocatable.h"
#include "assign-impl.h"
#include "derived.h"
#include "stat.h"
#include "terminator.h"
#include "type-info.h"
#include "flang-rt/runtime/assign-impl.h"
#include "flang-rt/runtime/derived.h"
#include "flang-rt/runtime/descriptor.h"
#include "flang-rt/runtime/stat.h"
#include "flang-rt/runtime/terminator.h"
#include "flang-rt/runtime/type-info.h"
#include "flang/Common/ISO_Fortran_binding_wrapper.h"
#include "flang/Runtime/assign.h"
#include "flang/Runtime/descriptor.h"
namespace Fortran::runtime {
extern "C" {

View File

@ -1,4 +1,4 @@
//===-- runtime/allocator-registry.cpp ------------------------------------===//
//===-- lib/runtime/allocator-registry.cpp ----------------------*- C++ -*-===//
//
// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
// See https://llvm.org/LICENSE.txt for license information.
@ -6,8 +6,8 @@
//
//===----------------------------------------------------------------------===//
#include "flang/Runtime/allocator-registry.h"
#include "terminator.h"
#include "flang-rt/runtime/allocator-registry.h"
#include "flang-rt/runtime/terminator.h"
namespace Fortran::runtime {

View File

@ -1,4 +1,4 @@
//===-- runtime/array-constructor.cpp -------------------------------------===//
//===-- lib/runtime/array-constructor.cpp -----------------------*- C++ -*-===//
//
// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
// See https://llvm.org/LICENSE.txt for license information.
@ -6,14 +6,14 @@
//
//===----------------------------------------------------------------------===//
#include "flang/Runtime/array-constructor.h"
#include "derived.h"
#include "terminator.h"
#include "tools.h"
#include "type-info.h"
#include "flang-rt/runtime/array-constructor.h"
#include "flang-rt/runtime/derived.h"
#include "flang-rt/runtime/descriptor.h"
#include "flang-rt/runtime/terminator.h"
#include "flang-rt/runtime/tools.h"
#include "flang-rt/runtime/type-info.h"
#include "flang/Runtime/allocatable.h"
#include "flang/Runtime/assign.h"
#include "flang/Runtime/descriptor.h"
namespace Fortran::runtime {

View File

@ -1,4 +1,4 @@
//===-- runtime/assign.cpp ------------------------------------------------===//
//===-- lib/runtime/assign.cpp ----------------------------------*- C++ -*-===//
//
// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
// See https://llvm.org/LICENSE.txt for license information.
@ -7,13 +7,13 @@
//===----------------------------------------------------------------------===//
#include "flang/Runtime/assign.h"
#include "assign-impl.h"
#include "derived.h"
#include "stat.h"
#include "terminator.h"
#include "tools.h"
#include "type-info.h"
#include "flang/Runtime/descriptor.h"
#include "flang-rt/runtime/assign-impl.h"
#include "flang-rt/runtime/derived.h"
#include "flang-rt/runtime/descriptor.h"
#include "flang-rt/runtime/stat.h"
#include "flang-rt/runtime/terminator.h"
#include "flang-rt/runtime/tools.h"
#include "flang-rt/runtime/type-info.h"
namespace Fortran::runtime {

View File

@ -1,4 +1,4 @@
//===-- runtime/buffer.cpp ------------------------------------------------===//
//===-- lib/runtime/buffer.cpp ----------------------------------*- C++ -*-===//
//
// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
// See https://llvm.org/LICENSE.txt for license information.
@ -6,7 +6,7 @@
//
//===----------------------------------------------------------------------===//
#include "buffer.h"
#include "flang-rt/runtime/buffer.h"
#include <algorithm>
namespace Fortran::runtime::io {

Some files were not shown because too many files have changed in this diff Show More