Relay-Version: version B 2.10 5/3/83; site utzoo.UUCP Posting-Version: version B 2.10.3 4.3bsd-beta 6/6/85; site decwrl.DEC.COM Path: utzoo!watmath!clyde!burl!ulysses!bellcore!decvax!decwrl!dec-rhea!dec-kirk!williams From: williams@kirk.DEC (John Williams 223-3402) Newsgroups: net.lang.c Subject: Creating functions in data space Message-ID: <1486@decwrl.DEC.COM> Date: Tue, 4-Mar-86 08:08:56 EST Article-I.D.: decwrl.1486 Posted: Tue Mar 4 08:08:56 1986 Date-Received: Wed, 5-Mar-86 06:25:10 EST Sender: daemon@decwrl.DEC.COM Organization: Digital Equipment Corporation Lines: 19 In response to George Tomasevich: I will say right off that bat that I haven't tried this. It appears to me, however, that the problem is how C handles memory management. This seems to me to be very machine dependent, even compiler dependent. I'm sure that the compiler, in any event, would spit all kinds of warnings at you. Perhaps a way around it would be to gain access somehow to the memory management register, have a function that flips a bit just before calling the data code, and cleans up afterwards. Perhaps the problem is that C allows you to have identically named functions and variables, but you could get around that as well. Perhaps the function that calls the coded data should be written in assembly, to account for the machine dependency, with conditional linking to maintain portability. I'm not convinced that the whole thing can be done in C, but by the same token, I don't see that the whole thing has to be written in assembly, either. John.