I'd like to submit this patchset for review, and hopefully for inclusion into the test source base. I'm a little reluctanct to do the checkin myself, at least not without independent review. The purpose is to fix problems in calling a function by way of taking its address and calling through that address. So far I've located those problems in the mmap and mprotect tests, specifically those which call the utility function vsrt_creat_exec_file. There may be other such assumptions in the code base, but if so, that's for another fix. They fix failures on mmap_P 3 and 4, and mprotect_P 4. To quote David Mosberger on the topic (with reference to a small test program he was supplied): The test program assumes that taking the address of a function returns the entry-point address of that function. This is not so on ia64 (and several other arches, including VAX, PA-RISC, and PPC, I believe). Instead, what you get on ia64 is a pointer to a function descriptor: struct fdesc { void *ip; /* entry point (code address) */ void *gp; /* global-pointer */ }; The patches as written are totally Itanium-specific and have no effect if not compiling __ia64__. If this code applies to other architectures, someone else will have to make those additions. I've sent the patchfile as an attachment so it doesn't suffer line-wrap problems. Mats
Attachment:
EXEC-FIX.ZIP
Description: Binary data