Near, far, and huge pointers are different types of pointers used to reconcile the different addressing models of the Intel 8086/8088 class processors, running in a 16-bit operating system such as Windows 3.x, as well as any of the newer incarnations running in real mode or virtual 8086 mode.
A near pointer can address something within one 64Kb memory segment, containing only an offset, and it takes two bytes. The segment is implied by context, and is usually the data segment, selected for the addressing model.
A far pointer can address anything in the 1Mb memory1, containing both a segment and an offset, and it takes four bytes.
A huge pointer is a normalised far pointer, which means its offset part is always between 00H and 0FH.
In 32-bit mode a pointer can address anything in 4Gb memory, containing a flat 32-bit offset, and it takes four bytes. (In this mode segments have no significance.) It only works, however, when there is support for it, such as the WIN32 extension of Windows 3.x.
---------------------------------------------------------------------------------------
1In the 80286 or higher, running in protected mode, in OS/2, the segment portion of the pointer is actually a descriptor selector, so 1Mb addressibility depends on the operating system environment.
far huge near pointer is an oxymoron. far points to memory outside of the normal address space. near points to memory within the normal address space, is the default, and usually is not needed. I've never seen huge before. What is the target architecture?
Near, far, and huge pointers are a construct (usually) in the Win16 environment running on an 8086/8088 or later in real mode, such as Visual C/C++ 1.52. In this environment, near pointers are 16 bits, and far and huge pointers are 32 bits.
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.
There are 8 bytes in a double
A single-byte type of array has 1 byte per character; a wide-character array has 2 bytes per character of storage. Without seeing the exact definition it cannot be determined what the actual size of the array would be.
how many bytes are there in a 64-bit machine? Another Answer: It takes 8 bytes to store a 64 bit number.
640 x 1024 x 1024 bytes (data transfer) 640 x 1000 x 1000 bytes (storage)
It all depends on the length and data type of the array...
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.
1073741824 bytes or 10243 bytes or 230 bytes
1024 bytes
536870912 Bytes
1024 bytes
how many bytes are needed to structure PCB Also explain different purposes of these bytes
128 megabytes equals 134,217,728 bytes.
125000 bytes Wrong. 1MB has 1048576 bytes.
847,263 bytes is 827.405273KB 1 kilobyte is equal to 1024 bytes. Bytes / 1024 (bytes in a kilobyte) = kilobytes 847,263 bytes / 1024 (bytes in a kilobyte) = 827.405273 kilobytes
1027254 bytes equals .97 megabytes
0.075