scala.scalanative.nir

Members list

Concise view

Type members

Classlikes

sealed abstract class Attr

Attributes

Companion:
object
Graph
Supertypes
class Object
trait Matchable
class Any
Known subtypes
object Abstract.type
class Alignment
class Define
object Dyn.type
class Extern
object Final.type
class Inline
object AlwaysInline.type
object InlineHint.type
object MayInline.type
object NoInline.type
class Link
object LinktimeResolved.type
class Opt
class BailOpt
object DidOpt.type
object NoOpt.type
object UnOpt.type
object SafePublish.type
object MaySpecialize.type
object NoSpecialize.type
object Stub.type
object UsesIntrinsic.type
object Volatile.type
object Attr

Attributes

Companion:
class
Graph
Supertypes
trait Sum
trait Mirror
class Object
trait Matchable
class Any
Self type
Attr.type
final case class Attrs(inlineHint: Inline, specialize: Specialize, opt: Opt, align: Option[Alignment], isExtern: Boolean, isBlocking: Boolean, isDyn: Boolean, isStub: Boolean, isAbstract: Boolean, isVolatile: Boolean, isFinal: Boolean, isSafePublish: Boolean, isLinktimeResolved: Boolean, isUsingIntrinsics: Boolean, links: Seq[Link], preprocessorDefinitions: Seq[Define])

Attributes

Companion:
object
Graph
Supertypes
trait Product
trait Equals
class Object
trait Matchable
class Any
object Attrs

Attributes

Companion:
class
Graph
Supertypes
trait Product
trait Mirror
class Object
trait Matchable
class Any
Self type
Attrs.type
sealed abstract class Bin

Attributes

Companion:
object
Graph
Supertypes
class Object
trait Matchable
class Any
Known subtypes
object And.type
object Ashr.type
object Fadd.type
object Fdiv.type
object Fmul.type
object Frem.type
object Fsub.type
object Iadd.type
object Imul.type
object Isub.type
object Lshr.type
object Or.type
object Sdiv.type
object Shl.type
object Srem.type
object Udiv.type
object Urem.type
object Xor.type
object Bin

Attributes

Companion:
class
Graph
Supertypes
trait Sum
trait Mirror
class Object
trait Matchable
class Any
Self type
Bin.type
sealed abstract class Comp

Attributes

Companion:
object
Graph
Supertypes
class Object
trait Matchable
class Any
Known subtypes
class Fcmp
object Feq.type
object Fge.type
object Fgt.type
object Fle.type
object Flt.type
object Fne.type
class Icmp
object Ieq.type
object Ine.type
object Sge.type
object Sgt.type
object Sle.type
object Slt.type
object Uge.type
object Ugt.type
object Ule.type
object Ult.type
object Comp

Attributes

Companion:
class
Graph
Supertypes
trait Sum
trait Mirror
class Object
trait Matchable
class Any
Self type
Comp.type
sealed abstract class Conv

Attributes

Companion:
object
Graph
Supertypes
class Object
trait Matchable
class Any
Known subtypes
object Bitcast.type
object Fpext.type
object Fptosi.type
object Fptoui.type
object Fptrunc.type
object Inttoptr.type
object Ptrtoint.type
object SSizeCast.type
object Sext.type
object Sitofp.type
object Trunc.type
object Uitofp.type
object ZSizeCast.type
object Zext.type
object Conv

Attributes

Companion:
class
Graph
Supertypes
trait Sum
trait Mirror
class Object
trait Matchable
class Any
Self type
Conv.type
sealed abstract class Defn extends Positioned

A definition in NIR.

A definition in NIR.

Programs in NIR are represented as a sequence of definitions denoting types, methods and fields. Definitions fall into two categories:

  • Top-level definitions: these represent classes, modules, traits, or global variables and constants.
  • Member definitions: these represent fields or methods.

Classes and modules inherit from a single parent with the exception of java.lang.Object, which sits at the top of the hierarchy. They may additionally implement traits.

