乳头湿疹用什么药| 梦到被狗咬是什么意思| 为什么会长水泡| 大体重减肥做什么运动| 牛筋面是什么做的| alan什么意思| 李思思为什么离开央视| 什么茶不能喝| 腰肌劳损有什么症状| 补气补血吃什么好| 生物工程学什么| 补脾吃什么好| 1为什么读yao| hpv阳性意味着什么| 肺纹理增粗是什么意思| 玻璃结节是什么意思| 三个毛念什么字| 晨尿很黄是什么原因| 田螺小子是什么意思| 考教师资格证需要什么条件| 12月10日是什么星座| 小海绵的真名叫什么| 小孩感冒吃什么饭菜比较好| au585是什么金| 幽门螺杆菌感染有什么症状| 玄关画挂什么图最好| 嘴唇发黑什么原因| 睾丸肿大吃什么药| 氨糖有什么功效| 什么贝壳| 6月23日是什么星座| 什么是抗凝药物| 什么的李逵| 再接再厉是什么意思| 外甥像舅舅有什么说法| 6月9日什么星座| 药店最怕什么样的举报| 9.21是什么星座| 嘴馋是什么意思| 电视剧靠什么赚钱| 58岁属什么生肖| 眦是什么意思| 6月初三是什么日子| 男性生殖长水泡是什么原因| 铁观音是属于什么茶| 什么是偏财| 取什么补什么| 红曲是什么| 知觉是什么意思| 梦见穿裤子是什么意思| 梦到吃螃蟹是什么意思| 曦字五行属什么| 沉住气是什么意思| 收孕妇尿是干什么用的| 指甲不平有凹凸是什么原因| 今天什么年| 女人脱发是什么原因| badus是什么牌子的手表| 儿童风寒感冒吃什么药| 上面一个山下面一个今读什么| 不明原因发烧挂什么科| 流明是什么意思| 自贸区什么意思| 丙类药一般是什么药| 消症是什么意思| b型血和o型血生的孩子是什么血型| 眼压高有什么症状| 茔是什么意思| 什么药治便秘最好最快| va是什么车牌| 眼皮老是跳是什么原因| 清清什么| 7月1日是什么星座| 梅毒螺旋体抗体阴性是什么意思| 什么是经络| 巨细胞病毒igm阳性是什么意思| 破伤风针什么时候打| 梦见鹦鹉是什么征兆| 46岁属什么| 白化病是什么能活多久| 倒着走路有什么好处| 叉烧肉是什么肉| 什么情况下需要打破伤风针| 什么是极光| 凌晨3点多是什么时辰| 突然是什么意思| 白虎痣是什么意思| 牛油果什么味道| 盆底肌高张是什么意思| 狗狗感冒了是什么症状| 十二月七号是什么星座| 太阳鱼是什么鱼| 折服是什么意思| 瞳字五行属什么| 85年什么命| 长乘宽乘高算的是什么| 王八看绿豆是什么意思| 副军级是什么级别| 什么的烤鸭| 益生菌不能和什么一起吃| 飞蚊症是什么症状| 桑叶有什么功效| 悠闲惬意什么意思| 男生属鸡和什么属相配| 幡然醒悟是什么意思| 王爷的儿子叫什么| 羊奶粉和牛奶粉有什么区别| 五福是什么生肖| 勾践姓什么| 蜜蜡脱毛有什么危害吗| 行政工作主要负责什么| 鸢的俗称是什么| 除了胃镜还有什么检查胃的方法吗| 老年人全身无力是什么原因| 血细胞分析能查出什么| 什么是保守治疗| 阿尔茨海默病吃什么药| 麻醉剂是什么| 肠易激综合征吃什么药| 吃什么吐什么喝水都吐怎么办| no是什么| cpu是什么意思| 心机是什么意思啊| 鲁蛇是什么意思| 为什么屎是臭的| 本垒打是什么意思| hds是什么意思| 卧底是什么意思| 练八段锦有什么好处| 柿子和什么不能一起吃| 3月31号什么星座| 强磁对人体有什么危害| oversize风格什么意思| 阿修罗道是什么意思| 王加玉念什么| 茯苓是什么味道| 头部紧绷感是什么原因| 手指甲空了是什么原因| 小鹿乱撞是什么意思| 戒手淫有什么好处| oo什么意思| 日语一库一库是什么意思| 傲慢表情是什么意思| 甲状旁腺激素高吃什么药| 草鱼喜欢吃什么| 平行班是什么意思| 血糖高什么水果不能吃| 激光脱毛和冰点脱毛有什么区别| 老年斑用什么药膏可以去掉| palace是什么牌子| 什么米之乡| 什么映雪| 中暑吃什么药| 吉数是什么数字| 脚掌痒是什么原因| 6.4是什么星座| 彩超能检查什么| 甲木命是什么意思| 里字五行属什么| 格列卫是什么药| 心脏不舒服看什么科室| 心脏骤停是什么原因引起的| 芈姝结局是什么| 鲁班是干什么的| 农历5月20日是什么星座| 来大姨妈能喝什么饮料| 脾脏大是什么原因| 哨兵是什么意思| 宵字五行属什么| 治疗灰指甲用什么药| 兔唇是什么原因造成的| 海澜之家是什么档次| 血分析能查出什么| cj什么意思| 人为什么会长智齿| 息肉和囊肿有什么区别| 炸鸡翅裹什么粉| 穆斯林为什么不吃猪肉| 七月十一是什么星座| 风湿病是什么引起的| 电信积分有什么用| 文房四宝是什么| 月经来潮是什么意思| amy什么意思| 维生素b2有什么功效| 打喷嚏代表什么| 晖字五行属什么| 踮脚尖有什么好处| 手指盖空了是什么原因| 桑枝是什么| 为什么水能灭火| 焦急的什么| 胃酸想吐是什么原因| 分分钟都妙不可言是什么歌| 手心脱皮是什么原因| 罗嘉良为什么娶苏岩| KT是什么| colombo是什么牌子| 十月十日是什么星座| 口嫌体正直是什么意思| 吃什么助消化| 武五行属什么| 夜夜笙歌什么意思| 红螺寺求什么最灵验| 格局小是什么意思| 孔明属什么生肖| 法图麦在回族什么意思| 附睾炎吃什么药最有效| 35是什么意思| 1893年是什么年| 纳少是什么意思| 处女座女和什么星座最配| 空气净化器有什么作用| 如果是什么意思| 男朋友发烧该说些什么| 什么样的水果| 蛇吃什么食物| plump什么意思| 女生喝红牛有什么影响| 脚踝肿是什么原因引起的| 奥运五环绿色代表什么| 口水多是什么原因引起的| 三月三号是什么星座| 学医需要什么条件| 电解质水是什么| 吃什么促进卵泡发育| 杏花什么季节开| 不care是什么意思| 教科书是什么意思| 美国人喜欢什么颜色| 短pr间期是什么意思| 再创佳绩是什么意思| 什么是前鼻音和后鼻音| 同型半胱氨酸高吃什么药| 什么体质容易长结石| 吃什么助眠| 吃什么补血效果最好| 早泄吃什么药| 胃病挂什么科| mh是什么单位| 黑眼圈是什么原因导致的| 深夜里买醉是什么歌| 今天属什么生肖老黄历| 南乳是什么| 奥美拉唑治什么病| 肚子怕冷是什么原因该怎么办| 柿子像什么| 亚麻籽是什么植物| 北京是什么省| 孩子第一次来月经要注意什么| 大豆指的是什么豆| 太阳穴疼什么原因| 乌鸡炖什么好吃又有营养| 家里进鸟了是什么预兆| 泪囊炎用什么眼药水| 胆囊息肉吃什么药| 为什么说| 眼睛胀痛是什么原因| 四月十七号是什么星座| 凉茶是什么茶| 颠鸾倒凤什么意思| 晚上11点到12点是什么时辰| 三十六计最后一计是什么| 皮赘是什么| 百度

