-
Notifications
You must be signed in to change notification settings - Fork 18.4k
Closed
Labels
FrozenDueToAgeNeedsInvestigationSomeone must examine and confirm this is a valid issue and not a duplicate of an existing one.Someone must examine and confirm this is a valid issue and not a duplicate of an existing one.PerformanceWaitingForInfoIssue is not actionable because of missing required information, which needs to be provided.Issue is not actionable because of missing required information, which needs to be provided.
Milestone
Description
type Example struct {
a, b int32
}
x := Example{x:1, y:1}
y := x
the y:=x
will be compiled to two movl while the x:=Example{x:1, y:1}
compiled to single movq.
it confuse me about the memory bevavior, assumpt we have one routine write x=Example{x:1, y:1}
and another write x=Example{x:2, y:2}
, according to the memory model, x will either be x:1,y:1
or x:2, y:2
. how ever if we do
y:=x
fmt.Println(y.a, y.b)
then, we could get x:1, y:2
!!!
Metadata
Metadata
Assignees
Labels
FrozenDueToAgeNeedsInvestigationSomeone must examine and confirm this is a valid issue and not a duplicate of an existing one.Someone must examine and confirm this is a valid issue and not a duplicate of an existing one.PerformanceWaitingForInfoIssue is not actionable because of missing required information, which needs to be provided.Issue is not actionable because of missing required information, which needs to be provided.