github.com/wasilibs/wazerox@v0.0.0-20240124024944-4923be63ab5f/internal/engine/compiler/arch_other.go (about)

     1  //go:build !amd64 && !arm64
     2  
     3  package compiler
     4  
     5  import (
     6  	"fmt"
     7  	"runtime"
     8  
     9  	"github.com/wasilibs/wazerox/internal/asm"
    10  )
    11  
    12  // archContext is empty on an unsupported architecture.
    13  type archContext struct{}
    14  
    15  // newCompiler panics with an unsupported error.
    16  func newCompiler() compiler {
    17  	panic(fmt.Sprintf("unsupported GOARCH %s", runtime.GOARCH))
    18  }
    19  
    20  func registerMaskShift(r asm.Register) (ret int) {
    21  	panic(fmt.Sprintf("unsupported GOARCH %s", runtime.GOARCH))
    22  }
    23  
    24  func registerFromMaskShift(s int) asm.Register {
    25  	panic(fmt.Sprintf("unsupported GOARCH %s", runtime.GOARCH))
    26  }