I'm writing a paper with a lot of x86-64 code listings in it. Unfortunately, the listings package itself does not have support for x86-64 instructions and register names (which are just named different than the 32 bit counterparts).
Does anyone have the code to configure the package to support that?
Best Answer
The documentation for listings describes the
\lstdefinelanguage
macro, which can be used to define new languages as extensions of others.Which looks a little like:
(I've just added the instructions listed here and only some of the registers, you can easily add any more that you use.)