Definitions may also carry attributes providing further information about their semantics (e.g., whether a method may be inlined). Attributes are also used to mark special-purpose definitions, such as stubs, proxies and FFIs.

Attributes

Companion:
object
Graph
Supertypes
class Object
trait Matchable
class Any
Known subtypes
class Class
class Const
class Declare
class Define
class Module
class Trait
class Var
object Defn

Attributes

Companion:
class
Graph
Supertypes
class Object
trait Matchable
class Any
Self type
Defn.type
final class Fresh

Attributes

Companion:
object
Graph
Supertypes
class Object
trait Matchable
class Any
object Fresh

Attributes

Companion:
class
Graph
Supertypes
class Object
trait Matchable
class Any
Self type
Fresh.type
sealed abstract class Global

The identifier of a type or method (aka a symbol).

The identifier of a type or method (aka a symbol).

Attributes

Companion:
object
Graph
Supertypes
class Object
trait Matchable
class Any
Known subtypes
class Member
object None.type
class Top
object Global

Attributes

Companion:
class
Graph
Supertypes
trait Sum
trait Mirror
class Object
trait Matchable
class Any
Self type
Global.type
sealed abstract class Inst extends Positioned

Attributes

Companion:
object
Graph
Supertypes
class Object
trait Matchable
class Any
Known subtypes
class Cf
class If
class Jump
class Ret
class Switch
class Throw
class Label
class Let
object Inst

Attributes

Companion:
class
Graph
Supertypes
class Object
trait Matchable
class Any
Self type
Inst.type
class InstructionBuilder(implicit fresh: Fresh)

A class to build sequences of NIR instructions.

A class to build sequences of NIR instructions.

Attributes

Graph
Supertypes
class Object
trait Matchable
class Any
Known subtypes
sealed trait LinktimeCondition

Attributes

Companion:
object
Graph
Supertypes
class Object
trait Matchable
class Any
Known subtypes

Attributes

Companion:
trait
Graph
Supertypes
class Object
trait Matchable
class Any
Self type
final case class Local(id: Long) extends AnyVal

Attributes

Graph
Supertypes
trait Product
trait Equals
class AnyVal
trait Matchable
class Any
object Mangle

Attributes

Graph
Supertypes
class Object
trait Matchable
class Any
Self type
Mangle.type
sealed abstract class MemoryOrder(val tag: Int)

An atomic memory ordering constraints.

An atomic memory ordering constraints.

Atomic instructions take ordering parameters specifying with which other instructions they synchronize.

Attributes

See also:
Companion:
object
Graph
Supertypes
class Object
trait Matchable
class Any
Known subtypes
object AcqRel.type
object Acquire.type
object Monotonic.type
object Release.type
object SeqCst.type
object Unordered.type

Attributes

Companion:
class
Graph
Supertypes
trait Sum
trait Mirror
class Object
trait Matchable
class Any
Self type
sealed case class NIRSource(directory: Path, path: Path)

Attributes

Companion:
object
Graph
Supertypes
trait Product
trait Equals
class Object
trait Matchable
class Any
Known subtypes
object None.type
object NIRSource

Attributes

Companion:
class
Graph
Supertypes
trait Product
trait Mirror
class Object
trait Matchable
class Any
Self type
sealed abstract class Next

Attributes

Companion:
object
Graph
Supertypes
class Object
trait Matchable
class Any
Known subtypes
class Case
class Label
object None.type
class Unwind
object Next

Attributes

Companion:
class
Graph
Supertypes
trait Sum
trait Mirror
class Object
trait Matchable
class Any
Self type
Next.type
object Of

Attributes

Graph
Supertypes
class Object
trait Matchable
class Any
Self type
Of.type
sealed abstract class Op

Attributes

Companion:
object
Graph
Supertypes
class Object
trait Matchable
class Any
Known subtypes
class Arrayload
class As
class Bin
class Box
class Call
class Comp
class Conv
class Copy
class Dynmethod
class Elem
class Extract
class Fence
class Field
class Fieldload
class Insert
class Is
class Load
class Method
class Module
class SizeOf
class Store
class Unbox
class Var
class Varload
class Varstore
Self type
object Op

