answersLogoWhite

0


Best Answer

Suppose that we're talking about C on an x86 32-bit processor it should be 4-bytes (32-bits).

Since the pointer has to be able to hold any memory location it should be the same number of bits as the processor.

User Avatar

Wiki User

15y ago
This answer is:
User Avatar
More answers
User Avatar

AnswerBot

5d ago

The number of bytes in a pointer address can vary depending on the system architecture. It is typically either 4 bytes (32-bit systems) or 8 bytes (64-bit systems).

This answer is:
User Avatar

Add your answer:

Earn +20 pts
Q: How many bytes in a pointer address?
Write your answer...
Submit
Still have questions?
magnify glass
imp
Related questions

How many bytes are read in pointers by pointers dereferencing?

When you dereference a pointer you "read" the number of bytes determined by the pointer's type. That is, a char pointer dereferences a single byte while an int pointer dereferences 4 bytes (assuming a 32-bit int) -- regardless of the type actually stored at that address. However, note that a pointer can only actually point at a single byte since it only has storage for a single memory address. How many additional bytes are dereferenced is entirely dependant on the type of the pointer. To determine how many bytes are actually allocated to an address, use the sizeof operator, passing a dereferenced pointer (the pointer must point at the start of the allocation). If the pointer points at several elements of the same type (an array), then divide the total bytes by the size of the pointer's type to determine the number of elements in the array.


Define pointer in C?

Pointer is a variable, A variable that stores the address of another variable. Size of a pointer is 2 bytes.


How many bites does an IP address have?

In case of IPv4, the address has 4 bytes. In case of IPv6, the address has 16 bytes.


How many bytes are required to store the pointer?

It depends on the platform... In a 16 bit environment, such as DOS or Windows 3.x, a near pointer is two bytes, while a far pointer is 4 bytes. In a 32 bit environment, such as Win32, a pointer is 4 bytes. In a 64 bit environment, such as Win64, a pointer is 8 bytes. If you want to find out in your particular environment, look at sizeof(ptr), where ptr is declared as a pointer to something. char* ptr; std::cout << sizeof(ptr) << std::endl; Note that the size of the pointer is not the same as the size of the object to which it points. If you looked at sizeof(*ptr), you would get 1.


How many types of pointers are there?

That depends on what you consider a type. A pointer variable simply stores a memory address or NULL so, strictly speaking, there is only one type of pointer. A pointer variable's type (int *, char *, void *, etc) determines the type that a pointer points to, not the type of the pointer itself. Whether a pointer points to a primitive type, a user-defined type, a function, another pointer or void, makes no difference to the pointer variable itself. It simply stores a memory address. How you treat that memory address is determined by the pointer variable's type. So, in that respect, there are as many types of pointer as there are types to point at; which would be infinite. The architecture determines the size of a pointer variable. On a 16-bit system, a pointer will occupy just 2 bytes, while on a 32-bit system it occupies 4 bytes and 8 bytes on a 64-bit system. Although these may be considered separate pointer types, you can't pick and choose which type you use. The size must be consistent for any given architecture, hence the prevalent use of the sizeof() operator to determine a variable's length at runtime.


How many bytes a char pointer takes?

In 32 bit address space it will most likely be 4 bytes, since 8 bits is a byte and 32 bits / 8 bits = 4. In 64 bit address space it should be 8 bytes (64 bits / 8 bits = 8). It is architecture dependent so use the sizeof() function.


How many bytes in an IPX network address?

10 bytes - 4 for the network, 6 for the MAC address.


How many bytes does null occupy?

In most languages with a null reference, it is simply a memory address to a zero-length memory block. So the only memory it would occupy in these cases would be enough for a memory pointer: usually around 4 bytes.


What Pointer in Data Structure?

No, pointer is not a data type but a reference to an object. Pointers are used to refer back to an object which can be anything from a large data value or a collection of values or objects.A pointer is a variable and is 4 bytes long because 4 bytes = 32 bits, and all addresses in 32 bit operating systems are 4 bytes long :) , so if you want to store an address somewhere you need 4 bytes. A pointer is just 4 bytes in the memory and in these 4 bytes an address is stored. If you ask the address of an element, like char, int, etc., the address you will get will be the address of the first byte. Only the first byte is saved in the pointer, and then you can manipulate the upcoming bytes.For example you declare a structure of 12 bytes and you name it myStruct.let's say that the address of this structure is the address 0x00400001


How many bytes in a Mac address?

A Mac address (Media Access Control address) is 48 bits long, which is equivalent to 6 bytes.


How many address lines will take to address the 16kilo bytes?

16KB, or 16384 bytes, can be addressed with 14 address lines. (214 = 16384)


What is the need of instruction pointer?

IP(instruction Pointer) is a processor Register IP store the offset address of the next instruction IP can be modified by Jump & call condition IP can Increment by 1,2,3.......bytes Regard:tiger_ucet@yahoo.com