财政部部长:房地产税立法、个税改革正稳步推进

百度 对此,有岛内网友在网络论坛上质疑,身为民进党党主席的台湾地区领导人蔡英文,难道不知道乱斗会影响票数?不吭声是故意要让民进党垮吗?不过,另一名网友就回应,这你就太小看蔡英文了,她现在放任DPP(民进党)乱斗有两点。

Memory ordering is the order of accesses to computer memory by a CPU. Memory ordering depends on both the order of the instructions generated by the compiler at compile time and the execution order of the CPU at runtime.[1][2] However, memory order is of little concern outside of multithreading and memory-mapped I/O, because if the compiler or CPU changes the order of any operations, it must necessarily ensure that the reordering does not change the output of ordinary single-threaded code.[1][2][3]

The memory order is said to be strong or sequentially consistent when either the order of operations cannot change or when such changes have no visible effect on any thread.[1][4] Conversely, the memory order is called weak or relaxed when one thread cannot predict the order of operations arising from another thread.[1][4] Many na?vely written parallel algorithms fail when compiled or executed with a weak memory order.[5][6] The problem is most often solved by inserting memory barrier instructions into the program.[6][7]

In order to fully utilize the bandwidth of different types of memory such as caches and memory banks, few compilers or CPU architectures ensure perfectly strong ordering.[1][5] Among the commonly used architectures, x86-64 processors have the strongest memory order, but may still defer memory store instructions until after memory load instructions.[5][8] On the other end of the spectrum, DEC Alpha processors make practically no guarantees about memory order.[5]

