Follow @Openwall on Twitter for new release announcements and other news
[<prev] [next>] [day] [month] [year] [list]
Date: Mon, 08 Aug 2016 01:47:11 -0700
From: <writeonce@...ipix.org>
To: john-dev@...ts.openwall.com
Subject: RE: x86-64.S Win64 support

> On Sun, Aug 07, 2016 at 05:47:57PM -0700, writeonce@...ipix.org wrote:
> > As part of alpha release preparation we've added JtR to midipix_build.sh
> > for inclusion in the release tarball. After reading this thread I went
> > on to test the binary, then realized that x86-64.S was still an open
> > issue due to the different calling conventions. As all global functions
> > in x86-64.S take two arguments at the most, I went ahead and patched the
> > relevant spots using #ifdef __PE__ and a push-mov-pop wrapping method
> > (note that in the WIN64 ABI, both %rdi and %rsi are nonvolatile
> > registers). After applying the attached patch, all tests passed.
> > Attached log is from a Dell Latitude E5450, JtR built with -g3 -O2, musl
> > libc and libpsxscl built with -g3 -O0.
> 
> Thanks for the patch.
> 
> Looking at x86-64.S in jumbo, I see it also saves/restores %xmm6 through
> %xmm15 when building for Win64. Perhaps this is unnecessary in a build
> with midipix, since musl does not currently use those registers and JtR
> core does not use any other libraries. But this may be something to
> include if I apply a patch like this to the core tree. Or at least
> there should be a comment added about this piece missing. Otherwise it
> could be an unpleasant surprise to someone when things are neither fully
> working nor fully broken in a non-midipix Win64 build of the core tree.
> 
> Alexander

Good point, and after looking at the jombo patch I thought it might be
best to have the same prologue/epilogue (and less #ifdef's) in both
projects. Attached an updated patch with a reference comment.


View attachment "john.diff" of type "text/x-diff" (7934 bytes)

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.