Re: Fix typo 586/686 in atomics/arch-x86.h
Zsolt Parragi <zsolt.parragi@percona.com>
From: Zsolt Parragi <zsolt.parragi@percona.com>
To: John Naylor <johncnaylorls@gmail.com>
Cc: Daniel Gustafsson <daniel@yesql.se>,
Jakub Wartak <jakub.wartak@enterprisedb.com>, PostgreSQL Hackers <pgsql-hackers@lists.postgresql.org>,
Andres Freund <andres@anarazel.de>
Date: 2025-12-20T07:38:59Z
Lists: pgsql-hackers
It seems this is dependent on the linux distribution. I assumed gcc uses the same march on all modern linux distributions, but that doesn't seem to be the case. OL 8/9/10, Gentoo, Arch seem to keep the x86-64 march even when you specify -m32: bash-5.2# gcc -m32 -Q --help=target | grep march -march= x86-64 Known valid arguments for -march= option: bash-5.2# gcc -Q --help=target | grep march -march= x86-64-v3 Known valid arguments for -march= option: But Ubuntu/Debian changes march to i386 when you do that: ❯ gcc -m32 -Q --help=target | grep march -march= i686 Known valid arguments for -march= option: ❯ gcc -Q --help=target | grep march -march= x86-64 Known valid arguments for -march= option: Gcc version doesn't seem to change this even if I install multiple gcc versions on the same setup.