github.com/gagliardetto/golang-go@v0.0.0-20201020153340-53909ea70814/cmd/compile/internal/ppc64/galign.go (about)

     1  // Copyright 2009 The Go Authors. All rights reserved.
     2  // Use of this source code is governed by a BSD-style
     3  // license that can be found in the LICENSE file.
     4  
     5  package ppc64
     6  
     7  import (
     8  	"github.com/gagliardetto/golang-go/cmd/compile/internal/gc"
     9  	"github.com/gagliardetto/golang-go/cmd/internal/obj/ppc64"
    10  	"github.com/gagliardetto/golang-go/cmd/internal/objabi"
    11  )
    12  
    13  func Init(arch *gc.Arch) {
    14  	arch.LinkArch = &ppc64.Linkppc64
    15  	if objabi.GOARCH == "ppc64le" {
    16  		arch.LinkArch = &ppc64.Linkppc64le
    17  	}
    18  	arch.REGSP = ppc64.REGSP
    19  	arch.MAXWIDTH = 1 << 60
    20  
    21  	arch.ZeroRange = zerorange
    22  	arch.Ginsnop = ginsnop
    23  	arch.Ginsnopdefer = ginsnopdefer
    24  
    25  	arch.SSAMarkMoves = ssaMarkMoves
    26  	arch.SSAGenValue = ssaGenValue
    27  	arch.SSAGenBlock = ssaGenBlock
    28  }