END_TEST /* \begin{test}{SIGRAPH0401} \TestDescription{Schedule inheritance graph: mutex release test} \TestImplementationProcess{ Thread 3 (main thread) releases mutex1, effective priority of main thread should be 7. } \TestPassStatus{pass} \TestImplementationStatus{Implemented} \TestRegressionStatus{In regression test suite} \end{test} */ START_TEST(SIGRAPH0401) { L4_MsgTag_t tag; setup_graph(); L4_Receive(main_thread); tag = L4_Make_MsgTag(0x3, 0); L4_Set_MsgTag(tag); L4_Send(main_thread); L4_Receive(main_thread); L4_LoadMR(0, 0); L4_Send(main_thread); measure_effective_prio(7); delete_all(); }
static void setup_extended_graph(void) { setup_graph(); prio8_thread = createThread(other_sending_thread); L4_KDB_SetThreadName(prio8_thread, "prio8_thread"); L4_Set_Priority(prio8_thread, 201); L4_Set_Priority(prio8_thread, 8); prio6bis_thread = createThread(other_sending_thread); L4_KDB_SetThreadName(prio6bis_thread, "prio6bis_thread"); L4_Set_Priority(prio6bis_thread, 201); L4_Set_Priority(prio6bis_thread, 6); L4_Receive(main_thread); L4_LoadMR(0, 0); L4_Send(main_thread); }
END_TEST /* \begin{test}{SIGRAPH0305} \TestDescription{Schedule inheritance graph: cancel operation test} \TestImplementationProcess{ Cancel edge between thread 5 and mutex1, effective priority of main thread should be 7. } \TestPassStatus{pass} \TestImplementationStatus{Implemented} \TestRegressionStatus{In regression test suite} \end{test} */ START_TEST(SIGRAPH0305) { setup_graph(); L4_AbortOperation(prio5_thread); measure_effective_prio(7); delete_all(); }
END_TEST /* \begin{test}{SIGRAPH0208} \TestDescription{Schedule inheritance graph: change priority test} \TestImplementationProcess{ Change priority of thread 7 to 8, effective priority of main thread should be 8. } \TestPassStatus{pass} \TestImplementationStatus{Implemented} \TestRegressionStatus{In regression test suite} \end{test} */ START_TEST(SIGRAPH0208) { setup_graph(); L4_Set_Priority(prio7_thread, 8); measure_effective_prio(8); delete_all(); }
END_TEST /* \begin{test}{SIGRAPH0501} \TestDescription{Schedule inheritance graph: thread deletion test} \TestImplementationProcess{ Delete thread 1, effective priority of main thread should be 6. } \TestPassStatus{pass} \TestImplementationStatus{Implemented} \TestRegressionStatus{In regression test suite} \end{test} */ START_TEST(SIGRAPH0501) { setup_graph(); deleteThread(prio1_thread); prio1_thread = L4_nilthread; measure_effective_prio(6); delete_all(); }
//_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_-_ MainWindow::MainWindow(QWidget *parent) :QMainWindow(parent),ui(new Ui::MainWindow) { ui->setupUi(this); get_Ports(); get_Settings(); setup_graph(); //............................................ QSP = new MySerial(0); connect(QSP, SIGNAL(readyRead(QByteArray)), this, SLOT(on_readData(QByteArray))); //............................................ ui->TextEdit_char->document()->setMaximumBlockCount(1000); ui->TextEdit_code->document()->setMaximumBlockCount(1000); //............................................ timer1 = new QTimer(this); timer2 = new QTimer(this); connect(timer1,SIGNAL(timeout()),this,SLOT(on_pushButton_char_clicked())); connect(timer2,SIGNAL(timeout()),this,SLOT(on_pushButton_code_clicked())); }
void write_plainstr(graph_t* g, std::string *str) { int i; node_t *n; edge_t *e; bezier bz; char buf[SMALLBUF],buf1[SMALLBUF]; char tmpbuf[1000]; setup_graph(g); sprintf(tmpbuf, "graph %.3f", g->u.drawing->scale); str->append(tmpbuf); printptf(str, g->u.bb.UR); str->append("\n"); for (n = agfstnode(g); n; n = agnxtnode(g,n)) { str->append("node "); str->append(agstrcanon(n->name,buf)); printptf(str,n->u.coord); sprintf(tmpbuf, " %.3f", n->u.width); str->append(tmpbuf); sprintf(tmpbuf, " %.3f ", n->u.height); str->append(tmpbuf); str->append(agstrcanon(n->u.label->text,buf)); str->append(" "); str->append(late_nnstring(n,N_style,"solid")); str->append(" "); str->append(n->u.shape->name); str->append(" "); str->append(late_nnstring(n,N_color,DEFAULT_COLOR)); str->append(" "); str->append(late_nnstring(n,N_fillcolor,DEFAULT_FILL)); str->append("\n"); } for (n = agfstnode(g); n; n = agnxtnode(g,n)) { for (e = agfstout(g,n); e; e = agnxtout(g,e)) { bz = e->u.spl->list[0]; str->append("edge "); str->append(agstrcanon(e->tail->name,buf)); str->append(" "); str->append(agstrcanon(e->head->name,buf1)); str->append(" "); sprintf(tmpbuf, " %d", bz.size); str->append(tmpbuf); for (i = 0; i < bz.size; i++) printptf(str,bz.list[i]); if (e->u.label) { str->append(" "); str->append(agstrcanon(e->u.label->text,buf)); printptf(str,e->u.label->p); } str->append(" "); str->append(late_nnstring(e,E_style,"solid")); str->append(" "); str->append(late_nnstring(e,E_color,DEFAULT_COLOR)); str->append("\n"); } } str->append("stop\n"); }