Lines Matching defs:address

9 // This file is a part of AddressSanitizer, an address sanity checker.
178 // In a 32-bit address space, the address calculation will wrap, so this check
241 uptr address, uptr size, DWORD *old_protection) {
242 return ::VirtualProtect((void*)address, size,
248 uptr address, uptr size, DWORD old_protection) {
250 return ::VirtualProtect((void*)address, size,
255 static bool IsMemoryPadding(uptr address, uptr size) {
256 u8* function = (u8*)address;
268 static bool FunctionHasPrefix(uptr address, const T &pattern) {
269 u8* function = (u8*)address - sizeof(pattern);
276 static bool FunctionHasPadding(uptr address, uptr size) {
277 if (IsMemoryPadding(address - size, size))
280 FunctionHasPrefix(address, kHintNop8Bytes))
318 // memory location containing the targeted address. The displacement is still
369 // Clamp {min,max}_addr to the accessible address space.
381 // This loop probes the virtual address space to find free memory in the
385 // considers the probe closest to func_addr. If that address is not free, the
391 // Consider the in-range address closest to func_addr.
460 // address within the module can be referenced with PC-relative operands.
464 // address of the module (e.g. if func_address is in mmap'ed memory), just
558 static size_t GetInstructionSize(uptr address, size_t* rel_offset = nullptr) {
569 if (memcmp((u8*)address, kPrologueWithShortJump1,
571 memcmp((u8*)address, kPrologueWithShortJump2,
577 switch (*(u64*)address) {
582 switch (*(u8*)address) {
635 switch (*(u16*)(address)) {
673 switch (0x00FFFFFF & *(u32 *)address) {
681 switch (0x000000FF & *(u32 *)address) {
687 switch (*(u8*)address) {
692 switch (*(u32 *)(address + 1)) {
708 const u8 next_byte = *(u8*)(address + 1);
716 switch (*(u16*)address) {
758 switch (0x00FFFFFF & *(u32 *)address) {
900 switch (*(u32*)(address)) {
926 switch (0xFFFFFFFFFFULL & *(u64 *)(address)) {
933 switch (*(u8*)address) {
937 switch (*(u16*)address) {
952 switch (0x00FFFFFF & *(u32*)address) {
964 switch (*(u32*)address) {
972 // compiled. In either case, we print the address and 8 bytes of instructions
976 u8 *bytes = (u8 *)address;
980 (void *)address, bytes[0], bytes[1], bytes[2], bytes[3], bytes[4],
987 size_t TestOnlyGetInstructionSize(uptr address, size_t *rel_offset) {
988 return GetInstructionSize(address, rel_offset);
992 static size_t RoundUpToInstrBoundary(size_t size, uptr address) {
995 size_t instruction_size = GetInstructionSize(address + cursor);
1136 // If needed, get memory space for indirect address.
1187 // Check if the targeted address can be encoded in the function padding.
1409 // We have two parallel arrays: the import address table (IAT) and the table