Unverified Commit 65c5581f authored by Paul Fultz II's avatar Paul Fultz II Committed by GitHub
Browse files

Merge branch 'master' into identity

parents 453fa37a f04a3ba6
......@@ -2,14 +2,14 @@
#ifndef MIGRAPH_GUARD_PASS_CONFIG_HPP
#define MIGRAPH_GUARD_PASS_CONFIG_HPP
#include <migraph/env.hpp>
#include <migraph/config.hpp>
#include <migraphx/env.hpp>
#include <migraphx/config.hpp>
namespace migraph {
namespace migraphx {
inline namespace MIGRAPH_INLINE_NS {
MIGRAPH_DECLARE_ENV_VAR(MIGRAPH_DISABLE_MEMORY_COLORING)
} // namespace MIGRAPH_INLINE_NS
} // namespace migraph
} // namespace migraphx
#endif // MIGRAPH_GUARD_PASS_CONFIG_HPP
......@@ -3,17 +3,17 @@
#include <list>
#include <unordered_map>
#include <migraph/operation.hpp>
#include <migraph/literal.hpp>
#include <migraph/builtin.hpp>
#include <migraph/instruction_ref.hpp>
#include <migraph/target.hpp>
#include <migraph/tracer.hpp>
#include <migraph/config.hpp>
#include <migraphx/operation.hpp>
#include <migraphx/literal.hpp>
#include <migraphx/builtin.hpp>
#include <migraphx/instruction_ref.hpp>
#include <migraphx/target.hpp>
#include <migraphx/tracer.hpp>
#include <migraphx/config.hpp>
#include <algorithm>
#include <iostream>
namespace migraph {
namespace migraphx {
inline namespace MIGRAPH_INLINE_NS {
struct program_impl;
......@@ -110,6 +110,6 @@ struct program
};
} // namespace MIGRAPH_INLINE_NS
} // namespace migraph
} // namespace migraphx
#endif
......@@ -3,10 +3,10 @@
#include <algorithm>
#include <initializer_list>
#include <migraph/rank.hpp>
#include <migraph/config.hpp>
#include <migraphx/rank.hpp>
#include <migraphx/config.hpp>
namespace migraph {
namespace migraphx {
inline namespace MIGRAPH_INLINE_NS {
namespace detail {
......@@ -107,6 +107,6 @@ iterator_range<Iterator> range(std::pair<Iterator, Iterator> p)
}
} // namespace MIGRAPH_INLINE_NS
} // namespace migraph
} // namespace migraphx
#endif
#ifndef MIGRAPH_GUARD_RTGLIB_RANK_HPP
#define MIGRAPH_GUARD_RTGLIB_RANK_HPP
#include <migraph/config.hpp>
#include <migraphx/config.hpp>
namespace migraph {
namespace migraphx {
inline namespace MIGRAPH_INLINE_NS {
template <int N>
......@@ -17,6 +17,6 @@ struct rank<0>
};
} // namespace MIGRAPH_INLINE_NS
} // namespace migraph
} // namespace migraphx
#endif
......@@ -2,11 +2,11 @@
#ifndef MIGRAPH_GUARD_RAW_DATA_HPP
#define MIGRAPH_GUARD_RAW_DATA_HPP
#include <migraph/tensor_view.hpp>
#include <migraph/requires.hpp>
#include <migraph/config.hpp>
#include <migraphx/tensor_view.hpp>
#include <migraphx/requires.hpp>
#include <migraphx/config.hpp>
namespace migraph {
namespace migraphx {
inline namespace MIGRAPH_INLINE_NS {
struct raw_data_base
......@@ -104,7 +104,7 @@ struct raw_data : raw_data_base
bool matches() const
{
return is_data_ptr<T>{} ||
self->get_shape().type() == migraph::shape::get_type<get_data_type<T>>{};
self->get_shape().type() == migraphx::shape::get_type<get_data_type<T>>{};
}
template <class T>
......@@ -125,7 +125,7 @@ struct raw_data : raw_data_base
{
auto&& s = static_cast<const Derived&>(*this).get_shape();
auto&& buffer = static_cast<const Derived&>(*this).data();
if(s.type() != migraph::shape::get_type<T>{})
if(s.type() != migraphx::shape::get_type<T>{})
MIGRAPH_THROW("Incorrect data type for raw data");
return make_view(s, reinterpret_cast<T*>(buffer));
}
......@@ -136,7 +136,7 @@ struct raw_data : raw_data_base
{
auto&& s = static_cast<const Derived&>(*this).get_shape();
auto&& buffer = static_cast<const Derived&>(*this).data();
assert(s.type() == migraph::shape::get_type<T>{});
assert(s.type() == migraphx::shape::get_type<T>{});
return reinterpret_cast<T*>(buffer);
}
};
......@@ -206,6 +206,6 @@ auto visit_all(T&& x, Ts&&... xs)
}
} // namespace MIGRAPH_INLINE_NS
} // namespace migraph
} // namespace migraphx
#endif
#ifndef MIGRAPH_GUARD_RTGLIB_REFLECT_HPP
#define MIGRAPH_GUARD_RTGLIB_REFLECT_HPP
#include <migraph/functional.hpp>
#include <migraph/rank.hpp>
#include <migraph/config.hpp>
#include <migraphx/functional.hpp>
#include <migraphx/rank.hpp>
#include <migraphx/config.hpp>
#include <functional>
namespace migraph {
namespace migraphx {
inline namespace MIGRAPH_INLINE_NS {
namespace detail {
......@@ -48,6 +48,6 @@ void reflect_each(T& x, F f)
}
} // namespace MIGRAPH_INLINE_NS
} // namespace migraph
} // namespace migraphx
#endif
......@@ -2,9 +2,9 @@
#define MIGRAPH_GUARD_MIGRAPHLIB_REQUIRES_HPP
#include <type_traits>
#include <migraph/config.hpp>
#include <migraphx/config.hpp>
namespace migraph {
namespace migraphx {
inline namespace MIGRAPH_INLINE_NS {
template <bool... Bs>
......@@ -32,21 +32,21 @@ struct requires_enum
#if 0
// TODO: This currently crashed on clang
#define MIGRAPH_REQUIRES(...) \
typename migraph::requires_enum<__LINE__>::e MIGRAPH_REQUIRES_CAT( \
typename migraphx::requires_enum<__LINE__>::e MIGRAPH_REQUIRES_CAT( \
PrivateRequires, \
__LINE__) = migraph::requires_enum<__LINE__>::a, \
__LINE__) = migraphx::requires_enum<__LINE__>::a, \
class = typename std::enable_if<and_<__VA_ARGS__, \
MIGRAPH_REQUIRES_CAT(PrivateRequires, __LINE__) == \
migraph::requires_enum<__LINE__>::a>{}>::type
migraphx::requires_enum<__LINE__>::a>{}>::type
#else
#define MIGRAPH_REQUIRES(...) \
typename migraph::requires_enum<__LINE__>::e MIGRAPH_REQUIRES_CAT( \
PrivateRequires, __LINE__) = migraph::requires_enum<__LINE__>::a, \
#define MIGRAPH_REQUIRES(...) \
typename migraphx::requires_enum<__LINE__>::e MIGRAPH_REQUIRES_CAT( \
PrivateRequires, __LINE__) = migraphx::requires_enum<__LINE__>::a, \
class = typename std::enable_if<and_<__VA_ARGS__>{}>::type
#endif
#endif
} // namespace MIGRAPH_INLINE_NS
} // namespace migraph
} // namespace migraphx
#endif
......@@ -7,11 +7,11 @@
#include <numeric>
#include <memory>
#include <migraph/errors.hpp>
#include <migraph/half.hpp>
#include <migraph/config.hpp>
#include <migraphx/errors.hpp>
#include <migraphx/half.hpp>
#include <migraphx/config.hpp>
namespace migraph {
namespace migraphx {
inline namespace MIGRAPH_INLINE_NS {
struct shape_impl;
......@@ -164,6 +164,6 @@ struct shape
};
} // namespace MIGRAPH_INLINE_NS
} // namespace migraph
} // namespace migraphx
#endif
#ifndef MIGRAPH_GUARD_MIGRAPHLIB_SHAPE_FOR_EACH_HPP
#define MIGRAPH_GUARD_MIGRAPHLIB_SHAPE_FOR_EACH_HPP
#include <migraph/shape.hpp>
#include <migraph/config.hpp>
#include <migraphx/shape.hpp>
#include <migraphx/config.hpp>
#include <algorithm>
namespace migraph {
namespace migraphx {
inline namespace MIGRAPH_INLINE_NS {
template <class F>
void shape_for_each(const migraph::shape& s, F f)
void shape_for_each(const migraphx::shape& s, F f)
{
// Ensure calls to f use const ref to vector
auto call = [&f](const std::vector<std::size_t>& i) { f(i); };
......@@ -29,6 +29,6 @@ void shape_for_each(const migraph::shape& s, F f)
}
} // namespace MIGRAPH_INLINE_NS
} // namespace migraph
} // namespace migraphx
#endif
......@@ -2,9 +2,9 @@
#define MIGRAPH_GUARD_RTGLIB_SIMPLIFY_ALGEBRA_HPP
#include <string>
#include <migraph/config.hpp>
#include <migraphx/config.hpp>
namespace migraph {
namespace migraphx {
inline namespace MIGRAPH_INLINE_NS {
struct program;
......@@ -19,6 +19,6 @@ struct simplify_algebra
};
} // namespace MIGRAPH_INLINE_NS
} // namespace migraph
} // namespace migraphx
#endif
......@@ -2,10 +2,10 @@
#define MIGRAPH_GUARD_RTGLIB_SIMPLIFY_RESHAPES_HPP
#include <string>
#include <migraph/instruction_ref.hpp>
#include <migraph/config.hpp>
#include <migraphx/instruction_ref.hpp>
#include <migraphx/config.hpp>
namespace migraph {
namespace migraphx {
inline namespace MIGRAPH_INLINE_NS {
struct program;
......@@ -20,6 +20,6 @@ struct simplify_reshapes
};
} // namespace MIGRAPH_INLINE_NS
} // namespace migraph
} // namespace migraphx
#endif
......@@ -3,10 +3,10 @@
#include <ostream>
#include <algorithm>
#include <migraph/rank.hpp>
#include <migraph/config.hpp>
#include <migraphx/rank.hpp>
#include <migraphx/config.hpp>
namespace migraph {
namespace migraphx {
inline namespace MIGRAPH_INLINE_NS {
template <class T>
......@@ -57,6 +57,6 @@ void stream_write_value(std::ostream& os, const T& x)
}
} // namespace MIGRAPH_INLINE_NS
} // namespace migraph
} // namespace migraphx
#endif
......@@ -5,9 +5,9 @@
#include <numeric>
#include <string>
#include <sstream>
#include <migraph/config.hpp>
#include <migraphx/config.hpp>
namespace migraph {
namespace migraphx {
inline namespace MIGRAPH_INLINE_NS {
inline std::string
......@@ -88,6 +88,6 @@ inline std::string to_string(const T& x)
}
} // namespace MIGRAPH_INLINE_NS
} // namespace migraph
} // namespace migraphx
#endif
......@@ -8,11 +8,11 @@
#include <type_traits>
#include <utility>
#include <vector>
#include <migraph/context.hpp>
#include <migraph/pass.hpp>
#include <migraph/config.hpp>
#include <migraphx/context.hpp>
#include <migraphx/pass.hpp>
#include <migraphx/config.hpp>
namespace migraph {
namespace migraphx {
inline namespace MIGRAPH_INLINE_NS {
#ifdef DOXYGEN
......@@ -245,6 +245,6 @@ inline const ValueType& any_cast(const target& x)
#endif
} // namespace MIGRAPH_INLINE_NS
} // namespace migraph
} // namespace migraphx
#endif
#ifndef MIGRAPH_GUARD_TENSOR_VIEW_HPP
#define MIGRAPH_GUARD_TENSOR_VIEW_HPP
#include <migraph/shape.hpp>
#include <migraph/float_equal.hpp>
#include <migraph/requires.hpp>
#include <migraph/config.hpp>
#include <migraphx/shape.hpp>
#include <migraphx/float_equal.hpp>
#include <migraphx/requires.hpp>
#include <migraphx/config.hpp>
#include <iostream>
#include <utility>
namespace migraph {
namespace migraphx {
inline namespace MIGRAPH_INLINE_NS {
template <class T>
......@@ -170,6 +170,6 @@ tensor_view<T> make_view(shape s, T* data)
}
} // namespace MIGRAPH_INLINE_NS
} // namespace migraph
} // namespace migraphx
#endif
......@@ -2,9 +2,9 @@
#define MIGRAPH_GUARD_RTGLIB_TIME_HPP
#include <chrono>
#include <migraph/config.hpp>
#include <migraphx/config.hpp>
namespace migraph {
namespace migraphx {
inline namespace MIGRAPH_INLINE_NS {
template <class Duration, class F>
......@@ -17,6 +17,6 @@ auto time(F f)
}
} // namespace MIGRAPH_INLINE_NS
} // namespace migraph
} // namespace migraphx
#endif
......@@ -2,10 +2,10 @@
#define MIGRAPH_GUARD_RTGLIB_TRACER_HPP
#include <ostream>
#include <migraph/functional.hpp>
#include <migraph/config.hpp>
#include <migraphx/functional.hpp>
#include <migraphx/config.hpp>
namespace migraph {
namespace migraphx {
inline namespace MIGRAPH_INLINE_NS {
struct tracer
......@@ -31,6 +31,6 @@ struct tracer
};
} // namespace MIGRAPH_INLINE_NS
} // namespace migraph
} // namespace migraphx
#endif
......@@ -2,9 +2,9 @@
#define MIGRAPH_GUARD_RTGLIB_TYPE_NAME_HPP
#include <string>
#include <migraph/config.hpp>
#include <migraphx/config.hpp>
namespace migraph {
namespace migraphx {
inline namespace MIGRAPH_INLINE_NS {
template <class PrivateMigraphTypeNameProbe>
......@@ -38,10 +38,10 @@ const std::string& get_type_name()
template <class T>
const std::string& get_type_name(const T&)
{
return migraph::get_type_name<T>();
return migraphx::get_type_name<T>();
}
} // namespace MIGRAPH_INLINE_NS
} // namespace migraph
} // namespace migraphx
#endif
......@@ -9,10 +9,10 @@
#define MIGRAPH_GUARD_RTGLIB_TYPE_TRAITS_HPP
#include <type_traits>
#include <migraph/half.hpp>
#include <migraph/config.hpp>
#include <migraphx/half.hpp>
#include <migraphx/config.hpp>
namespace migraph {
namespace migraphx {
inline namespace MIGRAPH_INLINE_NS {
#define MIGRAPH_DETAIL_EXTEND_TRAIT_FOR(trait, T) \
......@@ -31,6 +31,6 @@ MIGRAPH_DETAIL_EXTEND_TRAIT_FOR(is_signed, half)
MIGRAPH_DETAIL_EXTEND_TRAIT_FOR(is_arithmetic, half)
} // namespace MIGRAPH_INLINE_NS
} // namespace migraph
} // namespace migraphx
#endif
......@@ -7,10 +7,10 @@
#include <iostream>
#include <numeric>
#include <migraph/float_equal.hpp>
#include <migraph/config.hpp>
#include <migraphx/float_equal.hpp>
#include <migraphx/config.hpp>
namespace migraph {
namespace migraphx {
inline namespace MIGRAPH_INLINE_NS {
// Compute the value of a range
......@@ -174,5 +174,5 @@ bool verify_range(R1&& r1, R2&& r2, double tolerance = 80, double* out_error = n
}
} // namespace MIGRAPH_INLINE_NS
} // namespace migraph
} // namespace migraphx
#endif
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment