patch to add aes and pclmulqdq instructions to gcc

John-Mark Gurney jmg at funkthat.com
Thu Jan 17 07:05:24 UTC 2013


Mike Belopuhov pointed me to the patch in OpenBSD:
http://freshbsd.org/commit/openbsd/0babc91a00b1f1953637bb39c8ec97aef704629e/diff.txt

While OpenBSD's binutils is quite different than FreeBSD's, I was able
to use his patch to teach binutils how to assemble and disassemble the
aes and pclmulqdq instructions.

I have done basic tests, such as verified that it can assemble the aesni
module and get the same results, and assemble a sample file for
pclmulqdq..  For each of these tests, I have verified that it's output
matches (as close as possible, as gcc/clang compile callq's differently)
clang on amd64..

I have attached the patch, and it is also availble at:
http://people.freebsd.org/~jmg/gcc.aes.patch

Comments?

I have not passed it through a make universe yet, but will before
committing...

I am also working on basic intrinsics header files for these instructions
too...

-- 
  John-Mark Gurney				Voice: +1 415 225 5579

     "All that I will do, has been done, All that I have, has not."
-------------- next part --------------
A non-text attachment was scrubbed...
Name: gcc.aes.patch
Type: text/x-diff
Size: 8833 bytes
Desc: not available
URL: <http://lists.freebsd.org/pipermail/freebsd-toolchain/attachments/20130116/e912df80/attachment.patch>


More information about the freebsd-toolchain mailing list