Compile-time memory ordering

edit

Most programming languages have some notion of a thread of execution which executes statements in a defined order. Traditional compilers translate high-level expressions to a sequence of low-level instructions relative to a program counter at the underlying machine level.

Execution effects are visible at two levels: within the program code at a high level, and at the machine level as viewed by other threads or processing elements in concurrent programming, or during debugging when using a hardware debugging aid with access to the machine state (some support for this is often built directly into the CPU or microcontroller as functionally independent circuitry apart from the execution core which continues to operate even when the core itself is halted for static inspection of its execution state). Compile-time memory order concerns itself with the former, and does not concern itself with these other views.

General issues of program order

edit

Program-order effects of expression evaluation

edit

During compilation, hardware instructions are often generated at a finer granularity than specified in the high-level code. The primary observable effect in a procedural programming language is assignment of a new value to a named variable.

  sum = a + b + c; 
  print(sum);

The print statement follows the statement which assigns to the variable sum, and thus when the print statement references the computed variable sum it references this result as an observable effect of the prior execution sequence. As defined by the rules of program sequence, when the print function call references sum, the value of sum must be that of the most recently executed assignment to the variable sum (in this case the immediately previous statement).

At the machine level, few machines can add three numbers together in a single instruction, and so the compiler will have to translate this expression into two addition operations. If the semantics of the program language restrict the compiler into translating the expression in left-to-right order (for example), then the generated code will look as if the programmer had written the following statements in the original program:

  sum = a + b;
  sum = sum + c;

If the compiler is permitted to exploit the associative property of addition, it might instead generate:

  sum = b + c; 
  sum = a + sum; 

If the compiler is also permitted to exploit the commutative property of addition, it might instead generate:

  sum = a + c; 
  sum = sum + b; 

Note that the integer data type in most programming languages only follows the algebra for the mathematics integers in the absence of integer overflow and that floating-point arithmetic on the floating point data type available in most programming languages is not commutative in rounding effects, making effects of the order of expression visible in small differences of the computed result (small initial differences may however cascade into arbitrarily large differences over a longer computation).

If the programmer is concerned about integer overflow or rounding effects in floating point, the same program may be coded at the original high level as follows:

  sum = a + b; 
  sum = sum + c;

Program-order effects involving function calls

edit

Many languages treat the statement boundary as a sequence point, forcing all effects of one statement to be complete before the next statement is executed. This will force the compiler to generate code corresponding to the statement order expressed. Statements are, however, often more complicated, and may contain internal function calls.

  sum = f(a) + g(b) + h(c); 

At the machine level, calling a function usually involves setting up a stack frame for the function call, which involves many reads and writes to machine memory. In most compiled languages, the compiler is free to order the function calls f, g, and h as it finds convenient, resulting in large-scale changes of program memory order. In a pure functional programming language, function calls are forbidden from having side effects on the visible program state (other than its return value) and the difference in machine memory order due to function call ordering will be inconsequential to program semantics. In procedural languages, the functions called might have side-effects, such as performing an I/O operation, or updating a variable in global program scope, both of which produce visible effects with the program model.

