@Preston
I don't know how interested in OGL you are, but Basic4GL has several of the nehe tutorials converted to it. So if you're interested in OGL you might want to give it a look. It certainly would be easier to learn OGL in a BASIC syntax than a C style one.
http://www.basic4gl.net/
@Yellow
"Any resources would be great."
Okay, here it goes.
For the PE file format(Portable Executable. .exes basically) you're going to need several tutorials as I haven't found any of the tutorials out there(and they are few and far between) to be clear enough to be used by itself. I use 4 different sources for my info on the PE file format.
Source 1: Iczelion's PE tutorials
http://win32asm.cjb.net/
This is the first one that I found and it isn't too bad though the examples are in MASM as that is a assembly langauge site.
Source 2: LUEVELSMEYER's Description
http://spiff.tripnet.se/~iczelion/files/pe1.zip
This is the main tut I use and can be found at the bottom of the first tutorial in Iczelion's series. Its pretty good, but it leaves out stuff about the dos stub(i think) and is a little sparse in areas.
Source 3: Tool Interface Standards
http://x86.ddj.com/intel.doc/tools.htm
This is probably the least used tut out of the 4 as it is really sparse on the info it gives out. However, it does provide a visual reference and that may be helpful as you work your way through Source 2.
Source 4: MSDN Magazine
I found this while searching for one of the references listed at the bottom of Source 2. Its the Feburary 2002 edition for Part 1 and March 2002 edition for Part 2.
Part 1:
http://msdn.microsoft.com/msdnmag/issues/02/02/PE/default.aspx
Part 2:
http://msdn.microsoft.com/msdnmag/issues/02/03/PE2/default.aspx
Although it doesn't really go into as much depth as Source 2, some of the figuares that are attached to both parts are priceless as the fill in the gaps missing in Source 2, and better explain certain parts then anything else I've encountered.
It also comes with a improved version of PEDUMP free to download. Source code included!
Speaking of pe examiners, there is a program called PEBrowse that I find to be quite usefull in learning the structure of the PE file format. You can find it here(Note: I'm talking about PEBrowse, NOT PEBrowse Interactive. The former is what you want while the latter is a debugger)
http://www.smidgeonsoft.com
You'll probably also need a hex viewer in the beginning to make sense of things. I use HexCMP 2. There isn't any paticular reason why I use it, it is just the first free Hex viewer I came across that is of decent quality. You can find a free trail version of it here:
http://www.fairdell.com/
Well, that covers .exes and .dlls(they both use the same format: pe!). .Libs I haven't really found any good resources on other the ones listed above, but I really haven't develed into them as much as .exes and by extension, .dlls yet.
As for software optimization, I found a really good resource by accident while I was browsing the menuetOS site that someone posted a link to earlier.
http://www.agner.org/assem/
That site is a godsend for software optimizers. I've learned quite a bit from his How to Optimise for Pentiums pdf that is very up to date.
Also, the links at the bottom of the page are proving to be useful as well as I managed to find a few of intel's volumes on their microprocessors that are bound to be a gold mine of info.
There are two volumes that I found that really described the Opcodes pretty good. They also describe what those obsure acronyms I keep running into mean like imm and rel32. I found
that pretty handy.
Volume 2 a. Instruction Set reference A - M.
http://developer.intel.com/design/pentium4/manuals/253666.htm
Just go to the bottom of the page to where it says US ftp server and click there. It'll start downloading the pdf.
Volume 2 b. Instruction Set reference N - Z.
http://developer.intel.com/design/pentium4/manuals/253667.htm
The second half of the above volume. Same instructions apply for d/ling it.
There is a third volume off that site that deals with System programming that seems to be quite interesting. I haven't really got into it yet, but I'm pretty sure that it will come in handy later when I'm trying to write the assembler portion of my compiler.
Volume 3 System Programming Guide
http://developer.intel.com/design/pentium4/manuals/253668.htm
That's about all I have for now. I haven't really begun searching for resources on optimizing for AMD processors yet so I'll probably do that next.
Hope these resources help.