Write enable .text section
Meissner, Michael
michael.meissner@amd.com
Thu Mar 23 20:14:00 GMT 2006
It depends on the operating system you are using as well as the linker.
If you are using the GNU linker, you can do what you want by using
linker scripts, but these are very arcane.....
I have worked on platforms where it was impossible to write self
modifying code in any fashion, and on many other systems where you had
to go through various hoops to make sure all of the caches are flushed
properly (the trampoline code within the compiler generates self
modifying code).
-----Original Message-----
From: gcc-help-owner@gcc.gnu.org [mailto:gcc-help-owner@gcc.gnu.org] On
Behalf Of William
Sent: Monday, March 13, 2006 10:59 PM
To: gcc-help@gcc.gnu.org
Subject: Write enable .text section
Hi, I'm trying to implement some self-modifying code.
Usually I use Visual C++ so I'm not too familiar with the linker that
gcc uses. I can't figure out how to enable write for the .text section
so I don't get an access violation when the SMC runs. Anyone can help?
Thanks!
__________________________________________________
Do You Yahoo!?
Tired of spam? Yahoo! Mail has the best spam protection around
http://mail.yahoo.com
More information about the Gcc-help
mailing list