Again, a programmer concerned with these effects can become more pedantic in expressing the original source program:

  sum = f(a);
  sum = sum + g(b);
  sum = sum + h(c); 

In programming languages where the statement boundary is defined as a sequence point, the function calls f, g, and h must now execute in that precise order.

Specific issues of memory order

edit

Program-order effects involving pointer expressions

edit

Now consider the same summation expressed with pointer indirection, in a language such as C or C++ which supports pointers:

  sum = *a + *b + *c; 

Evaluating the expression *x is termed "dereferencing" a pointer and involves reading from memory at a location specified by the current value of x. The effects of reading from a pointer are determined by architecture's memory model. When reading from standard program storage, there are no side-effects due to the order of memory read operations. In embedded system programming, it is very common to have memory-mapped I/O where reads and writes to memory trigger I/O operations, or changes to the processor's operational mode, which are highly visible side effects. For the above example, assume for now that the pointers are pointing to regular program memory, without these side-effects. The compiler is free to reorder these reads in program order as it sees fit, and there will be no program-visible side effects.

What if assigned value is also pointer indirected?

  *sum = *a + *b + *c; 

Here the language definition is unlikely to allow the compiler to break this apart as follows:

  // as rewritten by the compiler
  // generally forbidden 
  *sum = *a + *b;
  *sum = *sum + *c; 

This would not be viewed as efficient in most instances, and pointer writes have potential side-effects on visible machine state. Since the compiler is not allowed this particular splitting transformation, the only write to the memory location of sum must logically follow the three pointer reads in the value expression.

Suppose, however, that the programmer is concerned about the visible semantics of integer overflow and breaks the statement apart as the program level as follows:

  // as directly authored by the programmer 
  // with aliasing concerns 
  *sum = *a + *b; 
  *sum = *sum + *c; 

The first statement encodes two memory reads, which must precede (in either order) the first write to *sum. The second statement encodes two memory reads (in either order) which must precede the second update of *sum. This guarantees the order of the two addition operations, but potentially introduces a new problem of address aliasing: any of these pointers could potentially refer to the same memory location.

For example, let's assume in this example that *c and *sum are aliased to the same memory location, and rewrite both versions of the program with *sum standing in for both.

  *sum = *a + *b + *sum; 

There are no problems here. The original value of what we originally wrote as *c is lost upon assignment to *sum, and so is the original value of *sum but this was overwritten in the first place and it's of no special concern.

  // what the program becomes with *c and *sum aliased 
  *sum = *a + *b;
  *sum = *sum + *sum; 

Here the original value of *sum is overwritten before its first access, and instead we obtain the algebraic equivalent of:

  // algebraic equivalent of the aliased case above
  *sum = (*a + *b) + (*a + *b); 

which assigns an entirely different value into *sum due to the statement rearrangement.

Because of possible aliasing effects, pointer expressions are difficult to rearrange without risking visible program effects. In the common case, there might not be any aliasing in effect, so the code appears to run normally as before. But in the edge case where aliasing is present, severe program errors can result. Even if these edge cases are entirely absent in normal execution, it opens the door for a malicious adversary to contrive an input where aliasing exists, potentially leading to a computer security exploit.

A safe reordering of the previous program is as follows:

  // declare a temporary local variable 'temp' of suitable type 
  temp = *a + *b; 
  *sum = temp + *c; 

Finally consider the indirect case with added function calls:

  *sum = f(*a) + g(*b); 

The compiler may choose to evaluate *a and *b before either function call, it may defer the evaluation of *b until after the function call f or it may defer the evaluation of *a until after the function call g. If the functions f and g are free from program visible side-effects, all three choices will produce a program with the same visible program effects. If the implementation of f or g contain the side-effect of any pointer write subject to aliasing with pointers a or b, the three choices are liable to produce different visible program effects.

Memory order in language specification

edit

In general, compiled languages are not detailed enough in their specification for the compiler to determine formally at compile time which pointers are potentially aliased and which are not. The safest course of action is for the compiler to assume that all pointers are potentially aliased at all times. This level of conservative pessimism tends to produce dreadful performance as compared to the optimistic assumption that no aliasing exists, ever.

