[ros-dev] object types (was [ros-svn] [ion] 12748: Fix incorrect LPC Object ...)

Hartmut Birr hartmut.birr at gmx.de
Mon Jan 3 22:09:49 CET 2005


Hi,

I've add the following line to my test driver:

extern __attribute__((dllimport)) POBJECT_TYPE* ExEventObjectType;

 DbgPrint("%x %x %x %x\n",
                ExEventObjectType,
                *(PULONG)ExEventObjectType,
                MmGetSystemRoutineAddress(&NameU),
               *(PULONG)MmGetSystemRoutineAddress(&NameU));

Running on W2K, I get this result:

GCC:       81ebd540 81ebd440 8047a888 81ebd540

MSVC:    8047a888 81ebd540 8047a888 81ebd540

Running on ROS:

GCC:      c0692ef8 54545645 c00e0760 c0692ef8

MSVC:   c00e0760 c0692ef8 c00e0760 c0692ef8

It seems that GCC and MSVC does handle imported data symbols different. 
In MSVC is an imported data symbol a pointer to the variable and in GCC 
the value of the variable.

- Hartmut


More information about the Ros-dev mailing list