diff options
Diffstat (limited to 'src/cmd/asm')
| -rw-r--r-- | src/cmd/asm/internal/arch/loong64.go | 12 | ||||
| -rw-r--r-- | src/cmd/asm/internal/asm/asm.go | 8 |
2 files changed, 0 insertions, 20 deletions
diff --git a/src/cmd/asm/internal/arch/loong64.go b/src/cmd/asm/internal/arch/loong64.go index bf5175f4a0..21263d3433 100644 --- a/src/cmd/asm/internal/arch/loong64.go +++ b/src/cmd/asm/internal/arch/loong64.go @@ -23,18 +23,6 @@ func jumpLoong64(word string) bool { return false } -// IsLoong64MUL reports whether the op (as defined by an loong64.A* constant) is -// one of the MUL/DIV/REM instructions that require special handling. -func IsLoong64MUL(op obj.As) bool { - switch op { - case loong64.AMUL, loong64.AMULU, loong64.AMULV, loong64.AMULVU, - loong64.ADIV, loong64.ADIVU, loong64.ADIVV, loong64.ADIVVU, - loong64.AREM, loong64.AREMU, loong64.AREMV, loong64.AREMVU: - return true - } - return false -} - // IsLoong64RDTIME reports whether the op (as defined by an loong64.A* // constant) is one of the RDTIMELW/RDTIMEHW/RDTIMED instructions that // require special handling. diff --git a/src/cmd/asm/internal/asm/asm.go b/src/cmd/asm/internal/asm/asm.go index 9a6e22cab2..6bdbcb9c1b 100644 --- a/src/cmd/asm/internal/asm/asm.go +++ b/src/cmd/asm/internal/asm/asm.go @@ -974,14 +974,6 @@ func (p *Parser) getConstant(prog *obj.Prog, op obj.As, addr *obj.Addr) int64 { return addr.Offset } -// getImmediate checks that addr represents an immediate constant and returns its value. -func (p *Parser) getImmediate(prog *obj.Prog, op obj.As, addr *obj.Addr) int64 { - if addr.Type != obj.TYPE_CONST || addr.Name != 0 || addr.Reg != 0 || addr.Index != 0 { - p.errorf("%s: expected immediate constant; found %s", op, obj.Dconv(prog, addr)) - } - return addr.Offset -} - // getRegister checks that addr represents a register and returns its value. func (p *Parser) getRegister(prog *obj.Prog, op obj.As, addr *obj.Addr) int16 { if addr.Type != obj.TYPE_REG || addr.Offset != 0 || addr.Name != 0 || addr.Index != 0 { |