As a result, many high-level compiled languages, such as C/C++, have evolved to have intricate and sophisticated semantic specifications about where the compiler is permitted to make optimistic assumptions in code reordering in pursuit of the highest possible performance, and where the compiler is required to make pessimistic assumptions in code reordering to avoid semantic hazards.

By far the largest class of side effects in a modern procedural language involve memory write operations, so rules around memory ordering are a dominant component in the definition of program order semantics. The reordering of the functions calls above might appear to be a different consideration, but this usually devolves into concerns about memory effects internal to the called functions interacting with memory operations in the expression which generates the function call.

Additional difficulties and complications

edit

Optimization under as-if

edit

Modern compilers sometimes take this a step further by means of an as-if rule, in which any reordering is permitted (even across statements) if no effect on the visible program semantics results. Under this rule, the order of operations in the translated code can vary wildly from the specified program order. If the compiler is permitted to make optimistic assumptions about distinct pointer expressions having no alias overlap in a case where such aliasing actually exists (this would normally be classified as an ill-formed program exhibiting undefined behavior), the adverse results of an aggressive code-optimization transformation are impossible to guess prior to code execution or direct code inspection. The realm of undefined behavior has nearly limitless manifestations.

It is the responsibility of the programmer to consult the language specification to avoid writing ill-formed programs where the semantics are potentially changed as a result of any legal compiler optimization. Fortran traditionally places a high burden on the programmer to be aware of these issues, with the systems programming languages C and C++ not far behind.

Some high-level languages eliminate pointer constructions altogether, as this level of alertness and attention to detail is considered too high to reliably maintain even among professional programmers.

A complete grasp of memory order semantics is considered to be an arcane specialization even among the subpopulation of professional systems programmers who are typically best informed in this subject area. Most programmers settle for an adequate working grasp of these issues within the normal domain of their programming expertise. At the extreme end of specialization in memory order semantics are the programmers who author software frameworks in support of concurrent computing models.

Aliasing of local variables

edit

Note that local variables can not be assumed to be free of aliasing if a pointer to such a variable escapes into the wild:

  sum = f(&a) + g(a); 

There is no telling what the function f might have done with the supplied pointer to a, including leaving a copy around in global state which the function g later accesses. In the simplest case, f writes a new value to the variable a, making this expression ill-defined in order of execution. f can be conspicuously prevented from doing this by applying a const qualifier to the declaration of its pointer argument, rendering the expression well defined. Thus the modern culture of C/C++ has become somewhat obsessive about supplying const qualifiers to function argument declarations in all viable cases.

C and C++ permit the internals of f to type cast the constness attribute away as a dangerous expedient. If f does this in a way that can break the expression above, it should not be declaring the pointer argument type as const in the first place.

Other high-level languages tilt toward such a declaration attribute amounting to a strong guarantee with no loop-holes to violate this guarantee provided within the language itself; all bets are off on this language guarantee if your application links a library written in a different programming language (though this is considered to be egregiously bad design).

Compile-time memory barrier implementation

edit

These barriers prevent a compiler from reordering instructions during compile time – they do not prevent reordering by CPU during runtime.

  • Any of these GNU inline assembler statements forbids the GCC compiler to reorder read and write commands around it:[9]
asm volatile(""?::: "memory");
__asm__ __volatile__ (""?::: "memory");
  • This C11/C++11 function forbids the compiler to reorder read and write commands around it:[10]
atomic_signal_fence(memory_order_acq_rel);
__memory_barrier()
_ReadBarrier()
_WriteBarrier()
_ReadWriteBarrier()

Combined barriers

edit

In many programming languages different types of barriers can be combined with other operations (like load, store, atomic increment, atomic compare and swap), so no extra memory barrier is needed before or after it (or both). Depending on a CPU architecture being targeted these language constructs will translate to either special instructions, to multiple instructions (i.e. barrier and load), or to normal instruction, depending on hardware memory ordering guarantees.

Runtime memory ordering

edit

In symmetric multiprocessing (SMP) microprocessor systems

edit

There are several memory-consistency models for SMP systems:

  • Sequential consistency (all reads and all writes are in-order)
  • Relaxed consistency (some types of reordering are allowed)
    • Loads can be reordered after loads (for better working of cache coherency, better scaling)
    • Loads can be reordered after stores
    • Stores can be reordered after stores
    • Stores can be reordered after loads
  • Weak consistency (reads and writes are arbitrarily reordered, limited only by explicit memory barriers)

On some CPUs

  • Atomic operations can be reordered with loads and stores.[14]
  • There can be incoherent instruction cache pipeline, which prevents self-modifying code from being executed without special instruction cache flush/reload instructions.
  • Dependent loads can be reordered (this is unique for Alpha). If the processor first fetches a pointer to some data and then the data, it might not fetch the data itself but use stale data which it has already cached and not yet invalidated. Allowing this relaxation makes cache hardware simpler and faster but leads to the requirement of memory barriers for readers and writers.[15] On Alpha hardware (like multiprocessor Alpha 21264 systems) cache line invalidations sent to other processors are processed in lazy fashion by default, unless requested explicitly to be processed between dependent loads. The Alpha architecture specification also allows other forms of dependent loads reordering, for example using speculative data reads ahead of knowing the real pointer to be dereferenced.
Memory ordering in some architectures[5][16]
Type Alpha ARMv7 MIPS RISC-V PA-RISC POWER SPARC x86 [a] AMD64 IA-64 z/Architecture
WMO TSO RMO PSO TSO
Loads can be reordered after loads Y Y depend on
implementation
Y Y Y Y Y
Loads can be reordered after stores Y Y Y Y Y Y Y
Stores can be reordered after stores Y Y Y Y Y Y Y Y
Stores can be reordered after loads Y Y Y Y Y Y Y Y Y Y Y Y Y
Atomic can be reordered with loads Y Y Y Y Y Y
Atomic can be reordered with stores Y Y Y Y Y Y Y
Dependent loads can be reordered Y
Incoherent instruction cache/pipeline Y Y Y Y Y Y Y Y Y Y
  1. ^ This column indicates the behaviour of the vast majority of x86 processors. Some rare specialised x86 processors (IDT WinChip manufactured around 1998) may have weaker 'oostore' memory ordering.[17]
RISC-V memory ordering models
WMO
Weak memory order (default)
TSO
Total store order (only supported with the Ztso extension)
SPARC memory ordering modes
TSO
Total store order (default)
RMO
Relaxed-memory order (not supported on recent CPUs)
PSO
Partial store order (not supported on recent CPUs)

Hardware memory barrier implementation

edit

Many architectures with SMP support have special hardware instruction for flushing reads and writes during runtime.

lfence (asm), void _mm_lfence(void)
sfence (asm), void _mm_sfence(void)[18]
mfence (asm), void _mm_mfence(void)[19]
sync (asm)
sync (asm)[20][21]
mf (asm)
dcs (asm)
dmb (asm)
dsb (asm)
isb (asm)

Compiler support for hardware memory barriers

edit

Some compilers support builtins that emit hardware memory barrier instructions:

See also

edit

References

edit
  1. ^ a b c d e Preshing, Jeff (30 September 2012). "Weak vs. Strong Memory Models". Preshing on Programming. Retrieved 3 August 2024.
  2. ^ a b Howells, David; McKenney, Paul E; Deacon, Will; Zijlstra, Peter. "Linux Kernel Memory Barriers". The Linux Kernel Archives. Retrieved 3 August 2024.
  3. ^ Preshing, Jeff (25 June 2012). "Memory Ordering at Compile Time". Preshing on Programming. Retrieved 3 August 2024.
  4. ^ a b Sewell, Peter. "Relaxed-Memory Concurrency". University of Cambridge. Retrieved 3 August 2024.
  5. ^ a b c d e McKenney, Paul E (19 September 2007). "Memory Ordering in Modern Microprocessors" (PDF). Retrieved 3 August 2024.
  6. ^ a b Torvalds, Linus (8 December 2003). "Re: branch prediction, renaming, joins". Retrieved 3 August 2024.
  7. ^ Manson, Jeremy; Goetz, Brian (February 2004). "JSR 133 (Java Memory Model) FAQ". University of Maryland. Retrieved 3 August 2024.
  8. ^ "Intel 64 Architecture Memory Ordering White Paper" (PDF). Intel. August 2007. Retrieved 3 August 2024.
  9. ^ GCC compiler-gcc.h Archived 2025-08-14 at the Wayback Machine
  10. ^ "std::atomic_signal_fence". ccpreference.
  11. ^ ECC compiler-intel.h Archived 2025-08-14 at the Wayback Machine
  12. ^ Intel(R) C++ Compiler Intrinsics Reference

    Creates a barrier across which the compiler will not schedule any data access instruction. The compiler may allocate local data in registers across a memory barrier, but not global data.

  13. ^ a b "_ReadWriteBarrier". Microsoft Learn. 3 August 2021.
  14. ^ Victor Alessandrini, 2015. Shared Memory Application Programming: Concepts and Strategies in Multicore Application Programming. Elsevier Science. p. 176. ISBN?978-0-12-803820-8.
  15. ^ Reordering on an Alpha processor by Kourosh Gharachorloo
  16. ^ McKenney, Paul E (7 June 2010). "Memory Barriers: a Hardware View for Software Hackers" (PDF). p.?16. Retrieved 3 August 2024. Figure 5.
  17. ^ Table 1. Summary of Memory Ordering, from "Memory Ordering in Modern Microprocessors, Part I"
  18. ^ SFENCE — Store Fence
  19. ^ MFENCE — Memory Fence
  20. ^ "MIPS? Coherence Protocol Specification, Revision 01.01" (PDF). p.?26. Retrieved 2025-08-14.
  21. ^ "MIPS instruction set R5" (PDF). p.?59-60. Retrieved 2025-08-14.
  22. ^ Data Memory Barrier, Data Synchronization Barrier, and Instruction Synchronization Barrier.
  23. ^ Atomic Builtins
  24. ^ "36793 – x86-64 does not get __sync_synchronize right".
  25. ^ "MemoryBarrier function (winnt.h) - Win32 apps". Microsoft Learn. 6 October 2021.
  26. ^ Handling Memory Ordering in Multithreaded Applications with Oracle Solaris Studio 12 Update 2: Part 2, Memory Barriers and Memory Fence [1]

Further reading

edit
东星斑为什么这么贵 穷的生肖指什么生肖 做什么行业最赚钱 康养中心是做什么的 杯弓蛇影告诉我们什么道理
经常拉稀是什么原因 认贼作父是什么意思 果冻是什么做的 女人带貔貅有什么讲究 aemape是什么牌子
胃发胀是什么原因 感冒了吃什么水果好 楼梯步数有什么讲究 正主是什么意思 无偿献血证有什么用
10月5号是什么星座 脚底疼是什么原因 男属狗配什么属相最好 颈椎不舒服挂什么科 父母都是o型血孩子是什么血型
鸭胗是鸭的什么部位hcv8jop9ns5r.cn 为什么水不能燃烧hcv7jop9ns7r.cn 左腰疼是什么原因hcv9jop3ns1r.cn 什么的精神sscsqa.com 秦朝之前是什么朝代hcv7jop7ns4r.cn
为什么左手会发麻hcv8jop4ns3r.cn 女人吃什么新陈代谢快hcv9jop5ns6r.cn venes保温杯是什么品牌hcv7jop6ns9r.cn 肺结核什么症状hcv9jop2ns3r.cn 风热感冒咳嗽吃什么药0735v.com
女性私下有苦味主要是什么原因hcv9jop0ns6r.cn 五行金是什么颜色hcv9jop4ns8r.cn foreverlove是什么意思hcv8jop6ns5r.cn 心五行属什么hcv7jop5ns1r.cn 世五行属什么hcv9jop1ns7r.cn
肚子里有积水是什么病hcv9jop4ns6r.cn 勾股定理是什么意思bfb118.com 没有高中毕业证有什么影响hcv9jop4ns2r.cn 胃热吃什么食物好hcv9jop1ns6r.cn 血红蛋白是什么hlguo.com
百度 技术支持:蜘蛛池 www.kelongchi.com