I have homemade NAS equipped with an embedded Atom D510 (dual-core 1.66 GHz) running Gentoo like a charm. I started from an amd64 stage3 and, from there, installed every ebuild with -march=native in $CFLAGS.

Now, I'd like to upgrade it to an i5-2400S. But before buying and taking all the components apart (major endeavour in a small mini-ITX case), I'd like to know:

Are all current binaries compatible with both CPUs? Or should I re-emerge system + world with a different -march before swapping the motherboard + CPU?

Without knowing much about i5 I'd say you are safe. System files do not depend much on CFLAGS, I had once a successful upgrade from AMD to Intel, it booted up no problem ... had to do emerge -e world to get some user apps working, though. Not to mention the kernel which I prepared for new hardware indeed._________________Please learn how to denote units correctly!

Political Correctness is all about replacing imaginary injustice with real injustice.

You should be able to diff the flags list with what you get on your Atom box and see if anything is missing. I very much doubt it will, Intel is usually pretty good about backwards compatibility. Of course, removing "march=native" and running an "emerge -e @system" can't hurt (I recently switched from a Phenom to the i5 and it was necessary then) and shouldn't take too long -- that way at least you'll know you'll end up with a working toolchain. You'll also want to make sure your kernel is OK (ie, has all your drivers), but that should be pretty straight-forward.

Thank you both for your replies. Very much appreciated! If I go through with the upgrade (still evaluating several options), I'll "emerge -e @system" (at least) and adjust the kernel configuration, and keep you posted.