[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: Problem with VIA C3 chip and libcrypto

"Oliver M. Bolzer" <oliver@gol.com> writes:

> On Mon, Nov 04, 2002 at 09:23:16AM +0000, Ricardo Javier Cardenes Medina <rcardenes@debian.org> wrote...
> > On Sun, Nov 03, 2002 at 12:13:07PM +0100, Michael Karcher wrote:
> > > take profit of these instructions, but It seems likely. Is there any way to
> > > select libraries based on 'instruction set' instead of architecture, so
> > > the VIA C3 could get code 'without cmov', the PII 'with cmov and MMX',
> > > the PIII 'with cmov, MMX and SSE' and an Athlon processor 'with cmov, MMX
> > > and 3D now!', although they all are 'family: 6'.
> > 
> > See at the end of /proc/cpuinfo. The "flags" field. For my Duron:
> > 
> > flags           : fpu vme de pse tsc msr pae mce cx8 sep mtrr pge mca cmov
> >                   pat pse36 mmx fxsr syscall mmxext 3dnowext 3dnow
> The problem with OpenSSL is, that it is hand-assembly. The author is using
> the cmov instruction for an i686-optimized routine, though that instruction
> is not guranteed to be available. 

This is wrong. The cmov instruction is NOT used in the assembly
routines. Also there are only assembly routines for i586. The cmov
instruction comes in through the usage of the -mcpu=i686 flag of
gcc. cmov is optional in i686, so gcc should not use it.


Christoph Martin, EDV der Verwaltung, Uni-Mainz, Germany
 Internet-Mail:  Christoph.Martin@Uni-Mainz.DE
  Telefon: +49-6131-3926337

Reply to: