math

package
v0.0.0-...-2ded9d7 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jun 19, 2019 License: Apache-2.0 Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type DADD

type DADD struct {
	base.NoOperandsInstruction
}

Add double

func (*DADD) Execute

func (self *DADD) Execute(frame *chapter4_rtdt.Frame)

type DDIV

type DDIV struct {
	base.NoOperandsInstruction
}

Divide double

func (*DDIV) Execute

func (self *DDIV) Execute(frame *chapter4_rtdt.Frame)

type DMUL

type DMUL struct {
	base.NoOperandsInstruction
}

Multiply double

func (*DMUL) Execute

func (self *DMUL) Execute(frame *chapter4_rtdt.Frame)

type DNEG

type DNEG struct {
	base.NoOperandsInstruction
}

Negate double

func (*DNEG) Execute

func (self *DNEG) Execute(frame *chapter4_rtdt.Frame)

type DREM

type DREM struct {
	base.NoOperandsInstruction
}

*

取余指令

func (*DREM) Execute

func (self *DREM) Execute(frame *chapter4_rtdt.Frame)

*

浮点数有Infinity -> 无限大值,所以即使是除0 也不会ArithmeticException

type DSUB

type DSUB struct {
	base.NoOperandsInstruction
}

Subtract double

func (*DSUB) Execute

func (self *DSUB) Execute(frame *chapter4_rtdt.Frame)

type FADD

type FADD struct {
	base.NoOperandsInstruction
}

Add float

func (*FADD) Execute

func (self *FADD) Execute(frame *chapter4_rtdt.Frame)

type FDIV

type FDIV struct {
	base.NoOperandsInstruction
}

Divide float

func (*FDIV) Execute

func (self *FDIV) Execute(frame *chapter4_rtdt.Frame)

type FMUL

type FMUL struct {
	base.NoOperandsInstruction
}

Multiply float

func (*FMUL) Execute

func (self *FMUL) Execute(frame *chapter4_rtdt.Frame)

type FNEG

type FNEG struct {
	base.NoOperandsInstruction
}

Negate float

func (*FNEG) Execute

func (self *FNEG) Execute(frame *chapter4_rtdt.Frame)

type FREM

type FREM struct {
	base.NoOperandsInstruction
}

func (*FREM) Execute

func (self *FREM) Execute(frame *chapter4_rtdt.Frame)

type FSUB

type FSUB struct {
	base.NoOperandsInstruction
}

Subtract float

func (*FSUB) Execute

func (self *FSUB) Execute(frame *chapter4_rtdt.Frame)

type IADD

type IADD struct {
	base.NoOperandsInstruction
}

Add int

func (*IADD) Execute

func (self *IADD) Execute(frame *chapter4_rtdt.Frame)

type IAND

type IAND struct {
	base.NoOperandsInstruction
}

func (*IAND) Execute

func (self *IAND) Execute(frame *chapter4_rtdt.Frame)

type IDIV

type IDIV struct {
	base.NoOperandsInstruction
}

Divide int

func (*IDIV) Execute

func (self *IDIV) Execute(frame *chapter4_rtdt.Frame)

type IINC

type IINC struct {
	Index uint
	Const int32
}

*

给局部变量表中的int增加常量值,局部变量表索引和常量值都由指令的操作数提供

func (*IINC) Execute

func (self *IINC) Execute(frame *chapter4_rtdt.Frame)

func (*IINC) FetchOperands

func (self *IINC) FetchOperands(reader *base.BytecodeReader)

type IMUL

type IMUL struct {
	base.NoOperandsInstruction
}

Multiply int

func (*IMUL) Execute

func (self *IMUL) Execute(frame *chapter4_rtdt.Frame)

type INEG

type INEG struct {
	base.NoOperandsInstruction
}

Negate int

func (*INEG) Execute

func (self *INEG) Execute(frame *chapter4_rtdt.Frame)

type IOR

type IOR struct {
	base.NoOperandsInstruction
}

Boolean OR int

func (*IOR) Execute

func (self *IOR) Execute(frame *chapter4_rtdt.Frame)

type IREM

type IREM struct {
	base.NoOperandsInstruction
}

func (*IREM) Execute

func (self *IREM) Execute(frame *chapter4_rtdt.Frame)

type ISHL

type ISHL struct {
	base.NoOperandsInstruction
}

*

位移指令分为左移和右移
右移又可以分为算术右移(有符号右移) 和 逻辑右移(无符号右移)

func (*ISHL) Execute

func (self *ISHL) Execute(frame *chapter4_rtdt.Frame)

type ISHR

type ISHR struct {
	base.NoOperandsInstruction
}

func (*ISHR) Execute

func (self *ISHR) Execute(frame *chapter4_rtdt.Frame)

type ISUB

type ISUB struct {
	base.NoOperandsInstruction
}

Subtract int

func (*ISUB) Execute

func (self *ISUB) Execute(frame *chapter4_rtdt.Frame)

type IUSHR

type IUSHR struct {
	base.NoOperandsInstruction
}

func (*IUSHR) Execute

func (self *IUSHR) Execute(frame *chapter4_rtdt.Frame)

type IXOR

type IXOR struct {
	base.NoOperandsInstruction
}

Boolean XOR int

func (*IXOR) Execute

func (self *IXOR) Execute(frame *chapter4_rtdt.Frame)

type LADD

type LADD struct {
	base.NoOperandsInstruction
}

Add long

func (*LADD) Execute

func (self *LADD) Execute(frame *chapter4_rtdt.Frame)

type LAND

type LAND struct {
	base.NoOperandsInstruction
}

func (*LAND) Execute

func (self *LAND) Execute(frame *chapter4_rtdt.Frame)

type LDIV

type LDIV struct {
	base.NoOperandsInstruction
}

Divide long

func (*LDIV) Execute

func (self *LDIV) Execute(frame *chapter4_rtdt.Frame)

type LMUL

type LMUL struct {
	base.NoOperandsInstruction
}

Multiply long

func (*LMUL) Execute

func (self *LMUL) Execute(frame *chapter4_rtdt.Frame)

type LNEG

type LNEG struct {
	base.NoOperandsInstruction
}

Negate long

func (*LNEG) Execute

func (self *LNEG) Execute(frame *chapter4_rtdt.Frame)

type LOR

type LOR struct {
	base.NoOperandsInstruction
}

Boolean OR long

func (*LOR) Execute

func (self *LOR) Execute(frame *chapter4_rtdt.Frame)

type LREM

type LREM struct {
	base.NoOperandsInstruction
}

func (*LREM) Execute

func (self *LREM) Execute(frame *chapter4_rtdt.Frame)

type LSHL

type LSHL struct {
	base.NoOperandsInstruction
}

func (*LSHL) Execute

func (self *LSHL) Execute(frame *chapter4_rtdt.Frame)

type LSHR

type LSHR struct {
	base.NoOperandsInstruction
}

func (LSHR) Execute

func (self LSHR) Execute(frame *chapter4_rtdt.Frame)

type LSUB

type LSUB struct {
	base.NoOperandsInstruction
}

Subtract long

func (*LSUB) Execute

func (self *LSUB) Execute(frame *chapter4_rtdt.Frame)

type LUSHR

type LUSHR struct {
	base.NoOperandsInstruction
}

func (*LUSHR) Execute

func (self *LUSHR) Execute(frame *chapter4_rtdt.Frame)

type LXOR

type LXOR struct {
	base.NoOperandsInstruction
}

Boolean XOR long

func (*LXOR) Execute

func (self *LXOR) Execute(frame *chapter4_rtdt.Frame)

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL