Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Minor style/comment fixes in the SIMD headers #489

Merged
merged 1 commit into from
Aug 7, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 1 addition & 3 deletions Source/astcenc_vecmathlib_avx2_8.h
Original file line number Diff line number Diff line change
Expand Up @@ -149,7 +149,7 @@ struct vint8
/**
* @brief Construct from 1 scalar value replicated across all lanes.
*
* Consider using vfloat8::zero() for constexpr zeros.
* Consider using zero() for constexpr zeros.
*/
ASTCENC_SIMD_INLINE explicit vint8(int a)
{
Expand Down Expand Up @@ -623,7 +623,6 @@ ASTCENC_SIMD_INLINE vfloat8 operator/(vfloat8 a, float b)
return vfloat8(_mm256_div_ps(a.m, _mm256_set1_ps(b)));
}


/**
* @brief Overload: scalar by vector division.
*/
Expand All @@ -632,7 +631,6 @@ ASTCENC_SIMD_INLINE vfloat8 operator/(float a, vfloat8 b)
return vfloat8(_mm256_div_ps(_mm256_set1_ps(a), b.m));
}


/**
* @brief Overload: vector by vector equality.
*/
Expand Down
2 changes: 1 addition & 1 deletion Source/astcenc_vecmathlib_neon_4.h
Original file line number Diff line number Diff line change
Expand Up @@ -203,7 +203,7 @@ struct vint4
/**
* @brief Construct from 1 scalar value replicated across all lanes.
*
* Consider using vfloat4::zero() for constexpr zeros.
* Consider using zero() for constexpr zeros.
*/
ASTCENC_SIMD_INLINE explicit vint4(int a)
{
Expand Down
2 changes: 1 addition & 1 deletion Source/astcenc_vecmathlib_none_4.h
Original file line number Diff line number Diff line change
Expand Up @@ -225,7 +225,7 @@ struct vint4
/**
* @brief Construct from 4 scalar values replicated across all lanes.
*
* Consider using vint4::zero() for constexpr zeros.
* Consider using zero() for constexpr zeros.
*/
ASTCENC_SIMD_INLINE explicit vint4(int a)
{
Expand Down
2 changes: 1 addition & 1 deletion Source/astcenc_vecmathlib_sse_4.h
Original file line number Diff line number Diff line change
Expand Up @@ -221,7 +221,7 @@ struct vint4
/**
* @brief Construct from 1 scalar value replicated across all lanes.
*
* Consider using vfloat4::zero() for constexpr zeros.
* Consider using zero() for constexpr zeros.
*/
ASTCENC_SIMD_INLINE explicit vint4(int a)
{
Expand Down
10 changes: 4 additions & 6 deletions Source/astcenc_vecmathlib_sve_8.h
Original file line number Diff line number Diff line change
Expand Up @@ -27,8 +27,8 @@
* code.
*/

#ifndef ASTC_VECMATHLIB_sve_8_H_INCLUDED
#define ASTC_VECMATHLIB_sve_8_H_INCLUDED
#ifndef ASTC_VECMATHLIB_SVE_8_H_INCLUDED
#define ASTC_VECMATHLIB_SVE_8_H_INCLUDED

#ifndef ASTCENC_SIMD_INLINE
#error "Include astcenc_vecmathlib.h, do not include directly"
Expand Down Expand Up @@ -159,7 +159,7 @@ struct vint8
/**
* @brief Construct from 1 scalar value replicated across all lanes.
*
* Consider using vfloat8::zero() for constexpr zeros.
* Consider using zero() for constexpr zeros.
*/
ASTCENC_SIMD_INLINE explicit vint8(int a)
{
Expand Down Expand Up @@ -602,7 +602,6 @@ ASTCENC_SIMD_INLINE vfloat8 operator/(vfloat8 a, float b)
return vfloat8(svdiv_f32_x(svptrue_b32(), a.m, svdup_f32(b)));
}


/**
* @brief Overload: scalar by vector division.
*/
Expand All @@ -611,7 +610,6 @@ ASTCENC_SIMD_INLINE vfloat8 operator/(float a, vfloat8 b)
return vfloat8(svdiv_f32_x(svptrue_b32(), svdup_f32(a), b.m));
}


/**
* @brief Overload: vector by vector equality.
*/
Expand Down Expand Up @@ -1086,4 +1084,4 @@ ASTCENC_SIMD_INLINE void print(vmask8 a)
print(select(vint8(0), vint8(1), a));
}

#endif // #ifndef ASTC_VECMATHLIB_sve_8_H_INCLUDED
#endif // #ifndef ASTC_VECMATHLIB_SVE_8_H_INCLUDED