-
Notifications
You must be signed in to change notification settings - Fork 5.3k
Open
Labels
area-CodeGen-coreclrCLR JIT compiler in src/coreclr/src/jit and related components such as SuperPMICLR JIT compiler in src/coreclr/src/jit and related components such as SuperPMIbughelp wanted[up-for-grabs] Good issue for external contributors[up-for-grabs] Good issue for external contributorsmemory modelissues associated with memory modelissues associated with memory model
Milestone
Description
Going by Ecma 335 III.4.13, it is my understanding that a sequence like
volatile.
ldobj MyType
should produce a volatile load. While one could argue that it's a store (the spec says "copy the value stored at address src to the stack"), interpreting it as a load seems more appropriate if one considers that the spec also says "if typeTok is not a generic parameter and either a reference type or a built-in value class, then the ldind instruction provides a shorthand for the ldobj instruction".
The relevant code:
- https://github.com/dotnet/coreclr/blob/cbf46fb0b6a0b209ed1caf4a680910b383e68cba/src/vm/interpreter.cpp#L5537
- https://github.com/dotnet/coreclr/blob/cbf46fb0b6a0b209ed1caf4a680910b383e68cba/src/vm/interpreter.cpp#L4292
category:correctness
theme:interpreter
skill-level:intermediate
cost:small
Metadata
Metadata
Assignees
Labels
area-CodeGen-coreclrCLR JIT compiler in src/coreclr/src/jit and related components such as SuperPMICLR JIT compiler in src/coreclr/src/jit and related components such as SuperPMIbughelp wanted[up-for-grabs] Good issue for external contributors[up-for-grabs] Good issue for external contributorsmemory modelissues associated with memory modelissues associated with memory model