Pointer (computer programming) in the context of Memory address


Pointer (computer programming) in the context of Memory address

Pointer (computer programming) Study page number 1 of 1

Play TriviaQuestions Online!

or

Skip to study material about Pointer (computer programming) in the context of "Memory address"


⭐ Core Definition: Pointer (computer programming)

In computer science, a pointer is an object in many programming languages that stores a memory address. This can be that of another value located in computer memory, or in some cases, that of memory-mapped computer hardware. A pointer references a location in memory, and obtaining the value stored at that location is known as dereferencing the pointer. As an analogy, a page number in a book's index could be considered a pointer to the corresponding page; dereferencing such a pointer would be done by flipping to the page with the given page number and reading the text found on that page. The actual format and content of a pointer variable is dependent on the underlying computer architecture.

Using pointers significantly improves performance for repetitive operations, like traversing iterable data structures (e.g. strings, lookup tables, control tables, linked lists, and tree structures). In particular, it is often much cheaper in time and space to copy and dereference pointers than it is to copy and access the data to which the pointers point.

↓ Menu
HINT:

In this Dossier

Pointer (computer programming) in the context of Dynamic linker

A dynamic linker is an operating system feature that loads and links dynamic libraries for an executable at runtime; before or while it is running. Although the details vary by operating system, typically, a dynamic linker copies the content of each library from persistent storage to RAM, fills jump tables and relocates pointers.

Linking is often referred to as a process that is performed when the executable is compiled, while a dynamic linker is a special part of an operating system that loads external shared libraries into a running process and then binds those shared libraries dynamically to the running process. This approach is also called dynamic linking or late linking.

View the full Wikipedia page for Dynamic linker
↑ Return to Menu

Pointer (computer programming) in the context of Node (computer science)

A node is a basic unit of a data structure, such as a linked list or tree data structure. Nodes contain data and also may link to other nodes. Links between nodes are often implemented by pointers.

View the full Wikipedia page for Node (computer science)
↑ Return to Menu

Pointer (computer programming) in the context of Indirection

In computer science, an indirection is a way of referring to something using a name, reference, or container instead of the value itself. The most common form of indirection is the act of manipulating a value through its memory address. For example, accessing a variable through the use of a pointer. A stored pointer that exists to provide a reference to an object by double indirection is called an indirection node. In some older computer architectures, indirect words supported a variety of more-or-less complicated addressing modes.

Another important example is the domain name system which enables names such as en.wikipedia.org to be used in placeof network addresses such as 208.80.154.224. The indirection from human-readable names to network addresses means that the references to a web page become more memorable, and links do not need to change when a web site is relocated to a different server.

View the full Wikipedia page for Indirection
↑ Return to Menu

Pointer (computer programming) in the context of Reference (computer science)

In computer programming, a reference is a value that enables a program to indirectly access a particular datum, such as a variable's value or a record, in the computer's memory or in some other storage device. The reference is said to refer to the datum, and accessing the datum is called dereferencing the reference. A reference is distinct from the datum itself.

A reference is an abstract data type and may be implemented in many ways. Typically, a reference refers to data stored in memory on a given system, and its internal value is the memory address of the data, i.e. a reference is implemented as a pointer. For this reason a reference is often said to "point to" the data. Other implementations include an offset (difference) between the datum's address and some fixed "base" address, an index, or identifier used in a lookup operation into an array or table, an operating system handle, a physical address on a storage device, or a network address such as a URL.

View the full Wikipedia page for Reference (computer science)
↑ Return to Menu

Pointer (computer programming) in the context of Struct (C programming language)

In the C programming language, struct is the keyword used to define a composite, a.k.a. record, data type – a named set of values that occupy a block of memory. It allows for the different values to be accessed via a single identifier, often a pointer. A struct can contain other data types so is used for mixed-data-type records. For example, a bank customer struct might contain fields for the customer's name, address, telephone number, and balance.

A struct occupies a contiguous block of memory, usually delimited (sized) by word-length boundaries. It corresponds to the similarly named feature available in some assemblers for Intel processors. Being a block of contiguous memory, each field within a struct is located at a certain fixed offset from the start.

View the full Wikipedia page for Struct (C programming language)
↑ Return to Menu

Pointer (computer programming) in the context of Program counter

A program counter (PC) is a register that stores where a computer program is being executed by a processor. It is also commonly called the instruction pointer (IP) in Intel x86 and Itanium microprocessors, and sometimes called the instruction address register (IAR), the instruction counter, or just part of the instruction sequencer.

Usually, a PC stores the memory address of an instruction. Further, it usually is incremented after fetching an instruction, and therefore points to the next instruction to be executed. For a processor that increments before fetch, the PC points to the instruction being executed. In some processors, the PC points some distance beyond the current instruction. For instance, in the ARM7, the value of PC visible to the programmer reflects instruction prefetching and reads as the address of the current instruction plus 8 in ARM State, or plus 4 in Thumb State. For modern processors, the location of execution in the program is complicated by instruction-level parallelism and out-of-order execution.

View the full Wikipedia page for Program counter
↑ Return to Menu