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

fio.exe for Windows ARM64 #1814

Open
gituser303 opened this issue Sep 12, 2024 · 14 comments
Open

fio.exe for Windows ARM64 #1814

gituser303 opened this issue Sep 12, 2024 · 14 comments

Comments

@gituser303
Copy link

Hello,

Could we please guide me creating fio.exe for a Windows ARM64?

Right now, the one we’ve is in the screenshot below isn’t the latest version, but we’d like to upgrade to the latest v3.37.

I’ve tried building the source code using WSL > Ubuntu on my Windows ARM64, which works, but I’d like a exe file that I can use it through a command prompt on a Windows ARM64. I’ve also tried building the source code in VS 2022 using Make empty project template and including the source code to the solution in IDE but throws bunch of build errors and warning. And the Cygwin won’t work on a Windows ARM64 system.

image

@vincentkfu
Copy link
Collaborator

I know little about building fio for Windows. However, our CI does build fio for Windows using the msys2 toolchain (in addition to Cygwin). The msys2 project says that it supports ARM64:

https://www.msys2.org/wiki/arm64/

Here are the msys2 packages we install: https://github.com/axboe/fio/blob/master/.github/workflows/ci.yml#L117

@gituser303
Copy link
Author

gituser303 commented Sep 12, 2024

I've got a Windows Server 2022 Datacenter which is a 64-bit operating system, ARM-based processor. I get this error in the screenshot below similar to my Cygwin attempt on click of msys2-x86_64-20240727.exe that I just downloaded through https://www.msys2.org/wiki/arm64/ as the webpage suggests.

image

@gituser303
Copy link
Author

If we've a fio.exe for the latest version 3.37 for Windows ARM64, could we share with me?

@vincentkfu
Copy link
Collaborator

I know of no fio 3.37 executable for Windows ARM64. I would consult with the msys2 folks to see why their package does not run.

@gituser303
Copy link
Author

That'd be great. Thank you, appreciated.

@vincentkfu
Copy link
Collaborator

My suggestion is for you to contact the msys2 developers to troubleshoot why their installer cannot run.

@gituser303
Copy link
Author

If I were to use command pacman -S mingw-w64-clangarm-x86_64-clang mingw-w64-clang-aarch64-clang on my Ubuntu 24.04 console which I had installed using WSL.exe, and then clang --target=aarch64-mingw-w64-win32-gnu a.c -o fio.exe what file name I'd be using in place of <a.c> from clang --target=aarch64-mingw-w64-win32-gnu a.c -o fio.exe

Someone from msys2's Help chat group wrote a sample program and steps to see if I can do it at my end. https://discord.com/channels/792780131906617355/1286036689545990206/1286036904327909479

@gituser303
Copy link
Author

I was able to install and run a 32bit Cygwin on my upgraded Windows ARM64 system based on https://stackoverflow.com/questions/74925143/cygwin-32-bit-update-on-win-10-64-bit-downloads-fail-with-errors, since the 64bit Cygwin won't work as mentioned in my earlier comment above, refer below my system info for details.

I was also able to execute successfully "How to compile fio on 64-bit Windows" steps from Building > Windows section from https://github.com/axboe/fio?tab=readme-ov-file

But the fio.exe that was generated shows "This version of fio.exe is not compatible with the version of Windows you're running. Check your computer's system information and then contact the software publisher." when fio.exe -help command was executed on this system's cmd. And on click of fio.exe, it shows the same blue screen message I posted earlier above.

Is there a way to fix it?

This is the config.log and make command output from 32bit Cygwin terminal console for reference.
config.log
MakeCommandOutput.txt

System Info:
OS Name: Microsoft Windows Server 2025 Datacenter
OS Version: 10.0.26100 N/A Build 26100
OS Manufacturer: Microsoft Corporation
OS Configuration: Member Server
OS Build Type: Multiprocessor Free
System Manufacturer: Microsoft
System Model: C2154
System Type: ARM64-based PC
Processor(s): 1 Processor(s) Installed.
[01]: ARMv8 (64-bit) Family 8 Model D0C Revision 301 Ampere(R) ~3000 Mhz
BIOS Version: Ampere(R) C2154.BS.1B15.GN1 (SCP: 1.08.20220218), 4/6/2022

@vincentkfu
Copy link
Collaborator

If I were to use command pacman -S mingw-w64-clangarm-x86_64-clang mingw-w64-clang-aarch64-clang on my Ubuntu 24.04 console which I had installed using WSL.exe, and then clang --target=aarch64-mingw-w64-win32-gnu a.c -o fio.exe what file name I'd be using in place of <a.c> from clang --target=aarch64-mingw-w64-win32-gnu a.c -o fio.exe

Someone from msys2's Help chat group wrote a sample program and steps to see if I can do it at my end. https://discord.com/channels/792780131906617355/1286036689545990206/1286036904327909479

I cannot access the discord link but there is no way to build fio with your command above replacing a.c with something else. I would just create a simple a.c to test your setup.

As for your build, we do automatically build 32-bit Windows x86 binaries. One flag you might be missing is to run configure with tihs option:

./configure --build-32bit-win

Take a look at ci/actions-install.sh and ci/actions-build.sh to see how we automatically build and test 32-bit Windows x86.

@gituser303
Copy link
Author

Now that I can install a 32bit Cygwin on my Windows ARM64 after a system upgrade, I'd like to go that route since it's simpler and I can follow instructions from fio's readme

Could you please guide me with the Cygwin to create fio.exe that I could run in Windows ARM64's cmd, since the fio.exe that I was able to get out of 32bit Cygwin won't work.

@vincentkfu
Copy link
Collaborator

From the README:

To build fio for 32-bit Windows, ensure the -i686 versions of the previously mentioned -x86_64 packages are installed and run ./configure --build-32bit-win before make

@gituser303
Copy link
Author

So the system is Windows ARM64 which is a 64bit system. It's the Cygwin that I was able to install is 32bit, still I've to follow 32bit Windows instructions?

@gituser303
Copy link
Author

I was able to install and run a 32bit Cygwin on my upgraded Windows ARM64 system based on https://stackoverflow.com/questions/74925143/cygwin-32-bit-update-on-win-10-64-bit-downloads-fail-with-errors, since the 64bit Cygwin won't work as mentioned in my earlier comment above, refer below my system info for details.

I was also able to execute successfully "How to compile fio on 64-bit Windows" steps from Building > Windows section from https://github.com/axboe/fio?tab=readme-ov-file

But the fio.exe that was generated shows "This version of fio.exe is not compatible with the version of Windows you're running. Check your computer's system information and then contact the software publisher." when fio.exe -help command was executed on this system's cmd. And on click of fio.exe, it shows the same blue screen message I posted earlier above.

Is there a way to fix it?

This is the config.log and make command output from 32bit Cygwin terminal console for reference. config.log MakeCommandOutput.txt

System Info: OS Name: Microsoft Windows Server 2025 Datacenter OS Version: 10.0.26100 N/A Build 26100 OS Manufacturer: Microsoft Corporation OS Configuration: Member Server OS Build Type: Multiprocessor Free System Manufacturer: Microsoft System Model: C2154 System Type: ARM64-based PC Processor(s): 1 Processor(s) Installed. [01]: ARMv8 (64-bit) Family 8 Model D0C Revision 301 Ampere(R) ~3000 Mhz BIOS Version: Ampere(R) C2154.BS.1B15.GN1 (SCP: 1.08.20220218), 4/6/2022

Is there anything we could do to make exe working from this attempt.

@vincentkfu
Copy link
Collaborator

I took another look at our configure script and your output a noticed the following from configure:

CYGWIN*)
  # We still force some options, so keep this message here.
  echo "Forcing some known good options on Windows"
  if test -z "${CC}${cross_prefix}"; then
    if test ! -z "$build_32bit_win" && test "$build_32bit_win" = "yes"; then
      cc="i686-w64-mingw32-gcc"
    else
      cc="x86_64-w64-mingw32-gcc"
    fi
  fi

On Windows our build system assumes that the platform is i686 or x86_64. The script does not support building on Windows on ARM platforms. You will need to find someone familiar with Windows and ARM to make the appropriate changes for your purposes.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants