This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [PATCH] Support asan-fixed-shadow-offset in GCC


It is required for Kernel AddressSanitizer, as the shadow offset is
not known at the compile time,

To get shadow offset this patch uses function __asan_get_shadow_ptr.
Wouldn't be more effective just to read variable instead of function call?

Depends on how much logic you want to hide there. If it's just "return something" than sure but if you need some synchronization or complex calculations, accessing global would not be enough.

-Y


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]