
/* This file was automatically generated by pclu.*/

#include "pclu_err.h"
#include "pclu_sys.h"


extern struct dbg_info* dbg_info_run_time;
#undef MY_TRACE_FLAG
#define MY_TRACE_FLAG run_time_TRACE
int run_time_TRACE;
extern struct OPS *int_ops;
static Vlist1 owns_run_time = {0, 1,{ {0, 2, "_init", &int_ops}
}
};
extern errcode _get_runtime();
extern errcode timeOPcreate();
extern OWN_req time_ownreqs;
extern struct OPS *time_ops;
static int run_time_own_init = 0;

/**** BEGIN PROCEDURE run_time ****/

errcode run_time(ret_1)
CLUREF *ret_1;
    {
    struct {
        struct dbg_info *DBG_INFO;
        int DBG_LINE;
        errcode err;
        errcode ecode2;
        CLUREF sec;
        CLUREF msec;
        CLUREF usec;
        } locals;
    locals.sec.num = UNINIT;
    locals.msec.num = UNINIT;
    locals.usec.num = UNINIT;
    locals.DBG_INFO = dbg_info_run_time;
        if (run_time_own_init == 0) {
        run_time_own_init = 1;
    }
    enter_proc(3);

  LINE(4);
    {
        {CLUREF T_1_1;
        CLUREF T_1_2;
        CLUREF T_1_3;
        locals.err = _get_runtime(&T_1_1, &T_1_2, &T_1_3);
        if (locals.err != ERR_ok) goto ex_0;
        locals.sec.num = T_1_1.num;
        locals.msec.num = T_1_2.num;
        locals.usec.num = T_1_3.num;
        }
        }

  LINE(5);
    {
    {
    CLUREF T_1_1;
    locals.err = timeOPcreate(CLU_0, CLU_0, CLU_0, locals.sec, locals.msec, locals.usec, &T_1_1);
    if (locals.err != ERR_ok) goto ex_0;
    ret_1->num = T_1_1.num;
    }
    {signal (ERR_ok);}}
    goto end_0;
    ex_0:
        {
            if (locals.err == ERR_failure) {signal(ERR_failure);}
            elist[0] = _pclu_erstr(locals.err);
            {signal(ERR_failure);}
        }
    end_0: elist[0].str = no_return_values_STRING;
        {signal(ERR_failure);}
    }

/**** END PROCEDURE run_time ****/

typedef struct {
    int hdr;
    int count;
    char *name;
    char *fname;
    bool is_iter;
    int is_parmd;
    int addr;
    int nargs;
    Vlist1 *vals;
    siglist0 *sigs;
    Vlist5 *locals;
    Vlist1 *owns;
    Vlist0 *ptowns;
    Vlist0 *popowns;
    Slist0 *type_formals;
    Slist0 *op_formals;
    } dbg_info_run_time_actual;
static Vlist1 vals_run_time = {0, 1, { {0, 2, "", &time_ops}}
};
static siglist0 sigs_run_time = {0, 0};
static Vlist5 locals_run_time = {0, 5,{ {0, 2, "err", &int_ops},  {0, 2, "ecode2", &int_ops},  {0, 2, "sec", &int_ops},  {0, 2, "msec", &int_ops},  {0, 2, "usec", &int_ops}}
};
static Vlist0 popowns_run_time = {0, 0};
Slist0 tformals_run_time = {0, 0};
Slist0 opformals_run_time = {0, 0};
dbg_info_run_time_actual dbg_info_run_time_data = {0, 12, 
    "run_time", "/common/pub/dcurtis-temp/pclu/lib/clu/run_time.clu", 0, 0, (int)run_time, 0, 
    &vals_run_time, &sigs_run_time, &locals_run_time, &owns_run_time, &NO_VALS, &NO_VALS, &NO_PARMS, &NO_PARMS};
    struct dbg_info *dbg_info_run_time = (struct dbg_info*)&dbg_info_run_time_data;
