package rune

  1. Overview
  2. Docs

Module Ir.LoweredSource

Sourcetype alu_op =
  1. | Binary of binop_kind
  2. | Unary of unary_op_kind
  3. | Ternary of ternary_op_kind
Sourcetype instruction =
  1. | L_Buffer of {
    1. dtype : Dtype.any;
    2. size : int;
    3. out : Var.t;
    }
  2. | L_Local of {
    1. dtype : Dtype.any;
    2. size : int;
    3. out : Var.t;
    }
  3. | L_Acc of {
    1. dtype : Dtype.any;
    2. out : Var.t;
    }
  4. | L_Define_Global of {
    1. ptr : Var.t;
    2. dtype : Dtype.any;
    3. size : int;
    }
  5. | L_Const of {
    1. dtype : Dtype.any;
    2. value : string;
    3. out : Var.t;
    }
  6. | L_Vconst of {
    1. dst : Var.t;
    2. values : string array;
    3. dtype : Dtype.any;
    }
  7. | L_Special of {
    1. dst : Var.t;
    2. kind : Special_index_kind.t;
    }
  8. | L_Define_Var of {
    1. sym_var : SymVar.t;
    2. out : Var.t;
    }
  9. | L_Range of {
    1. idx : Var.t;
    2. bound : Var.t;
    }
  10. | L_EndRange
  11. | L_If of {
    1. cond : Var.t;
    }
  12. | L_EndIf
  13. | L_Barrier
  14. | L_Block of {
    1. block_id : int;
    2. start : bool;
    }
  15. | L_Unroll of {
    1. idx : Var.t;
    2. iterations : int;
    }
  16. | L_Load of {
    1. dst : Var.t;
    2. buf : Var.t;
    3. idx : Var.t;
    4. dtype : Dtype.any;
    5. valid : Var.t option;
    }
  17. | L_Store of {
    1. buf : Var.t;
    2. idx : Var.t;
    3. src : Var.t;
    4. valid : Var.t option;
    }
  18. | L_ALU of {
    1. dst : Var.t;
    2. op : alu_op;
    3. args : Var.t list;
    4. dtype : Dtype.any;
    }
  19. | L_Gep of {
    1. dst : Var.t;
    2. src : Var.t;
    3. indices : int array;
    4. dtype : Dtype.any;
    }
  20. | L_Vectorize of {
    1. dst : Var.t;
    2. srcs : Var.t array;
    3. dtype : Dtype.any;
    }
  21. | L_Ptrcat of {
    1. dst : Var.t;
    2. ptrs : Var.t array;
    3. dtype : Dtype.any;
    }
  22. | L_Wmma of {
    1. dst : Var.t;
    2. a : Var.t;
    3. b : Var.t;
    4. c : Var.t;
    5. m : int;
    6. n : int;
    7. k : int;
    8. dtype : Dtype.any;
    }
  23. | L_Cast of {
    1. dst : Var.t;
    2. src : Var.t;
    3. dtype : Dtype.any;
    }
  24. | L_Bitcast of {
    1. dst : Var.t;
    2. src : Var.t;
    3. dtype : Dtype.any;
    }
  25. | L_Assign of {
    1. dst : Var.t;
    2. src : Var.t;
    }
  26. | L_Custom of {
    1. dst : Var.t option;
    2. op_name : string;
    3. args : Var.t array;
    4. attributes : (string * custom_attr) list;
    5. inline : bool;
    }
  27. | L_Noop
Sourcetype graph_t = {
  1. instructions : instruction list;
  2. vars_metadata : (Var.t, var_metadata) Hashtbl.t;
  3. kernel_input_vars : Var.t list;
  4. kernel_output_vars : Var.t list;
  5. symbolic_vars : SymVar.t list;
}
OCaml

Innovation. Community. Security.