Click here to Skip to main content
15,908,274 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
GeneralRe: CButton and DialogBar Pin
Ravi Bhavnani18-Mar-03 10:54
professionalRavi Bhavnani18-Mar-03 10:54 
GeneralRe: CButton and DialogBar Pin
MemLeak19-Mar-03 7:38
MemLeak19-Mar-03 7:38 
GeneralRe: CButton and DialogBar Pin
Ravi Bhavnani19-Mar-03 8:14
professionalRavi Bhavnani19-Mar-03 8:14 
GeneralAviCap Questions Pin
User 1278218-Mar-03 10:13
User 1278218-Mar-03 10:13 
GeneralSAPI 5.1 and Win98... Pin
JoeSox18-Mar-03 9:42
JoeSox18-Mar-03 9:42 
GeneralRe: SAPI 5.1 and Win98... Pin
Tim Smith18-Mar-03 9:54
Tim Smith18-Mar-03 9:54 
GeneralRe: SAPI 5.1 and Win98... Pin
JoeSox19-Mar-03 9:43
JoeSox19-Mar-03 9:43 
GeneralVery interesting Question about Compilers Pin
Joel Holdsworth18-Mar-03 9:36
Joel Holdsworth18-Mar-03 9:36 
.... Well I though it was interesting. I'll start off with some background...

I am making this really cool app - it's really a super flexible imaging enviroment. One of its distinctive features is it's XML plugins. Each XML plugin contains a payload of C++ code plus a few other bits and pieces. So the app slots the pieces of C++ code from various XML plugins together and then runs them through a 3rd party compiler to make a "Processor" DLL, which the main app then loads and runs. This is useful because it allows the program to be fast and completly flexible even to the level of allowing users to edit the way image are created right down to the code!

Ok so really I have a couple of questions...
When you compile you get obj file which are subsequently passed through the linker. So what does the obj file contain? - I was under the impression that there was machine code in there. So if this is the case is it possible to load this machine code into memory manually, then use the beginning of the buffer as a function pointer, and then run the code that way?

This would be advantagous because I could cache machine code much more efficiently than keeeping loads of DLLs around. And instead of slotting together C++ I could cut and paste machine code together, so an XML plugin would only need recompiling every time the code was edited; and all the host would have to do is put the relevant machine code together then run it - all in memory - instead of clumsy compiling and temporaries and modules and stuff. Also cutting out the Linker would give obvious speed improvments, even I didn't do any machine code cut and pasting!!! On the other hand I was a bit worried because cutting out the linker might mess things up... Like the Implicit linking of the "Processor" DLL to the module... Can this worked around?

I realise this is a leviathon of topic, so I would be more than happy if somone could point me in the direction of a good source of information... Dynamic processing engines in general...

Anyway thanks for your time!!!


With time we live, with money we spend!
Joel Holdsworth.

GeneralRe: Very interesting Question about Compilers Pin
Chris Losinger18-Mar-03 10:31
professionalChris Losinger18-Mar-03 10:31 
GeneralRe: Very interesting Question about Compilers Pin
Joel Holdsworth18-Mar-03 10:45
Joel Holdsworth18-Mar-03 10:45 
GeneralRe: Very interesting Question about Compilers Pin
Neville Franks18-Mar-03 10:55
Neville Franks18-Mar-03 10:55 
GeneralRe: Very interesting Question about Compilers Pin
Joel Holdsworth18-Mar-03 11:26
Joel Holdsworth18-Mar-03 11:26 
GeneralRe: Very interesting Question about Compilers Pin
Neville Franks18-Mar-03 12:29
Neville Franks18-Mar-03 12:29 
GeneralON_THREAD_MESSAGE Pin
clintsinger18-Mar-03 9:20
clintsinger18-Mar-03 9:20 
GeneralRe: ON_THREAD_MESSAGE Pin
Dave Bryant18-Mar-03 9:38
Dave Bryant18-Mar-03 9:38 
QuestionWell, when I use cstringVar.GetBuffer() I need to call ReleaseBuffer, but if I (LPTSTR)(LPCTSTR)cstringVar? Pin
Joan M18-Mar-03 9:10
professionalJoan M18-Mar-03 9:10 
AnswerRe: Well, when I use cstringVar.GetBuffer() I need to call ReleaseBuffer, but if I (LPTSTR)(LPCTSTR)cstringVar? Pin
Dave Bryant18-Mar-03 9:33
Dave Bryant18-Mar-03 9:33 
AnswerRe: Well, when I use cstringVar.GetBuffer() I need to call ReleaseBuffer, but if I (LPTSTR)(LPCTSTR)cstringVar? Pin
Tim Smith18-Mar-03 9:34
Tim Smith18-Mar-03 9:34 
GeneralRe: Well, when I use cstringVar.GetBuffer() I need to call ReleaseBuffer, but if I (LPTSTR)(LPCTSTR)cstringVar? Pin
Joan M20-Mar-03 5:05
professionalJoan M20-Mar-03 5:05 
GeneralATL Object Wizard Pin
DuFF18-Mar-03 8:59
DuFF18-Mar-03 8:59 
GeneralCombine multiple images into one Pin
AWebDude18-Mar-03 8:59
AWebDude18-Mar-03 8:59 
GeneralRe: Combine multiple images into one Pin
Maximilien18-Mar-03 9:07
Maximilien18-Mar-03 9:07 
GeneralRe: Combine multiple images into one Pin
AWebDude18-Mar-03 9:34
AWebDude18-Mar-03 9:34 
GeneralRe: Combine multiple images into one Pin
Larry Antram18-Mar-03 10:05
Larry Antram18-Mar-03 10:05 
GeneralSort Pin
Anthony988718-Mar-03 7:16
Anthony988718-Mar-03 7:16 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.