davoli@natinst.com (Russell Davoli) (01/17/91)
Recently, Rob Mitchell at BBN Systems & Technology asked me how I get the listings of the assembly code generated by THINK C that I posted to the net. I tried to return Rob's email to no avail, so for Rob and anyone else interested here's my response. I don't know of any way to do this with just THINK C. In MacsBug, I turned logging on and dissassembled the function. The function must be in memory, so you disassemble it when you're running you're application or driver or whatever. Another way that sometimes works is to load the code or driver resource in Resedit (use the hex editor to open the resource), then do what I described above. These methods work nicely, but it's a pain to do. It'd be really nice if THINK provided something to list their code from within the THINK C environment so you could optimize some stuff by hand when you need to. I've tried the DumpCode tool in MPW, but that tool doesn't really understand the THINK C generated code and screws up some things, although I don't remember what. If anyone who reads this knows of any other ways to accomplish this, esp. without having to leave THINK C, I'd be interested. Russell Davoli National Instruments