[Mono-dev] Patch for IPAddress.cs
Miguel de Icaza
miguel at novell.com
Sun Mar 25 02:17:24 EDT 2007
> x86 actually has an instruction whose sole purpose is to invert the byte
> order of a 32-bit value. Look up BSWAP. It requires at least a 486, though.
> Does mono otherwise run on 386 CPUs presently? If it is okay to exclude 386
> systems (or they can be detected on-the-fly and given the alternative 3
> instructions), then perhaps it would be possible to do something like
> marking it as an icall and having the JIT recognize that method and inline
> it as just a BSWAP.
Well, we can detect if the CPU is a 486 or better, and if so use the
instruction instead of our own code.
This would come in handy for BitConverter and DataConverter as well.
More information about the Mono-devel-list