Skip to content

Build failure on armv7l-linux and riscv64-linux (11.2.0, 12.0.0) (error: 'batch_bool_cast' was not declared in this scope) #986

@misuzu

Description

@misuzu

xsimd fails to build on armv7l-linux and riscv64-linux since 11.2.0, x86_64-linux and aarch64-linux have no issues

<.................>
[  5%] Building CXX object test/CMakeFiles/test_xsimd.dir/test_api.cpp.o
In file included from /build/source/include/xsimd/types/../arch/./xsimd_generic.hpp:18,
                 from /build/source/include/xsimd/types/../arch/xsimd_isa.hpp:92,
                 from /build/source/include/xsimd/types/xsimd_batch.hpp:492,
                 from /build/source/include/xsimd/xsimd.hpp:61,
                 from /build/source/test/test_api.cpp:12:
/build/source/include/xsimd/types/../arch/././generic/xsimd_generic_math.hpp: In function 'xsimd::batch<float, A> xsimd::kernel::cbrt(const xsimd::batch<float, A>&, requires_arch<xsimd::generic>)':
/build/source/include/xsimd/types/../arch/././generic/xsimd_generic_math.hpp:152:45: error: 'batch_bool_cast' was not declared in this scope; did you mean 'batch_cast'?
  152 |             const batch_type cbrt2 = select(batch_bool_cast<float>(flag), CBRT2, CBRT2I);
      |                                             ^~~~~~~~~~~~~~~
      |                                             batch_cast
/build/source/include/xsimd/types/../arch/././generic/xsimd_generic_math.hpp:152:61: error: expected primary-expression before 'float'
  152 |             const batch_type cbrt2 = select(batch_bool_cast<float>(flag), CBRT2, CBRT2I);
      |                                                             ^~~~~
/build/source/include/xsimd/types/../arch/././generic/xsimd_generic_math.hpp:153:61: error: expected primary-expression before 'float'
  153 |             const batch_type cbrt4 = select(batch_bool_cast<float>(flag), CBRT4, CBRT4I);
      |                                                             ^~~~~
/build/source/include/xsimd/types/../arch/././generic/xsimd_generic_math.hpp:154:54: error: expected primary-expression before 'float'
  154 |             batch_type fact = select(batch_bool_cast<float>(rem == i_type(1)), cbrt2, batch_type(1.));
      |                                                      ^~~~~
/build/source/include/xsimd/types/../arch/././generic/xsimd_generic_math.hpp:155:43: error: expected primary-expression before 'float'
  155 |             fact = select(batch_bool_cast<float>(rem == i_type(2)), cbrt4, fact);
<.................>

Build logs:
xsimd-12.0.0-armv7l-linux.log
xsimd-12.0.0-riscv64-linux.log

Maybe related? #716

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions