Exemple #1
0
  @Override
  public void generate(@Nonnull PrintWriter pw) {
    ExecutionState inc = getIncomingExecutionState();
    Variable value = inc.peek(0);

    pw.println("    ret " + value.getType().getLLVMType() + " " + value.getName());
  }
Exemple #2
0
 @Override
 public void generate(@Nonnull PrintWriter pw) {
   ExecutionState inc = getIncomingExecutionState();
   pw.println(
       "    "
           + var.getName()
           + " = frem double "
           + inc.peek(1).getName()
           + ", "
           + inc.peek(0).getName());
 }
Exemple #3
0
  @Override
  public void generate(@Nonnull PrintWriter pw) {
    ExecutionState inc = getIncomingExecutionState();
    Variable value = inc.peek(0);
    Variable index = inc.peek(1);
    Variable arrayref = inc.peek(2);

    pw.println(
        "    call void(%array1.int *, i32, i32)* @iastore("
            + "%array1.int *"
            + arrayref.getName()
            + ", "
            + "i32 "
            + index.getName()
            + ", "
            + "i32 "
            + value.getName()
            + ")");
  }
Exemple #4
0
 @Override
 public void generate(@Nonnull PrintWriter pw) {
   ExecutionState inc = getIncomingExecutionState();
   pw.println("    " + var.getName() + " = trunc i32 " + inc.peek().getName() + " to i8");
 }