对于后一个主题,我选择实现一个并发堆栈并解释设计这种数据结构涉及的一些问题。
For the latter topic, I have chosen to implement a concurrent stack and highlight some of the issues in designing such a data structure.
正如你可能知道的那样,堆栈是一种数据结构,被用来以后入先出的模式增加或移除条目。
As you probably know, a stack is a data structure that is used to add and remove items in a last-in, first-out manner.
当数组用于实现诸如堆栈或环形缓冲区之类的数据结构时,会出现另一种形式的对象游离。
Another form of object loitering arises when arrays are used to implement data structures such as stacks or circular buffers.
实现作用域内当前名称空间声明堆栈的数据结构。
NsStack: a data structure that implements a stack of namespace declarations that are currently in scope.
虚拟堆栈与实际堆栈类似,是一种后进先出(LIFO)的数据结构,可以用来临时存储函数参数和函数结果。
The virtual stack -- like a real stack -- is a last in-first out (LIFO) data structure that temporarily stores function arguments and function results.
这个堆栈没有锁;这种无锁的并发数据结构也称为非阻塞数据结构。
No locks will be included; this kind of lock-free, concurrent data structure is also referred to as a non-blocking data structure.
在内核中,普通进程有若干数据结构与之关联,包括一个堆栈,进程控制块(PCB)。
A normal process has a number of data structures associated with it in the kernel, including a stack and process control block (PCB).
该数据结构可以用于许多问题(包括普通堆栈能使用的场合)求解的过程之中。
It can be used in the procedures of solving many problems, including those in which the usual stack can be used.
设计了任务堆栈和硬件堆栈的数据结构,详尽的描述了移植的工作及实现的过程。
Have designed the data structure of the task stack and hardware stack, the course worked and realized transplanted in exhaustive description.
该算法通过引入邻接矩阵并借助自定义的堆栈数据结构来完成控制流路径子集的生成。
The control flow paths in the subset are based on the strategy that the loop statements in the program execute less than twice.
这个简单的设计,可能是因为数据遵循严格的后进先出顺序,这意味着没有复杂的数据结构需要跟踪堆栈的内容-一个简单的指针的堆栈的顶部就可以了。
This simple design, possible because the data obeys strict LIFO order, means that no complex data structure is needed to track stack contents – a simple pointer to the top of the stack will do.
这个简单的设计,可能是因为数据遵循严格的后进先出顺序,这意味着没有复杂的数据结构需要跟踪堆栈的内容-一个简单的指针的堆栈的顶部就可以了。
This simple design, possible because the data obeys strict LIFO order, means that no complex data structure is needed to track stack contents – a simple pointer to the top of the stack will do.
应用推荐