sc_module.cc (12953:ddfd5e4643a9) | sc_module.cc (12958:a8188f40f342) |
---|---|
1/* 2 * Copyright 2018 Google, Inc. 3 * 4 * Redistribution and use in source and binary forms, with or without 5 * modification, are permitted provided that the following conditions are 6 * met: redistributions of source code must retain the above copyright 7 * notice, this list of conditions and the following disclaimer; 8 * redistributions in binary form must reproduce the above copyright --- 407 unchanged lines hidden (view full) --- 416{ 417 ::sc_core::at_negedge(s); 418} 419 420 421void 422next_trigger() 423{ | 1/* 2 * Copyright 2018 Google, Inc. 3 * 4 * Redistribution and use in source and binary forms, with or without 5 * modification, are permitted provided that the following conditions are 6 * met: redistributions of source code must retain the above copyright 7 * notice, this list of conditions and the following disclaimer; 8 * redistributions in binary form must reproduce the above copyright --- 407 unchanged lines hidden (view full) --- 416{ 417 ::sc_core::at_negedge(s); 418} 419 420 421void 422next_trigger() 423{ |
424 warn("%s not implemented.\n", __PRETTY_FUNCTION__); | 424 sc_gem5::Process *p = sc_gem5::scheduler.current(); 425 p->setDynamic(nullptr); |
425} 426 427void | 426} 427 428void |
428next_trigger(const sc_event &) | 429next_trigger(const sc_event &e) |
429{ | 430{ |
430 warn("%s not implemented.\n", __PRETTY_FUNCTION__); | 431 sc_gem5::Process *p = sc_gem5::scheduler.current(); 432 p->setDynamic(new ::sc_gem5::SensitivityEvent(p, &e)); |
431} 432 433void | 433} 434 435void |
434next_trigger(const sc_event_or_list &) | 436next_trigger(const sc_event_or_list &eol) |
435{ | 437{ |
436 warn("%s not implemented.\n", __PRETTY_FUNCTION__); | 438 sc_gem5::Process *p = sc_gem5::scheduler.current(); 439 p->setDynamic(new ::sc_gem5::SensitivityEventOrList(p, &eol)); |
437} 438 439void | 440} 441 442void |
440next_trigger(const sc_event_and_list &) | 443next_trigger(const sc_event_and_list &eal) |
441{ | 444{ |
442 warn("%s not implemented.\n", __PRETTY_FUNCTION__); | 445 sc_gem5::Process *p = sc_gem5::scheduler.current(); 446 p->setDynamic(new ::sc_gem5::SensitivityEventAndList(p, &eal)); |
443} 444 445void | 447} 448 449void |
446next_trigger(const sc_time &) | 450next_trigger(const sc_time &t) |
447{ | 451{ |
448 warn("%s not implemented.\n", __PRETTY_FUNCTION__); | 452 sc_gem5::Process *p = sc_gem5::scheduler.current(); 453 p->setDynamic(new ::sc_gem5::SensitivityTimeout(p, t)); |
449} 450 451void 452next_trigger(double d, sc_time_unit u) 453{ 454 next_trigger(sc_time(d, u)); 455} 456 457void | 454} 455 456void 457next_trigger(double d, sc_time_unit u) 458{ 459 next_trigger(sc_time(d, u)); 460} 461 462void |
458next_trigger(const sc_time &, const sc_event &) | 463next_trigger(const sc_time &t, const sc_event &e) |
459{ | 464{ |
460 warn("%s not implemented.\n", __PRETTY_FUNCTION__); | 465 sc_gem5::Process *p = sc_gem5::scheduler.current(); 466 p->setDynamic(new ::sc_gem5::SensitivityTimeoutAndEvent(p, t, &e)); |
461} 462 463void 464next_trigger(double d, sc_time_unit u, const sc_event &e) 465{ 466 next_trigger(sc_time(d, u), e); 467} 468 469void | 467} 468 469void 470next_trigger(double d, sc_time_unit u, const sc_event &e) 471{ 472 next_trigger(sc_time(d, u), e); 473} 474 475void |
470next_trigger(const sc_time &, const sc_event_or_list &) | 476next_trigger(const sc_time &t, const sc_event_or_list &eol) |
471{ | 477{ |
472 warn("%s not implemented.\n", __PRETTY_FUNCTION__); | 478 sc_gem5::Process *p = sc_gem5::scheduler.current(); 479 p->setDynamic( 480 new ::sc_gem5::SensitivityTimeoutAndEventOrList(p, t, &eol)); |
473} 474 475void 476next_trigger(double d, sc_time_unit u, const sc_event_or_list &eol) 477{ 478 next_trigger(sc_time(d, u), eol); 479} 480 481void | 481} 482 483void 484next_trigger(double d, sc_time_unit u, const sc_event_or_list &eol) 485{ 486 next_trigger(sc_time(d, u), eol); 487} 488 489void |
482next_trigger(const sc_time &, const sc_event_and_list &) | 490next_trigger(const sc_time &t, const sc_event_and_list &eal) |
483{ | 491{ |
484 warn("%s not implemented.\n", __PRETTY_FUNCTION__); | 492 sc_gem5::Process *p = sc_gem5::scheduler.current(); 493 p->setDynamic( 494 new ::sc_gem5::SensitivityTimeoutAndEventAndList(p, t, &eal)); |
485} 486 487void 488next_trigger(double d, sc_time_unit u, const sc_event_and_list &eal) 489{ 490 next_trigger(sc_time(d, u), eal); 491} 492 493bool 494timed_out() 495{ 496 warn("%s not implemented.\n", __PRETTY_FUNCTION__); 497 return false; 498} 499 500 501void 502wait() 503{ | 495} 496 497void 498next_trigger(double d, sc_time_unit u, const sc_event_and_list &eal) 499{ 500 next_trigger(sc_time(d, u), eal); 501} 502 503bool 504timed_out() 505{ 506 warn("%s not implemented.\n", __PRETTY_FUNCTION__); 507 return false; 508} 509 510 511void 512wait() 513{ |
504 warn("%s not implemented.\n", __PRETTY_FUNCTION__); | 514 sc_gem5::Process *p = sc_gem5::scheduler.current(); 515 p->setDynamic(nullptr); 516 sc_gem5::scheduler.yield(); |
505} 506 507void | 517} 518 519void |
508wait(int) | 520wait(int n) |
509{ | 521{ |
510 warn("%s not implemented.\n", __PRETTY_FUNCTION__); | 522 for (int i = 0; i < n; i++) 523 wait(); |
511} 512 513void | 524} 525 526void |
514wait(const sc_event &) | 527wait(const sc_event &e) |
515{ | 528{ |
516 warn("%s not implemented.\n", __PRETTY_FUNCTION__); | 529 sc_gem5::Process *p = sc_gem5::scheduler.current(); 530 p->setDynamic(new ::sc_gem5::SensitivityEvent(p, &e)); 531 sc_gem5::scheduler.yield(); |
517} 518 519void | 532} 533 534void |
520wait(const sc_event_or_list &) | 535wait(const sc_event_or_list &eol) |
521{ | 536{ |
522 warn("%s not implemented.\n", __PRETTY_FUNCTION__); | 537 sc_gem5::Process *p = sc_gem5::scheduler.current(); 538 p->setDynamic(new ::sc_gem5::SensitivityEventOrList(p, &eol)); 539 sc_gem5::scheduler.yield(); |
523} 524 525void | 540} 541 542void |
526wait(const sc_event_and_list &) | 543wait(const sc_event_and_list &eal) |
527{ | 544{ |
528 warn("%s not implemented.\n", __PRETTY_FUNCTION__); | 545 sc_gem5::Process *p = sc_gem5::scheduler.current(); 546 p->setDynamic(new ::sc_gem5::SensitivityEventAndList(p, &eal)); 547 sc_gem5::scheduler.yield(); |
529} 530 531void | 548} 549 550void |
532wait(const sc_time &) | 551wait(const sc_time &t) |
533{ | 552{ |
534 warn("%s not implemented.\n", __PRETTY_FUNCTION__); | 553 sc_gem5::Process *p = sc_gem5::scheduler.current(); 554 p->setDynamic(new ::sc_gem5::SensitivityTimeout(p, t)); 555 sc_gem5::scheduler.yield(); |
535} 536 537void 538wait(double d, sc_time_unit u) 539{ 540 wait(sc_time(d, u)); 541} 542 543void | 556} 557 558void 559wait(double d, sc_time_unit u) 560{ 561 wait(sc_time(d, u)); 562} 563 564void |
544wait(const sc_time &, const sc_event &) | 565wait(const sc_time &t, const sc_event &e) |
545{ | 566{ |
546 warn("%s not implemented.\n", __PRETTY_FUNCTION__); | 567 sc_gem5::Process *p = sc_gem5::scheduler.current(); 568 p->setDynamic(new ::sc_gem5::SensitivityTimeoutAndEvent(p, t, &e)); 569 sc_gem5::scheduler.yield(); |
547} 548 549void 550wait(double d, sc_time_unit u, const sc_event &e) 551{ 552 wait(sc_time(d, u), e); 553} 554 555void | 570} 571 572void 573wait(double d, sc_time_unit u, const sc_event &e) 574{ 575 wait(sc_time(d, u), e); 576} 577 578void |
556wait(const sc_time &, const sc_event_or_list &) | 579wait(const sc_time &t, const sc_event_or_list &eol) |
557{ | 580{ |
558 warn("%s not implemented.\n", __PRETTY_FUNCTION__); | 581 sc_gem5::Process *p = sc_gem5::scheduler.current(); 582 p->setDynamic( 583 new ::sc_gem5::SensitivityTimeoutAndEventOrList(p, t, &eol)); 584 sc_gem5::scheduler.yield(); |
559} 560 561void 562wait(double d, sc_time_unit u, const sc_event_or_list &eol) 563{ 564 wait(sc_time(d, u), eol); 565} 566 567void | 585} 586 587void 588wait(double d, sc_time_unit u, const sc_event_or_list &eol) 589{ 590 wait(sc_time(d, u), eol); 591} 592 593void |
568wait(const sc_time &, const sc_event_and_list &) | 594wait(const sc_time &t, const sc_event_and_list &eal) |
569{ | 595{ |
570 warn("%s not implemented.\n", __PRETTY_FUNCTION__); | 596 sc_gem5::Process *p = sc_gem5::scheduler.current(); 597 p->setDynamic( 598 new ::sc_gem5::SensitivityTimeoutAndEventAndList(p, t, &eal)); 599 sc_gem5::scheduler.yield(); |
571} 572 573void 574wait(double d, sc_time_unit u, const sc_event_and_list &eal) 575{ 576 wait(sc_time(d, u), eal); 577} 578 --- 67 unchanged lines hidden --- | 600} 601 602void 603wait(double d, sc_time_unit u, const sc_event_and_list &eal) 604{ 605 wait(sc_time(d, u), eal); 606} 607 --- 67 unchanged lines hidden --- |