Skip to content

Commit ce179da

Browse files
feat: fixing Rust's print mechanism for _mm512_conj_pch
1 parent a80eff1 commit ce179da

File tree

3 files changed

+10
-1
lines changed

3 files changed

+10
-1
lines changed

crates/intrinsic-test/missing_x86.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -890,7 +890,7 @@ _mm256_extract_epi16
890890
_mm256_extract_epi8
891891
_mm512_castsi128_si512
892892
_mm512_castsi256_si512
893-
_mm512_conj_pch
893+
# _mm512_conj_pch
894894
_mm512_mask_reduce_max_pd
895895
_mm512_mask_reduce_max_ps
896896
_mm512_mask_reduce_min_pd

crates/intrinsic-test/src/x86/config.rs

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -235,6 +235,9 @@ macro_rules! impl_debug_as {
235235
impl_debug_as!(__m128i, "__m128i", 128, [u8, i8, u16, i16, u32, i32, u64, i64]);
236236
impl_debug_as!(__m256i, "__m256i", 256, [u8, i8, u16, i16, u32, i32, u64, i64]);
237237
impl_debug_as!(__m512i, "__m512i", 512, [u8, i8, u16, i16, u32, i32, u64, i64]);
238+
impl_debug_as!(__m128h, "__m128h", 128, [f32]);
239+
impl_debug_as!(__m256h, "__m256h", 256, [f32]);
240+
impl_debug_as!(__m512h, "__m512h", 512, [f32]);
238241
239242
fn debug_as<V, T>(x: V) -> impl core::fmt::Debug
240243
where V: DebugAs<T>

crates/intrinsic-test/src/x86/types.rs

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -290,6 +290,12 @@ impl IntrinsicTypeDefinition for X86IntrinsicType {
290290
fn print_result_rust(&self) -> String {
291291
let return_value = match self.kind() {
292292
TypeKind::Float if self.inner_size() == 16 => "debug_f16(__return_value)".to_string(),
293+
TypeKind::Float
294+
if self.inner_size() == 32
295+
&& ["__m512h"].contains(&self.param.type_data.as_str()) =>
296+
{
297+
"debug_as::<_, f32>(__return_value)".to_string()
298+
}
293299
TypeKind::Int(_)
294300
if ["__m128i", "__m256i", "__m512i"].contains(&self.param.type_data.as_str()) =>
295301
{

0 commit comments

Comments
 (0)