Attributes

Companion:
class
Graph
Supertypes
trait Sum
trait Mirror
class Object
trait Matchable
class Any
Self type
Op.type

Attributes

Companion:
object
Graph
Supertypes
class Object
trait Matchable
class Any
Known subtypes
class Defn
class Class
class Const
class Declare
class Define
class Module
class Trait
class Var
class Inst
class Cf
class If
class Jump
class Ret
class Switch
class Throw
class Label
class Let
object Positioned

Attributes

Companion:
trait
Graph
Supertypes
class Object
trait Matchable
class Any
Self type
final case class ScopeId(id: Int) extends AnyVal

The identifier of a lexical scope.

The identifier of a lexical scope.

Attributes

Companion:
object
Graph
Supertypes
trait Product
trait Equals
class AnyVal
trait Matchable
class Any
object ScopeId

Attributes

Companion:
class
Graph
Supertypes
class Object
trait Matchable
class Any
Self type
ScopeId.type
object Show

Attributes

Graph
Supertypes
class Object
trait Matchable
class Any
Self type
Show.type
final class Sig(val mangle: String)

Attributes

Companion:
object
Graph
Supertypes
class Object
trait Matchable
class Any
object Sig

Attributes

Companion:
class
Graph
Supertypes
class Object
trait Matchable
class Any
Self type
Sig.type
sealed trait SourceFile

Attributes

Companion:
object
Graph
Supertypes
class Object
trait Matchable
class Any
Known subtypes
class Relative
object Virtual.type
object SourceFile

Attributes

Companion:
trait
Graph
Supertypes
trait Sum
trait Mirror
class Object
trait Matchable
class Any
Self type
final case class SourcePosition(source: SourceFile, line: Int, column: Int, nirSource: NIRSource)

Attributes

Companion:
object
Graph
Supertypes
trait Product
trait Equals
class Object
trait Matchable
class Any

Attributes

Companion:
class
Graph
Supertypes
trait Product
trait Mirror
class Object
trait Matchable
class Any
Self type
trait Transform

Attributes

Graph
Supertypes
class Object
trait Matchable
class Any
trait Traverse

Attributes

Graph
Supertypes
class Object
trait Matchable
class Any
sealed abstract class Type

Attributes

Companion:
object
Graph
Supertypes
class Object
trait Matchable
class Any
Known subtypes
class RefKind
class Array
object Null.type
class Ref
object Unit.type
class Function
object Nothing.type
class Var
object Vararg.type
object Virtual.type
class ValueKind
trait I
object Byte.type
object Char.type
object Int.type
object Long.type
object Short.type
object Size.type
object Bool.type
class F
object Double.type
object Float.type
object Ptr.type
object Type

Attributes

Companion:
class
Graph
Supertypes
trait Sum
trait Mirror
class Object
trait Matchable
class Any
Self type
Type.type
object Unmangle

Attributes

Graph
Supertypes
class Object
trait Matchable
class Any
Self type
sealed abstract class Val

A NIR value.

A NIR value.

Attributes

Companion:
object
Graph
Supertypes
class Object
trait Matchable
class Any
Known subtypes
class Byte
class Char
class ClassOf
class Const
class Double
object False.type
class Float
class Global
class Int
class Local
class Long
object Null.type
class Short
class Size
class String
object True.type
object Unit.type
class Virtual
class Zero
object Val

Attributes

Companion:
class
Graph
Supertypes
trait Sum
trait Mirror
class Object
trait Matchable
class Any
Self type
Val.type
object Versions

Attributes

Graph
Supertypes
class Object
trait Matchable
class Any
Self type

Types

The name of a variable in program sources.

The name of a variable in program sources.

Attributes

A map from SSA identifier to its name in program sources.

A map from SSA identifier to its name in program sources.

Local variables get lowered to an static assignment that is assigned to a unique identifier in the context of its definition. Instances of this type are used to maintain the correspondance between an SSA ID and its corresponding name in program sources.

Attributes