Skip to content

Commit 811ebb6

Browse files
committed
cmd/compile: temporarily disable inplace append special case
Fixes #15246 Re-opens #14969 Change-Id: Ic0b41c5aa42bbb229a0d62b7f3e5888c6b29293d Reviewed-on: https://go-review.googlesource.com/21891 Run-TryBot: Josh Bleecher Snyder <[email protected]> TryBot-Result: Gobot Gobot <[email protected]> Reviewed-by: Keith Randall <[email protected]>
1 parent 8edf4cb commit 811ebb6

File tree

1 file changed

+2
-1
lines changed
  • src/cmd/compile/internal/gc

1 file changed

+2
-1
lines changed

src/cmd/compile/internal/gc/ssa.go

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -699,7 +699,8 @@ func (s *state) stmt(n *Node) {
699699
// If the slice can be SSA'd, it'll be on the stack,
700700
// so there will be no write barriers,
701701
// so there's no need to attempt to prevent them.
702-
if samesafeexpr(n.Left, rhs.List.First()) && !s.canSSA(n.Left) {
702+
const doInPlaceAppend = false // issue 15246
703+
if doInPlaceAppend && samesafeexpr(n.Left, rhs.List.First()) && !s.canSSA(n.Left) {
703704
s.append(rhs, true)
704705
return
705706
}

0 commit comments

Comments
 (0)