未验证 提交 002f2185 编写于 作者: C chenxujun 提交者: GitHub

Fix typos, test=document_fix (#52937)

上级 c3417fd2
...@@ -39,7 +39,7 @@ enum class DataType { ...@@ -39,7 +39,7 @@ enum class DataType {
BOOL, BOOL,
UINT8, // BYte UINT8, // Byte
INT8, // Char INT8, // Char
UINT16, UINT16,
INT16, INT16,
...@@ -70,7 +70,7 @@ enum class DataType { ...@@ -70,7 +70,7 @@ enum class DataType {
BFLOAT16, BFLOAT16,
NUM_DATA_TYPES, NUM_DATA_TYPES,
// See Note [ Why we need ALL in baisc kernel key member? ] // See Note [ Why we need ALL in basic kernel key member? ]
ALL_DTYPE = UNDEFINED, ALL_DTYPE = UNDEFINED,
}; };
......
...@@ -44,7 +44,7 @@ class ThreadDataRegistry { ...@@ -44,7 +44,7 @@ class ThreadDataRegistry {
} }
// Returns current snapshot of all threads. Make sure there is no thread // Returns current snapshot of all threads. Make sure there is no thread
// create/destory when using it. // create/destroy when using it.
template < template <
typename Alias = T, typename Alias = T,
typename = std::enable_if_t<std::is_copy_constructible<Alias>::value>> typename = std::enable_if_t<std::is_copy_constructible<Alias>::value>>
...@@ -53,7 +53,7 @@ class ThreadDataRegistry { ...@@ -53,7 +53,7 @@ class ThreadDataRegistry {
} }
// Returns current snapshot of all threads. Make sure there is no thread // Returns current snapshot of all threads. Make sure there is no thread
// create/destory when using it. // create/destroy when using it.
std::unordered_map<uint64_t, std::reference_wrapper<T>> std::unordered_map<uint64_t, std::reference_wrapper<T>>
GetAllThreadDataByRef() { GetAllThreadDataByRef() {
return impl_->GetAllThreadDataByRef(); return impl_->GetAllThreadDataByRef();
......
...@@ -33,7 +33,7 @@ namespace phi { ...@@ -33,7 +33,7 @@ namespace phi {
// range defined by a pair of iterators. // range defined by a pair of iterators.
// //
// - The specialization for CPU calls std::transform. // - The specialization for CPU calls std::transform.
// - The specialization for CUDA calls thrust::tranform. // - The specialization for CUDA calls thrust::transform.
// //
// NOTE: We need to define InputIter and OutputIter defined as // NOTE: We need to define InputIter and OutputIter defined as
// different types, because the InputIter points op's inputs and // different types, because the InputIter points op's inputs and
...@@ -41,7 +41,7 @@ namespace phi { ...@@ -41,7 +41,7 @@ namespace phi {
// //
// NOTE: We don't assume that InputIter to be const InputType* and // NOTE: We don't assume that InputIter to be const InputType* and
// OutputIter to be OutputType*, because we might use a iterator // OutputIter to be OutputType*, because we might use a iterator
// class, paddle::fluid::operators::RowwiseTRansformIterator. // class, paddle::fluid::operators::RowwiseTransformIterator.
template <typename Context> template <typename Context>
struct Transform { struct Transform {
// The unary version. // The unary version.
...@@ -94,7 +94,7 @@ struct Transform<phi::CPUContext> { ...@@ -94,7 +94,7 @@ struct Transform<phi::CPUContext> {
#if defined(__NVCC__) || defined(__HIPCC__) #if defined(__NVCC__) || defined(__HIPCC__)
// PointerToThrustDevicePtr has two speicalizations, one casts a (CUDA // PointerToThrustDevicePtr has two specializations, one casts a (CUDA
// device) pointer into thrust::device_ptr, the other keeps rest types // device) pointer into thrust::device_ptr, the other keeps rest types
// un-casted. // un-casted.
template <typename T, bool is_ptr> template <typename T, bool is_ptr>
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册