Follow @Openwall on Twitter for new release announcements and other news
[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Date: Tue, 29 Oct 2013 23:39:13 +0100
From: magnum <>
To: "" <>
Subject: Linux-X32 support for DES_BS_ASM


After warming up with Win64 I thought I'd have another go at enabling 
DES_BS_ASM for Linux-X32. Contrary to Win64, X32 is exactly like AMD64 
except pointers and longs are 32-bit. The NT assembler works fine as-is, 
my problem is DES.

I was hoping to get away with concentrating on these:

/* Sun's assembler can't multiply, but at least it can add... */
#define nptr(n)				n+n+n+n+n+n+n+n
#define nvec(n)				n+n+n+n+n+n+n+n+n+n+n+n+n+n+n+n

I'm thinking if these are solely used for pointers and vectors 
respectively, only the first should be changed and this could work:

#ifdef __ILP32__
#define nptr(n)				n+n+n+n
#define nptr(n)				n+n+n+n+n+n+n+n
#define nvec(n)				n+n+n+n+n+n+n+n+n+n+n+n+n+n+n+n

...but I have tried that before (and other variants) to no avail. Are 
you able to give a quick hint?

Perhaps a few constants need a change, such as in this line:

	subq $nvec(0x300+48),k_ptr


Powered by blists - more mailing lists

Confused about mailing lists and their use? Read about mailing lists on Wikipedia and check out these guidelines on proper formatting of your messages.