score.h 552 Bytes
Newer Older
Leigh B. Stoller's avatar
Leigh B. Stoller committed
1 2 3 4 5 6
/*
 * EMULAB-COPYRIGHT
 * Copyright (c) 2000-2002 University of Utah and the Flux Group.
 * All rights reserved.
 */

Mac Newbold's avatar
Mac Newbold committed
7 8 9 10

#ifndef _SCORE_H
#define _SCORE_H

11

Mac Newbold's avatar
Mac Newbold committed
12 13 14 15 16 17
typedef struct {
  int unassigned;
  int pnode_load;
  int no_connection;
  int link_users;
  int bandwidth;
18
  int desires;
19
  int vclass;
Mac Newbold's avatar
Mac Newbold committed
20 21 22 23 24 25 26 27 28 29
} violated_info;

extern float score;
extern int violated;
extern violated_info vinfo;

void init_score();
void remove_node(node n);
int add_node(node n,int loc);
float get_score();
Christopher Alfeld's avatar
 
Christopher Alfeld committed
30
double fd_score(tb_vnode &vnoder,tb_pnode &pnoder,int *fd_violated);
Mac Newbold's avatar
Mac Newbold committed
31 32

#endif