[ 
https://issues.apache.org/jira/browse/ARROW-9688?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Kouhei Sutou reassigned ARROW-9688:
-----------------------------------

    Assignee: Niyas

> [C++] Supporting Windows ARM64 builds
> -------------------------------------
>
>                 Key: ARROW-9688
>                 URL: https://issues.apache.org/jira/browse/ARROW-9688
>             Project: Apache Arrow
>          Issue Type: Bug
>          Components: C++
>    Affects Versions: 1.0.0
>         Environment: Windows
>            Reporter: Mukul Sabharwal
>            Assignee: Niyas
>            Priority: Minor
>              Labels: pull-request-available
>   Original Estimate: 336h
>          Time Spent: 1h
>  Remaining Estimate: 335h
>
> I was trying to build the Arrow library so I could use it to generate parquet 
> files on Windows ARM64, but it currently fails to compile for a few reasons. 
> I thought I'd enumerate them here, so someone more familiar with the project 
> could spearhead it.
> In SetupCxxFlags.cmake
>  * the MSVC branch for ARROW_CPU_FLAG STREQUAL "x86" is taken even though I'm 
> building ARM64, this may be a more fundamental error somewhere else that 
> needs correction and maybe things would work better, but an inspection of 
> other branches seemed to indicate that ARM64 is assumed to be missing from 
> MSVC and the keywrod "aarch64" (not a term used in the Windows ecosystem) is 
> prevalent in the cmake files. So the first thing I did was I stubbed it out 
> and set SSE42, AVX and AVX512 to be not present
>  * In bit_util.h I provided implementations for popcount32, popcount64 that 
> were not neon accelerated, although neon_cnt is provided by msvc (for n64)
>  * Removed nmintrin.h since that is x64/x64 specific. Note, _BitScanReverse 
> and _BitScanForward are Microsoft specific and support on ARM64.
>  * cpu_info.cc needed tweaks for cpuid stuff, I just returned false and 
> didn't really care too much about any upstream effects. flag_mappings and 
> num_flags ought be defined in the not WIN32 ifdef, since they're not actually 
> used.
> After these changes I was able to remove the vcpkg restriction that 
> artificially failed the library from compiling on arm64 and I was able to 
> successfully compile for both arm64-windows-static and arm64-windows.



--
This message was sent by Atlassian Jira
(v8.3.4#803005)

Reply via email to